Commit 5128842e authored by Justin Ruggles's avatar Justin Ruggles

10l: Fix mistake in r26044. Check increment bounds using actual increment

instead of 64. This will change output in some cases, but it happens to not
affect the AC-3 regression tests.

Originally committed as revision 26180 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent c05ffcd9
......@@ -1125,7 +1125,7 @@ static int cbr_bit_allocation(AC3EncodeContext *s)
FFSWAP(uint8_t *, s->bap_buffer, s->bap1_buffer);
for (snr_incr = 64; snr_incr > 0; snr_incr >>= 2) {
while (snr_offset + 64 <= 1023 &&
while (snr_offset + snr_incr <= 1023 &&
bit_alloc(s, snr_offset + snr_incr) <= bits_left) {
snr_offset += snr_incr;
FFSWAP(uint8_t *, s->bap_buffer, s->bap1_buffer);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment