Commits
Commits on
978e6857d64772912559c8d8a4e6ee7cd309bdccFiltered to crates/engine/tests/opus_export.rsClear filter2026-08-20
✨ feat(engine): clips can be moved, scaled, rotated and cropped (edith 20)Ahmet Kaan Gümüş · 684b8a4
✨ feat(engine): clips can be moved, scaled, rotated and cropped (edith 20) Per-clip TransformParams (position, scale, 90-degree rotation, crop) shared through a colour-style table, applied in both the playback preview and the export compositor, persisted as the edith 20 dialect; v19 files load untransformed.
2026-08-19
✨ feat(engine): clips can name a dissolve into their neighbor (edith 19, storage+format)Ahmet Kaan Gümüş · 8369d8e
✨ feat(engine): clips can name a dissolve into their neighbor (edith 19, storage+format) transition_out frames on a video clip dissolve it into the adjacent next clip; split keeps the tail's transition clamped and zeroes the head; v18 files load with hard cuts, v19 round-trips bit-exactly. Blending (playback and export) lands separately.
🐛 fix(engine): integration tests learn the sample-rate argumentAhmet Kaan Gümüş · c6b5eb7
🐛 fix(engine): integration tests learn the sample-rate argument cf27932 added sample_rate to export::start and edith::save but left every tests/ call site behind; cargo build -p engine --tests has been broken since. All 34 call sites pass None (source rate), preserving each test's old behavior.
✨ feat(engine): per-clip audio fades, adjacency crossfade, and edith 18Ahmet Kaan Gümüş · 6d0747c
✨ feat(engine): per-clip audio fades, adjacency crossfade, and edith 18 Clip carries fade_in/fade_out, an equal-power gain envelope mixed into playback and export, a crossfade() op that sets both edges of two adjacent audio clips, and split's rule that only the kept edge keeps its fade. The project file format bumps to edith 18 to carry the two new fields; a v17 (or older) file loads with every clip's fades at zero. Fixes a stray fade_in/fade_out struct-literal fragment left outside any Clip literal in Player::trimmed (crates/app/src/player/timeline_edit.rs), which was a syntax error breaking the whole app crate's build. Adds unit coverage for Fade::gain_at's boundary/midpoint curve, the split edge rule, crossfade's adjacency refusal, the Clip size-lock test (40 -> 48 bytes), and a v17-loads-zero-fades / v18-round-trips edith.rs test.
2026-08-12
🔀 fix(export): a copied picture names the sound it was really written withAhmet Kaan Gümüş · 64cb44f
🔀 fix(export): a copied picture names the sound it was really written with The copy path and the Opus seat landed in the same function from two lanes and published two different sentences. The encoder path already names the codec the mix was *measured* to have taken; the copy path was still handing the card the same prediction the card shows before an export starts -- so an mkv whose mix fell back to AAC would have run under a line saying Opus, on precisely the exports that are over in a few seconds. Both branches now read the one flag `copy_audio` came back with. The check is the seam itself: an untouched HEVC timeline (copied block for block) with a 5.1 Opus source folded onto its audio lane (encoded), asserting the published line is "copy · Opus · SW encode (opus-rs)" and that the file carries A_OPUS and no A_AAC.
🔊 feat(export): an edited Opus source leaves an mkv as OpusAhmet Kaan Gümüş · 76ede8e
🔊 feat(export): an edited Opus source leaves an mkv as Opus Opus could be read here since `ruopus` landed and could not be written at all, so every cut of an Opus film came out as AAC in a Matroska file: a codec downgrade nobody asked for, paid on every edit. `opus-rs 0.1.26` is the encoder half -- a pure-Rust port of libopus 1.6, BSD-3, no `build.rs`, not one `.c` in the crate and no dependencies at all (checked, not read off the README) -- and a Matroska export now writes `A_OPUS` with an `OpusHead` in its `CodecPrivate`, `CodecDelay` and the codec's fixed 80 ms `SeekPreRoll` beside it. An mp4 still says AAC and the mp4 writer now refuses an Opus track by name rather than declaring `mp4a` over it. Only where an *encode* was going to happen anyway. An untouched timeline still copies its packets, bit for bit, into the same container: Opus is what an edit costs, never what a passthrough costs. The envelope is measured and it is narrow, which is the whole story of this crate. On three one-second spans of a 5.1 Opus film, encoded here and decoded with `ruopus` -- not the suspect, it reads ffmpeg's libopus at 256 kbps back at correlation 1.00000 -- the encoder is usable to 128 kbps (0.937/0.989/0.994) and ruined by 136 (0.452/0.697/0.951), against libopus at 0.997/0.998 on the same material. Pure-tone fixtures put that cliff at 165 kbps, so its edge moves with the content and no constant is safe on its own: the cap is 128 kbps *and* every track is decoded again and correlated with the mix before it is written. Below 0.95 the export writes AAC instead, and the encoder line the export publishes says AAC, so the fallback is visible rather than silent. Mono keeps AAC outright -- this encoder mis-codes it at every rate asked for here -- and so does any timeline that is not 48 kHz, since Opus has one rate and resampling a whole timeline to reach it is a bigger change to the sound than the codec is. Two delays, both measured rather than hoped for. The pre-skip is 1080 samples: the encoder's 2.5 ms lookahead plus one warm-up frame, because a cold first frame comes out ramped and out of phase (the head of the fixture went 0.9788 -> 0.988 correlated once it was fed its own first 20 ms first), and one silent frame is pushed in at the end so the last 2.5 ms leave the encoder instead of ending the track short under a picture that is not. ffmpeg's decode of the file agrees with this project's own reader sample for sample, which is what says the header describes the stream. `tests/opus_export.rs` exports a cut and reads it back through symphonia's mkv reader and `ruopus` -- 0.9948 left and 0.9825 right against the source, 0.997/0.993 past the first frame -- proves the AAC copy still wins where it applies and that a mono mix takes the AAC path, and, with `EDITH_OPUS_FILM` pointing at a real-library Opus mkv, cuts a span out of the film itself: correlation 0.9914 at a lag of one sample. The unit test in `export.rs` pins the 256 kbps failure, so the day the crate fixes it this suite fails and the cap can be raised.