Commit Graph
89 Commits
Author SHA1 Message Date
Tanish Manku 23ad007760 feat(ui): translate the sound envelope editor, layer volume and mute, and show the real Undo key in messages (M8)
The strings from sound effects (#100) and the ActionScript Script view
(#99) go through tr!/trn!; the envelope editor joins the pseudo-locale
accessibility audit. Messages that said "Ctrl+Z" now fill {undo} from
App::undo_key (the rebindable Undo key, through platform::shortcut_label,
so macOS reads ⌘Z). ADR 0040 leaves the reservations table.
2026-11-10 13:34:27 -07:00
Tanish Manku 562dd48e3f chore: merge main (sound effects, ActionScript tier 1, motion path points) into localisation; new strings still to route through tr! (M8) 2026-11-10 00:58:12 -07:00
Tanish Manku cddd1ea2e0 feat(ui): interface languages: tr! everywhere in the shell, craft-i18n catalogs, pseudo-locale (M8)
A translation layer in the shell (src/i18n): English source text is the
key (tr!, trn! with CLDR plurals, trc!, tr_noop!), catalogs in the
craft-i18n TSV format read by our own parser and embedded from
CRAFT_I18N_DIR by build.rs, fallback app > shared > base > English.
Preferences > Appearance > Language (system language by default) and
--lang for one run. Every shell string and screen-reader name goes through
it; menus translate the registry's labels when drawn, ids stay English.

Guardrails: a source guideline test fails on prose literals outside the
macros, a pseudo-locale accessibility audit fails on untranslated names,
and scripts/i18n-extract.sh writes the translators' template (1173
strings) and per-locale coverage. Lookups: 13 ns from a catalog, 16 ns
pseudo, none in English.
2026-11-10 00:41:54 -07:00
Tanish Manku d7c0434a25 chore: merge main (ActionScript tier 1) into sound effects; tests build with Symbol.linkage (M5) 2026-11-10 00:35:46 -07:00
Tanish Manku 990ea2c116 fix(ui): name the class field's widget id plainly (M6) 2026-11-10 00:10:50 -07:00
Tanish Manku 95a83ee2a0 feat(ui): Script view in the Actions panel, class rows in Properties (M6)
The Actions panel's Frame tab gets a Type row (Actions, Plug-in, Script);
Script shows and edits a keyframe's kept script in a monospace editor with
line numbers and its language, live and undoable. Graphic and button
timelines and guide layers show their kept scripts too. Properties shows the
symbol linkage class and the document class in documents that use scripts;
Test Movie says how many kept scripts don't run. The panel's pickers and
title bar are named for screen readers; --open script for screenshots.
2026-11-10 00:10:38 -07:00
Tanish Manku de38e47aa3 feat(audio): sound effect envelopes, layer volume and mute, sounds inside symbols (M5)
Frame sounds get Animate's Effect presets and Custom envelopes (up to 16
points per channel, seconds from the sound's start), shaped over the time
the sound is heard. Layers get a volume and Mute, multiplied down through
symbols. Graphic symbols play their sounds on their own frames mapped to
the parent's time (streams join mid-way), movie clips on a loop from when
the instance appeared; the interactive player reports entered sounds so
Test Movie plays them, following the audio clock. The mixer applies
per-channel envelopes and start offsets sample-exactly. HTML canvas
export carries envelopes, volumes and graphic sounds. Edit Envelope
window, timeline mute toggle, waveform shaped by the envelope.
2026-11-10 00:02:17 -07:00
Tanish Manku 5d3dc8dae0 feat(ui): edit motion path points and move the whole path on the stage (M2)
Subselection selects several anchors (Shift), double-click on the path
adds a point, Delete removes points (the ends stay, the status says
why), right-click makes them smooth or corners or straightens the path.
The Pen's Alt-click adds a point to the motion path or a selected
shape. Ctrl/Cmd-drag on the path or its object moves the whole path in
one undo step, and Properties shows the path's start to move it by
number. New screenshot and audit state: --open motionedit.
2026-11-09 23:43:06 -07:00
Tanish Manku a87728ba50 chore: merge main (eraser, eyedropper, XFL corpus) into the web build (M8) 2026-11-09 23:15:49 -07:00
Tanish Manku 7dcd01041e feat(shell): web build of the editor: browser entry, file picker and downloads, autosave to browser storage (M8)
src/web.rs starts the editor on a page canvas with eframe's WebRunner (WebGL2 via glow) and
provides the browser's services; platform.rs decides when: picked files go to the engine's
in-memory store and the command runs, saves and exports leave as downloads, preferences and
recovery copies live in localStorage, Web Locks tell open tabs from crashed ones, and leaving
with unsaved work asks first. The GPU stage and sound output become build cfgs that are off
on wasm. Video export and plug-in installs are dimmed in the browser with the reason.

scripts/build-web.sh and .ps1 build web/ with the wasm-bindgen CLI pinned to Cargo.lock's
version, from packaging/web/index.html. The web profile (opt-level s, stripped, renderer and
geometry at opt-level 3) gives an 8973 KB module, 3278 KB gzipped, in 41 s.
crates/engine/tests/wasm.rs runs the engine inside WebAssembly in Node (3 tests, 0.6 s).
2026-11-09 22:36:09 -07:00
Tanish Manku 3862732928 feat(shell): Eraser (E) with erase modes, Faucet and Erase Everything, and Eyedropper (I) (M7)
The Eraser sweeps the brush tip with a live preview in the stage colour, [ and ] size it, and a double-click on its tool button (or Erase Everything in its options) clears the stage at this frame after asking. The Eyedropper picks a fill (solid, gradient, bitmap) or a line into the tool style, applies it to selected shapes, then becomes the Paint Bucket or the Ink Bottle; Shift-click picks into the other swatch. New original icons; --open eraser|erasing|eyedropper for screenshots.
2026-11-09 22:18:41 -07:00
Tanish Manku 86f76dbc82 feat(engine): draw.erase with Animate's erase modes, the faucet and Erase Everything; paint.pick and paint.apply_style (M7)
The eraser sweeps the brush tip (ADR 0033) and goes into the planar merge as a fill whose regions come out empty, placed by the mode: on top (Erase Normal), between fills and lines (Erase Fills), over the lines only (Erase Lines), right above the selected fills or the fill the stroke starts on. Only raw shapes are erased; a stroke that erases nothing leaves no step (exact area and length compare). The Eyedropper picks a fill's paint (solid, gradient or bitmap, in stage space) or a line's colour, width and profile into the tool style; the Paint Bucket and the shape tools use a picked gradient where it is on the stage.
2026-11-09 22:13:26 -07:00
Tanish Manku 478c70feb8 feat(shell): Brush tool (B) with tool options, pen pressure, live preview and [ ] sizes (M7) 2026-11-09 21:20:59 -07:00
Tanish Manku 863e8af60a fix(gpu): tests and bench build with merge drawing's Shape.merge; ADR renumbered to 0032 after merge drawing took 0031 (M3) 2026-11-09 20:45:47 -07:00
Tanish Manku 02c4e1fc13 chore: merge main into the GPU stage third slice (M3) 2026-11-09 20:44:05 -07:00
BFlat e8bbc45dab Merge drawing, first slice: raw shapes cut and join as in Animate (#92)
Part of #42. ADR 0031: raw shapes cut and join on the layer (exact Bezier planar merge), Object Drawing (J), dot-pattern selection, double-click connected, drop on move, screen-pixel nudge.
2026-11-10 10:08:36 +07:00
Tanish Manku 3f3f280806 fix(shell): unit tests never start the GPU stage (M3)
With the GPU the default, app-level tests started its start-up thread; on
CI (lavapipe installed) it was still in the Vulkan driver when the test
process exited, which crashed it (SIGSEGV after all tests passed).
2026-11-09 20:03:11 -07:00
Tanish Manku 313745b204 feat(gpu): the GPU is the default stage renderer; ADR 0031 (M3)
The shell's gpu-stage feature is on by default and Preferences > Stage >
Renderer defaults to Graphics card (GPU), with the CPU drawing whenever
there is no usable card, a tile is past the GPU's limits or anything
fails. The setting is stored under a new key: every earlier build wrote
the old one as Cpu without anyone choosing it. CI installs lavapipe so the
parity tests run on a software adapter.

Measured (release, RTX 5090): 4K filtered sample 3.9 ms on Vulkan and
4.2 ms on DX12 (CPU 31.5 ms); 200 bitmap fills 4.4 / 4.3 ms (CPU 37.2 ms).
Docs: ADR 0031, performance, roadmap, architecture, CHANGELOG.
2026-11-09 19:48:49 -07:00
Tanish Manku bccb5e4df7 chore: merge main (GPU stage, second slice) into motion paths (M2) 2026-11-09 17:50:15 -07:00
Tanish Manku 67bf3ee0de feat(ui): motion paths on the stage: bend, move ends, Subselection points and handles; Orient to path (M2)
The selected motion tween's path shows in the motion colour on a dark halo,
with a dot per frame. Selection drags the path to bend it and its ends to
move them; Subselection drags anchors and handles (smooth pairs stay in
line, Alt breaks them). Each drag is one undo step. Properties shows the
path (Straighten) and Orient to path. --open motionpath|motionpoints show
it for screenshots and the accessibility audit.
2026-11-09 17:12:21 -07:00
Tanish Manku eb85dd2411 feat(gpu): GPU stage draws into the window's textures, no readback; ADR 0029 (M3)
The GPU stage shares eframe's wgpu device (egui_wgpu::RenderState) and
draws each stage tile into a storage texture the shell registers with
egui as it is. Fallbacks: a headless device with readback (window on
OpenGL), then the CPU oracle. Every call runs in thread-local error
scopes; nothing is installed on the window's device; a work bound per
dispatch guards the driver watchdog.

The engine stays GPU-free: Raster::Native carries an opaque image, cached
under its own 384 MB budget; only the shell downcasts it.

perf, gpu_bench on RTX 5090 (Vulkan), 32 threads:
  4K, 1,000 shapes: CPU 16.2-19.6 ms, read-back 8.4, direct 2.1-2.4 ms
  4K, 10k shapes:   CPU 25.8-28.1 ms, read-back 23.2, stage tiles 10.2 ms
  4K, masked 10k:   CPU 74.8-80.0 ms, stage tiles 10.9 ms
Binning stays on the CPU (ADR 0029: not the bottleneck as stage tiles).
2026-11-09 16:58:49 -07:00
Tanish Manku 86f74b71a3 Merge pull request #86 from storytold/m6/html-canvas-export
feat(export): HTML canvas export with an interactive player (M6)
2026-11-09 13:55:34 -07:00
Tanish Manku a7b3b0f2fa feat(engine): file.export_html, File > Export > Export HTML Canvas; ADR 0028, docs (M6) 2026-11-09 13:22:19 -07:00
Tanish Manku 7a2c3eaca8 fix(shell): the timeline header fits at the default window size (whole frame rates without decimals, tighter spacing) 2026-11-09 13:21:20 -07:00
Tanish Manku 62c5abf9cf chore: merge main (packaging, filters) into the camera layer (M7) 2026-11-09 13:10:26 -07:00
Tanish Manku 5b431ec1d3 feat(app): Camera tool, camera frame on the stage, Preview Through Camera and the camera toggle (M7)
The stage draws the camera frame in the camera layer's colour; the Camera tool
(C) pans, turns (round handle) and zooms (wheel), one undo step per drag;
View > Preview Through Camera renders stage tiles through the camera; the
timeline header toggles the camera; Properties gets a Camera section and a
layer Depth row. GPU parity and the accessibility audit cover camera scenes.
2026-11-09 12:50:31 -07:00
Tanish Manku cc4773a3ea feat(doc): camera layer, layer depth and camera commands (M7)
A camera layer kind (at most one per scene, always on top) whose keyframes hold
the camera as an element, so it tweens with classic and motion tweens. The
movie (evaluate, the player, every export) is the stage seen through it; the
editing view stays in stage space. Layer depth gives parallax. Commands:
camera.add/remove/set/info and layer.set_depth (ADR 0027).
2026-11-09 12:40:55 -07:00
Tanish Manku d05c12effd fix(shell): release builds are Windows GUI programs, no console window (M8)
The packaging's PE check found anicraft.exe used the console subsystem, so a console window
opened beside the app. Debug builds keep the console for logs.
2026-11-09 12:29:32 -07:00
Tanish Manku 94ac5cf2a0 test(packaging): keep the installers in step with the app; anicraft --version (M8)
src/packaging_tests.rs checks one app id everywhere, every type the Open dialog accepts is
registered on Windows, macOS and Linux, the WiX registry matches install-policy.json, and
the packaging icons exist.
2026-11-09 12:29:21 -07:00
Tanish Manku 7fbad142b6 feat(cli): anicraft-cli --version, window app id ai.storyteller.anicraft (M8)
The release packaging smoke-tests every build with anicraft-cli --version. The window's
Wayland app_id / X11 class becomes the reverse-DNS id the desktop entry, AppStream, Flatpak
and macOS bundle use (platform::APP_ID), so docks match the window to its launcher.
build.rs fails instead of warning when ANICRAFT_REQUIRE_WINRES=1 and the icon can't be
embedded (set by the Windows packaging).
2026-11-09 12:29:14 -07:00
Tanish Manku 996d7220a8 chore: merge main (frame scripts, Test Movie) into bevel and gradient filters (M5) 2026-11-09 05:39:38 -07:00
Tanish Manku 6a5b3f423d fix(app): name the Actions panel's list id scope plainly, not 'salt' (CodeQL took it for a cryptographic salt) (M6) 2026-11-09 05:18:52 -07:00
Tanish Manku a0dd41657f docs: ADR 0024 frame actions, frame scripts and Test Movie; plug-in ABI, roadmap, changelog (M6)
Also keeps frame-script plug-ins out of Commands > Plug-ins and the palette
(the Plug-ins window says where they are used instead).
2026-11-09 05:18:52 -07:00
Tanish Manku f18e4c9d4b feat(engine): frame actions, frame scripts on the plug-in host and Test Movie (M6)
Commands: actions.set/clear/list, instance.set_name, control.test_movie
(Ctrl+Enter; headless it plays the movie and reports its output), and
file.new_sample {which: interactive}. Frame-script plug-ins (kind
frame-script, entry points) run on enter-frame with Limits::frame_script:
20 M instructions shared per frame, 100 ms, ops player/action/actions/log,
no commands; plugin.run refuses them.

App: Test Movie window (player at the document frame rate, pointer to
buttons, Output panel, restart/pause/step, snapshot of the document),
Actions panel (F9) with structured action lists for keyframes, movie clip
timelines and button/movie clip events, instance name and events in
Properties, an 'a' mark on keyframes with actions.
2026-11-09 05:18:45 -07:00
Tanish Manku 9c7f65d305 feat(doc): timeline action IR and a pure interactive player (M6)
anicraft-actions (L0): typed actions (stop, play, go to a frame or label in
a scene, next/previous frame and scene, trace, set property), instance-name
target paths, button events, plug-in frame-script references.

anicraft-doc: keyframes carry a FrameScript, symbol instances carry event
handlers (serde defaults, sanitized on load). player::{start, step} steps a
PlayerState (scene, playheads, script-set properties, pointer) with budgets;
evaluate_player draws it; evaluate stays pure and unchanged.
2026-11-09 05:18:14 -07:00
Tanish Manku e3549b9bda fix(filters): review: centred even blurs, inner margins, area-capped reach, SVG region and ramp tables, stable ramp editing (M5)
* Box blurs of an even width were half a pixel off centre: now centred (one more
  pixel each side at half weight), so bevels stay symmetric.
* Inner effects blur the transparency around the artwork, so every side gets the
  full margin (inner Glow and Drop Shadow came out weak near the buffer edge).
* The reach past the surface is capped by area, keeping the padding around the
  artwork on wide surfaces (a 4096 px surface clipped shadows to the artwork).
* SVG: filter regions are the stage grown by the reach in user space; ramp tables
  have the CPU's 257 samples.
* Ramps: one pinned stop, others step aside (sanitize is idempotent); XFL ramps
  use one ratio scale; the panel edits sanitized filters, keeps moved stops between
  their neighbours and clear of the pin, and adds a stop from the keyboard.
2026-11-09 05:17:39 -07:00
Tanish Manku d28f0446a5 feat(filters): Bevel, Gradient Glow and Gradient Bevel filters (M5)
Model (FilterSide inner/outer/full, ramps with a pinned transparent rest stop),
CPU oracle (signed offset-difference field of the blurred opacity; ramp table),
SVG export with standard primitives, element.set_filters with hex colours and
ramp stops, XFL import of BevelFilter, GradientGlowFilter and
GradientBevelFilter, and Properties > Filters rows with a compact ramp editor.

Per 400x300 buffer, blur 16, quality Medium (release): Glow 0.87 ms, Bevel
1.33 ms, Gradient Glow 1.66 ms, Gradient Bevel 2.42 ms.
2026-11-09 05:17:20 -07:00
Tanish Manku 2805470a3e feat(shell): shape hint markers on the stage, Modify > Shape > Add Shape Hint (M2) 2026-11-09 04:43:18 -07:00
Tanish Manku 261dc14567 chore: merge main (variable-width strokes) into accessibility; the width profile picker and previews are named for screen readers (M8) 2026-11-09 04:32:58 -07:00
Tanish Manku 069cfdee43 feat(a11y): name the Sound properties from main; audit a sound keyframe too (M8) 2026-11-09 04:23:04 -07:00
Tanish Manku 24abe905f7 test(a11y): keyboard ownership with a focused control; timeline anchor falls back to the top row (M8) 2026-11-09 04:21:29 -07:00
Tanish Manku 73e82ba354 feat(a11y): interface scale up to 200 %, --theme/--scale for screenshots (M8)
- Stage stays fitted when the canvas changes size (window, docks, scale).
- Docks start proportional to the window and never crowd out the stage.
- Tools column scrolls; the timeline header scrolls sideways instead of
  clipping; the status message truncates before the readouts, which drop
  diagnostics when narrow, and is a polite live region for screen readers.
- Layer-count hint moves into the Layers header row.
- anicraft --theme graphite|high-contrast --scale <percent> (not saved).
2026-11-09 04:21:17 -07:00
Tanish Manku 95f4cc607c feat(a11y): screen-reader names for every control, Ctrl+F6 panel focus, high-contrast palette (M8)
- a11y module: names and roles for custom-painted controls (tools, layer
  toggles, icon buttons, library rows), Named for value-only widgets,
  focus rings, panel anchors and Ctrl+F6 / Ctrl+Shift+F6 cycling.
- Headless test walks egui's AccessKit tree in 22 UI states and fails on
  interactive nodes without a name or role.
- theme: runtime palette (Graphite, High contrast) behind T; new tokens
  on_active, icon_hot, on_fill, accent_text, control_outline.
- Contrast test covers both palettes; fixes two graphite AA misses
  (playhead number, accent-coloured text) and text_faint on headers.
2026-11-09 04:20:59 -07:00
Tanish Manku d85e398c4a chore: merge main (GPU stage, SVG clips) into variable-width strokes; GPU parity covers width profiles (M7) 2026-11-09 04:17:57 -07:00
Tanish Manku 3c79f97701 chore: merge main (SVG clips and text) into the GPU stage (M3) 2026-11-09 04:07:01 -07:00
Tanish Manku 6b8e3cb26f chore: merge main (audio, plug-ins, motion tweens) into variable-width strokes; ADR renumbered to 0018; plug-ins may edit stroke widths (M7) 2026-11-09 04:00:33 -07:00
Tanish Manku 244e21527b chore: merge main (audio, plug-ins, motion tweens) into the GPU stage (M3) 2026-11-09 03:58:26 -07:00
Tanish Manku 7e7d3a29d0 chore: merge main (audio, plug-ins, motion tweens) into SVG clips and text; fix an ADR reference (M4) 2026-11-09 03:57:17 -07:00
Tanish Manku 9173796835 docs: GPU stage ADR is 0019, as assigned by the lead (M3) 2026-11-09 03:44:33 -07:00
Tanish Manku 38209b8913 docs: ADR 0014 GPU stage, measured timings, roadmap and status (M3) 2026-11-09 03:44:33 -07:00