[FFmpeg-soc] [soc]: r2874 - aac/aac.c

superdump subversion at mplayerhq.hu
Mon Jul 28 10:52:21 CEST 2008


Author: superdump
Date: Mon Jul 28 10:52:21 2008
New Revision: 2874

Log:
Value is constant throughout loop so don't recalculate every iteration


Modified:
   aac/aac.c

Modified: aac/aac.c
==============================================================================
--- aac/aac.c	(original)
+++ aac/aac.c	Mon Jul 28 10:52:21 2008
@@ -1259,6 +1259,7 @@ static int decode_spectrum(AACContext * 
         for (i = 0; i < ics->max_sfb; i++) {
             const int cur_band_type = band_type[g][i];
             const int dim = cur_band_type >= FIRST_PAIR_BT ? 2 : 4;
+            const int is_cb_unsigned = IS_CODEBOOK_UNSIGNED(cur_band_type);
             int group;
             if (cur_band_type == ZERO_BT) {
                 for (group = 0; group < ics->group_len[g]; group++) {
@@ -1273,7 +1274,7 @@ static int decode_spectrum(AACContext * 
                         int j;
                         for (j = 0; j < dim; j++)
                             icoef[coef_idx + j] = 1;
-                        if (IS_CODEBOOK_UNSIGNED(cur_band_type)) {
+                        if (is_cb_unsigned) {
                             for (j = 0; j < dim; j++)
                                 if (vq_ptr[j] && get_bits1(gb))
                                     icoef[coef_idx + j] = -1;



More information about the FFmpeg-soc mailing list