[FFmpeg-cvslog] r26180 - trunk/libavcodec/ac3enc.c

jbr subversion
Fri Dec 31 23:59:19 CET 2010


Author: jbr
Date: Fri Dec 31 23:59:19 2010
New Revision: 26180

Log:
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.

Modified:
   trunk/libavcodec/ac3enc.c

Modified: trunk/libavcodec/ac3enc.c
==============================================================================
--- trunk/libavcodec/ac3enc.c	Fri Dec 31 21:01:12 2010	(r26179)
+++ trunk/libavcodec/ac3enc.c	Fri Dec 31 23:59:19 2010	(r26180)
@@ -1125,7 +1125,7 @@ static int cbr_bit_allocation(AC3EncodeC
 
     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);



More information about the ffmpeg-cvslog mailing list