forge
Explore
Log in

Don't you dare go Hollow

Commits

Commits on b978eaaa330c18a8b9c8cac7bbfdea0053c37dd2Filtered to crates/ec-ac3/src/decoder.rsClear filter

2026-08-14

fix(ac3): switch the spectral extension noise with the dither optionAhmet Kaan Gümüş · 6432e08
fix(ac3): switch the spectral extension noise with the dither option

§E3.6.4.2.4's noise() is a zero-mean unit-variance source the standard
leaves to the implementation, exactly like §7.3.4's dither: two conformant
decoders differ by it and by nothing else. It now follows the same option,
so a comparison against another decoder can isolate what the standard does
specify, and the default still generates both.

On the Dolby Digital Plus track that uses spectral extension this is the
whole remaining difference: 0.9988 per-channel correlation with both
decoders' noise in, 0.9994 with it out.
feat(ac3): AC-3 decoder — coupling, rematrixing, DRC and the public surfaceAhmet Kaan Gümüş · 5bc2be2
feat(ac3): AC-3 decoder — coupling, rematrixing, DRC and the public surface

One packet is one syncframe; frames come out as interleaved f32 in the
family's channel order, with an optional section 7.8 Lo/Ro downmix for
callers that want stereo. Dynamic range compression is applied by default
because section 7.7.1 says a decoder shall, with drc_scale to turn it
down; dialnorm is surfaced and never applied.

Every fixture decodes to a per-channel correlation of 1.000000 against
ffmpeg (mono, stereo and 5.1 at 32/44.1/48 kHz).