forge
Explore
Log in

Don't you dare go Hollow

Commits

Commits on 00c1b3ff2d80d84fef71bb6208110dedbbd95fc4Filtered to crates/ec-opus/src/multistream.rsClear filter

2026-08-14

feat(opus): multistream decoding, 5.1 and 7.1Ahmet Kaan Gümüş · 8bd3b2b
feat(opus): multistream decoding, 5.1 and 7.1

MultistreamDecoder splits a packet into its elementary streams by the
self-delimiting framing of Appendix B and routes each stream's channels through
the mapping table, silent channels included. Constructor takes the layout the
container header carries (rate, streams, coupled, mapping), which is the shape
the product already calls.

The CELT N/4 FFT's 15-point stage is now radix-3 then radix-5 rather than a
direct 15x15 evaluation, which is where a third of multichannel decode time was
going: a real 7.1 film track went from 102x to 124x realtime.

Checks (all in tests/conformance.rs): the mono, stereo and 5.1 Ogg-Opus
fixtures decode to correlation 1.00000 per channel against libopus through
ffmpeg; the 5.1 fixture's per-channel tones land in the RFC 7845 family 1
(Vorbis) order the reference produces, each channel carrying its own tone;
decode speed is 430x realtime stereo (fixture and testvector01 music alike) and
236x realtime 5.1, against floors of 135x and 104x. The twelve RFC vectors are
unchanged. An env-driven sweep (EC_OPUS_FILES, #[ignore]) runs the same
comparison over real files.