forge
Explore
Log in

Don't you dare go Hollow

Commits

Commits on mainFiltered to crates/engine/tests/images.rsClear filter

2026-10-23

🚚 edith moves to git.tahinli.comAhmet Kaan Gümüş · b02f499
🚚 edith moves to git.tahinli.com

The working tree as of 2026-10-23, as one commit on top of the last one
here. It carries the work up to that date plus the test-slimming work:
integration tests merged into one binary per crate, nextest config,
doctest = false, debug line tables only, perf tests behind --ignored,
and faster generators, reverse, undo, subtitle-export, hevc, stabilise
and hear tests.

2026-08-11

🧹 test(scratch): a fixture directory is deleted by the test that made itAhmet Kaan Gümüş · 5c39124
🧹 test(scratch): a fixture directory is deleted by the test that made it

Every suite here made its own directory under /tmp with a name and a
process id and then walked away from it: 2907 `ve_*` directories, 6.4G of
a 16G tmpfs, none of them reclaimable by anything but a person with `rm`.

`engine::scratch::Scratch` is the one place a throwaway path comes from
now -- a directory, or the single file inside one -- and `Drop` is what
takes it back. That is the whole reason it is a guard rather than a
cleanup call at the end of a test: unwinding runs `Drop`, so the *failing*
tests, which are exactly the ones that used to leave the most behind,
clean up like the passing ones.

It derefs to a `Path`, so the call sites did not have to change: the
helpers that handed back a `PathBuf` hand back one of these. The prefixes
stay what they were, so a directory is still recognisable while a test is
stopped in it.

Nothing about what a test *does* moved -- only where its fixtures live and
when they die. Driven: the whole engine suite and the app's own tests run
with the count of `/tmp/ve_*` before equal to the count after.

2026-08-10

🔀 merge(T6): the last media leaves, and nothing assumes source 0 stayedAhmet Kaan Gümüş · 7e4ead7
🔀 merge(T6): the last media leaves, and nothing assumes source 0 stayed

Both sides kept: the library-removal slice (a project may name no file, the
audio reference is never a still, the clipboard follows its file down the
list, a silence edit drops the selection) and main's EQ audio export, image
left-trim, track removal, volume slider, hold-repeat and EQ spectrum.

The one textual conflict was the test import list; close_session now also
drops the gestures and caches those slices added.
🐛 fix(timeline): a pasted still never lands on the audio laneAhmet Kaan Gümüş · b586b85
🐛 fix(timeline): a pasted still never lands on the audio lane

`Project::paste` routed by `is_audio` alone, so a *copied* still clip --
the one door that does not go through `place_stream_at` -- was pasted as
a grouped take across `V1` and `A1`. The A1 half is a PNG the audio
worker demuxes: "file contains a box with a larger size than it", which
silences the whole session rather than that clip, and the save it writes
is one `open_project` then refuses by name. An `is_image` arm mirrors the
audio-only one.

Same-shape sweep of every clip-level door that routes by source kind:
- `Project::paste` (project.rs) -- this defect, fixed.
- `PlaybackSession::place_stream_at` -- already routed, image arm returns
  on the video lane before the audio fork.
- `PlaybackSession::open`/`open_project` -- both directions refused by
  name at load.
- `Project::move_to_lane` -- refuses a move across kinds, so no clip can
  cross by drag. Clean.
- `Project::place`, `split`, `regroup`, `lift`, `delete_in`, `trim` --
  the caller names the lane or the lane never changes. Clean, and the
  loader is the backstop for a hand-written file either way.
- `Player::insert_source` (app) -- guarded both ways already.

Falsification: with the `(_, true) => &[LaneKind::Video]` arm removed the
new test fails at the lane count (A1 1 -> 2), and with that assertion
lifted it fails on the WAV export with the demux error above -- the two
consequences the test names, both reachable.

Two doc corrections found with it: `Still::open` now says alpha is
dropped by `to_rgb8` (a transparent PNG lands opaque, with the blend as
the ponytail), and `first_audio_of` no longer implies an image-first
timeline accepts a later audio import -- it widens which source is
asked, not what "the timeline is silent" means.

tests: images 7/7 (new `pasting_a_copied_still_never_reaches_the_audio_lane`
asserts no A1 clip, no audio clip from a picture, the WAV export still
carries the sound, and the save reopens), engine lib 155, saveload 12,
audio_files 16, lanes 5 (serial), bin 56.
✨ feat(timeline): still images import and place as clipsAhmet Kaan Gümüş · 30d430d
✨ feat(timeline): still images import and place as clips

A PNG, JPEG or WebP is a source like any other: it imports into the
library, drags onto a video lane, shows at the playhead, trims, saves and
exports. `engine::is_image` is the door, beside `is_audio`, and every
choice it forces is made in one place.

The decisions, spelled out:

- Extensions: png, jpg, jpeg, webp -- exactly what the `image` crate is
  built with here. Anything else is refused by the door that refuses a
  .txt.
- Length: an image has none, so it is *held to* ten minutes (600 s at the
  timeline's rate) and *placed* at five seconds. The cap is finite on
  purpose -- a u32::MAX sentinel would hand a trim drag a wall past
  anything the timeline can hold -- and it is recomputed identically at
  load, so a clip trimmed out to it reopens.
- Image-first project: its own picture is the canvas (a still *has* a
  resolution, unlike a song) at 30 fps, silent, one 5 s clip on V1. The
  A2 audio-only precedent for everything else.
- Scaling: none of its own. The still is decoded once to I420 and goes
  through the same grade, the same `Composer` and the same conversion a
  decoded picture does, so a 640x360 image on a 1280x720 canvas is
  letterboxed by its fit policy and never stretched.
- Lanes: the mirror of a song. A still goes on the video lane it was
  asked for or on V1, never on an audio one, and never as a grouped take
  -- a clip on A1 playing a PNG is a segment the audio worker cannot
  open. Hand-written projects are refused by name.
- The timeline's audio parameters are now the first source that *could*
  have any, so an image as source 0 no longer holds every later import to
  its silence.

Playback opens a still worker (one conversion, then a memcpy per frame,
as the black-gap worker does); the export's `ClipDecoder` hands the same
planes out for as long as the span runs, so a mixed video/still timeline
encodes at the cut.

tests: engine/tests/images.rs -- import registers only, placed pixels
match the file's own (top/bottom bands catch a flip, RGB order catches a
swap), trim walls at the cap, .edith round trip incl. the audio-lane
refusal, mp4 export pixel-checked at the cut, audio-lane placement lands
on V1. Fixture: scripts/gen_fixtures.sh writes assets/test_still.png.