1
0
mirror of synced 2026-08-05 19:16:55 +00:00
Files
MohammadYusif 03bb0f09e6 fix(mpeg): avoid negative bitrate/sampleRate for ADTS escape frequency index (#2644)
The MPEG-4 sampling-frequency index 15 is an escape value: the sampling
frequency is signalled explicitly elsewhere and cannot be derived from the
ADTS fixed header. The lookup table mapped this index to the sentinel -1
instead of null, so the bogus -1 was treated as a valid rate and propagated
into format.sampleRate and the ADTS bitrate calculation
(8 * bytesPerFrame * sampleRate / 1024), producing a negative bitrate.

Map index 15 to null like the other reserved indices (13, 14) so the existing
null-guards report an unknown rate instead of a negative one.
2026-07-05 15:09:39 +02:00
..