Commits
Commits on
fbc29d12fa2e194b105dd2344342fc50da4e90cdFiltered to crates/engine/tests/capability_matrix.rsClear filter2026-09-12
Merge branch 'lane-opus-swap' (597e096): both Opus seats are ec-opus natives -- ruopus/opus-rs/spectrograms leave the tree, the 128 kbps cap (an opus-rs bug workaround) rises to 320 and mono is proven end to end; known-accepted: ~1.5x slower absolute encode/decode vs the FFT-built incumbents at >=88x realtime floor, lane-ecopus-perf queued to close itAhmet Kaan Gümüş · 3d8112aBrowse files
✨ feat(engine): both Opus seats are ec-opus natives — the library pair is goneAhmet Kaan Gümüş · 597e096
✨ feat(engine): both Opus seats are ec-opus natives — the library pair is gone The decode seat (SymDecoder::Opus) and the encode seat (encode_opus) move off ruopus 0.1.2 / opus-rs 0.1.26 onto the codec family's own ec-opus, the first path dependency across into the sibling edith_codecs workspace. Both replaced crates leave Cargo.lock with everything they pulled in. What the swap is measured to do, not hoped to do: * decode equivalence: a real 5.1 stream decodes to correlation 1.000000 between the two decoders, and the film seek witness lands on the same samples it always did — the 312-sample pre-skip corrections hold unchanged, so no constant moved. * the 128 kbps cap goes to 320, the Sound row's top: opus-rs's packets above ~165 kbps were noise to every decoder but its own (re-measured: 0.011 correlation at 320 through BOTH decoders), and that cliff is the only thing the old ceiling stood on. ec-opus's 320 kbps packets read back identically through ruopus and through ec-opus. Fidelity at the top of the new band: 0.9999 (stereo 320), mono 0.9999-1.0000 (was 0.9983-0.9987 at 128). * mono leaves as Opus now. opus-rs mis-encoded mono at every rate, which is what kept a mono mix on the AAC path; a_mono_mix_leaves_as_opus_too pins the new behavior and the export.rs unit suite round-trips mono at 96 and 256. The muxer's family-0 OpusHead needed no change: it already wrote mono. * performance, measured honestly (release, min-of-7 alternating, against ruopus WITH the spectrograms/FFT backend the product actually shipped): ec-opus is ~1.4-1.7x SLOWER on every path — 5.1 decode 246x realtime where ruopus managed 407x; the export seat (encode plus its mandatory fidelity decode) 0.27 s against the old seat's 0.18 s per 30 s of stereo. Both stay far past realtime (>=88x), so nothing is user-perceptible, but the >10% bar is not met numerically; the swap stands on the dependency-freedom goal, and the family decoder has the headroom to close the gap. KNOWN-OPEN, not silently accepted.
✨ feat(engine): software VP8 decode via dlopen'd libvpx seat in the pluginAhmet Kaan Gümüş · ba33df0
✨ feat(engine): software VP8 decode via dlopen'd libvpx seat in the plugin
VP8 was refused by a stale UNSUPPORTED claim ('no VP8 decoder'); the
vendored cros-codecs VP8 decoder is VA-API-only and the test GPU
exposes no VP8 VA-API profile, so the real seat is software: libvpx.so.9
dlopen'd inside libengine_hw.so (vpx.rs), routed before any GPU device
opens, seek = destroy+re-init on the demuxer's keyframe contract,
CAP_VP8 reported as the plugin's seat. Codec::Vp8 plumbed through
demux (V_VP8 + mp4 vp08), colorspace, refusals; export UI gains a
truthful read-only VP8 row; test_vp8.{webm,mp4} fixtures + capability
row + tests/vp8.rs decode/export twins. Verified by the authoring
session: headless playloop 270 frames 0 dropped, 50/50 seeks, live
harness-driven UI playback, cross-provider review PASS (FFI layouts
against shipped libvpx DWARF, valgrind-clean).2026-08-12
✨ feat(audio): convert wide layouts and off-rate sources at import instead of refusingAhmet Kaan Gümüş · c94ba8b
✨ feat(audio): convert wide layouts and off-rate sources at import instead of refusing An 8-channel Opus track came back "IMPORT FAILED: unsupported channel layout: 8 channels (max stereo)" and took the picture with it, and a 48 kHz file "audio 48000 Hz 2 ch does not match the timeline's 44100 Hz 2 ch". Both strings are gone: an import converts. Width: `fold_5_1` becomes `downmix`, a coefficient table per layout from 2.1 to 7.1 (ITU-R BS.775 — front channels keep their side, centre and surrounds join at -3 dB, LFE dropped, both sides normalised by their own coefficient sum so a full-scale source cannot clip). 5.1 comes out of the table bit-identical to what it was. `vorbis_to_film_order` gains the RFC 7845 permutations for 3, 5, 7 and 8 channels beside the 6 it had, so surround Opus at any width reaches the fold in the order the fold reads. The AC-3 decoder's own 2.1 passthrough, which it leaves at 3, folds here too, and a multichannel AAC track in an *mp4* now takes the `rusty_aac` route the Matroska side already had (`aac_decoder`, one call for both). Rate: the segment resampler a speeded clip already goes through takes the source rate over the timeline's into its step, so the two compose into one interpolation and 48 kHz onto a 44.1 kHz timeline keeps its pitch. All of it is convert-on-read — per packet in the decoder, per buffer in `emit`, after the window trim — so there is no upfront pass to show progress for and nothing to cancel. What is still refused is the layout alone: a mono track cannot join a stereo timeline, in the words "audio 1 ch does not match the timeline's 2 ch". The picker's grey-out rule follows the gate rather than leading it. Measured on a 12.9 GB 2160p AV1 remux with a real-library 7.1 Opus track: imports, opens as a timeline, and a ten-second WAV export comes back at RMS 0.0091 left / 0.0085 right.
🔊 feat(audio): an Opus film is heard, not refusedAhmet Kaan Gümüş · 699950a
🔊 feat(audio): an Opus film is heard, not refused The refusal was the bug again. `is_audio` said "no opus, ac3 or dts, for which no pure-Rust decoder exists" while symphonia's own mkv and ogg readers have always mapped `A_OPUS` and `OpusHead` to `CODEC_ID_OPUS`: the containers read the format, only the decoder was missing. Symphonia genuinely has none at any version -- its feature list stops at vorbis and there is no `symphonia-codec-opus` crate -- so the decoder is `ruopus`, pure Rust, MIT, no dependencies of its own, and the film plays. Which crate is not a coin toss. A 5.1 track is four elementary Opus streams in one packet, all but the last self-delimited (RFC 6716 App. B). `rusty-opus 0.9.1` -- the sibling of `rusty_aac`/`rusty_mp3` already here -- hands each self-delimited slice to a decoder that parses it as an ordinary packet, so every stream but the last reads the length prefix as payload: it was measured on a 5.1 Opus remux as full-scale noise at -13 dBFS over a passage where the film is silent, which is exactly the failure that "the decoder returns samples" would have shipped. `ruopus` matches ffmpeg's decode of the same file to a correlation of 1.00000 on all six channels. Two things that are Opus's alone: it is stored in Vorbis channel order (FL, FC, FR, BL, BR, LFE) and the 5.1 fold reads the film order every other decoder here hands back, so the frame is permuted before it folds; and its encoder delay lives in the stream (`OpusHead`'s pre-skip, 312 samples) where neither reader drops it, so that is this track's priming -- sample-exact against ffmpeg afterwards, 6.5 ms late before. `.opus` and `.mka` join `is_audio`, `unsupported` asks the other reader before naming a codec (a refusal that fires on a track which decodes is the same defect wearing the other face), and `capability_matrix` covers Opus per container with DTS left as the one live refusal row.
🐛 fix(demux): a codec's support is probed per container, not inferred from a neighbourAhmet Kaan Gümüş · 4f4dcb4
🐛 fix(demux): a codec's support is probed per container, not inferred from a neighbour VP9 was decodable out of an mp4 and refused out of a .webm — `V_VP9` fell through the Matroska track dispatch into `OtherVideo` and came back as "V_VP9 video in a Matroska file is not supported", with the VA-API VP9 decoder wired in `engine-hw` the whole time. A browser-downloaded .mkv was one of those files. Both dispatches now read one table (`CODEC_IDS`), and the Matroska arm matches on `Codec` with no wildcard, so a codec added to the enum fails to compile until it has been routed rather than falling through to a refusal. A cell that is deliberately absent is a row in `UNSUPPORTED` with a reason, and the refusal quotes that reason instead of listing what is supported and leaving the user to guess. The mp4 video track comes out of `moov.traks` in file order, not a `HashMap` walk of `Mp4Reader::tracks()`: a file with two video tracks opened on a different picture from one run to the next, and a saved .edith reopened on the other one. `audio::audio_track_ids` fixed the same trap for sound; the naming half of `AudioSession::unsupported` had it too. VP9 states its bit depth in no container record — an mkv `TrackEntry` carries none and an mp4's `vpcC` is optional — so it is read off the first keyframe's uncompressed header. Assumed 8-bit, a profile 2 stream would decode into an NV12 pool and come back as garbage; 12-bit is refused by name like 12-bit AV1 and HEVC. The audio refusals said "AAC and AC-3 only" long after FLAC, MP3, Vorbis, ALAC and PCM decoded out of a Matroska file. They name the real set now, per container, because an mp4 video's sound never reaches symphonia and reads fewer codecs than an mkv does. tests/capability_matrix.rs holds all of it against real files.