[FFmpeg-cvslog] r20039 - trunk/libavcodec/ac3.c

jbr subversion
Sun Sep 27 06:41:05 CEST 2009


Author: jbr
Date: Sun Sep 27 06:41:05 2009
New Revision: 20039

Log:
Move 2 variable declarations to inside of loop.

Modified:
   trunk/libavcodec/ac3.c

Modified: trunk/libavcodec/ac3.c
==============================================================================
--- trunk/libavcodec/ac3.c	Sun Sep 27 06:37:00 2009	(r20038)
+++ trunk/libavcodec/ac3.c	Sun Sep 27 06:41:05 2009	(r20039)
@@ -98,7 +98,7 @@ static inline int calc_lowcomp(int a, in
 void ff_ac3_bit_alloc_calc_psd(int8_t *exp, int start, int end, int16_t *psd,
                                int16_t *band_psd)
 {
-    int bin, j, k, end1, v;
+    int bin, j, k;
 
     /* exponent mapping to PSD */
     for(bin=start;bin<end;bin++) {
@@ -109,8 +109,8 @@ void ff_ac3_bit_alloc_calc_psd(int8_t *e
     j=start;
     k=bin_to_band_tab[start];
     do {
-        v = psd[j++];
-        end1 = FFMIN(band_start_tab[k+1], end);
+        int v = psd[j++];
+        int end1 = FFMIN(band_start_tab[k+1], end);
         for (; j < end1; j++) {
             /* logadd */
             int adr = FFMIN(FFABS(v - psd[j]) >> 1, 255);



More information about the ffmpeg-cvslog mailing list