Skip to content

Pixel Studio ​

A compact sprite editor built around a 16 × 16 canvas, named tools, a palette and a live preview. The editing surface stays central at every zoom level.

Run it ​

Build the examples with devenv shell -- lcom-ng-build, then run:

sh
lcom-ng run -- build/examples/pixel_studio build/pixel_studio_sprite.h

Try a complete workflow ​

Draw or fill a region, sample a color, and inspect the preview. Use undo, redo and reversible flips to explore alternatives. Export the sprite as a timestamped C header for another program.

Controls ​

ControlAction
B / P / E / F / IPencil / eraser / fill / eyedropper
Mouse drag / right-clickPaint / pick canvas color
Arrows + Enter / SpaceMove pixel cursor and apply tool
DeleteErase the cursor pixel
[ / ]Previous / next palette color
X / VFlip horizontally / vertically
1 / 2 / 3 or - / +Zoom
GToggle grid
Cmd/Ctrl+Z / Shift+ZUndo / redo
Cmd/Ctrl+S / S / F2Export reusable C header
C / F1Clear / shortcuts

Command shortcuts work on macOS; Ctrl shortcuts work on other hosts. Esc closes help first. Cmd/Ctrl+W closes the app.

In the app ​

These are actual runtime captures. Open a screenshot for a larger view; use Left and Right to browse, and Escape to close.

A 16 by 16 canvas, indexed palette, native-size previews and real history controls.

Every pixel counts · A 16 by 16 canvas, indexed palette, native-size previews and real history controls.

What it demonstrates ​

PS/2 gestures, stroke interpolation, flood fill, bounded undo history, RTC timestamps and C asset generation.

The editable sprite is 16 × 16 pixels. Export produces C data; it does not reopen arbitrary image files.

Source: examples/pixel_studio.c.

Refresh these screenshots ​

sh
devenv shell -- python3 scripts/capture_gallery.py --app pixel-studio

See the screenshot workflow to add states or check freshness.

Course/docs licensed CC BY 4.0. Code licensed MIT.