[FFmpeg-soc] [soc]: r4352 - wmapro/wma3dec.c

faust3 subversion at mplayerhq.hu
Sun May 31 01:18:02 CEST 2009


Author: faust3
Date: Sun May 31 01:18:02 2009
New Revision: 4352

Log:
reset decorrelation_matrix only when needed

Modified:
   wmapro/wma3dec.c

Modified: wmapro/wma3dec.c
==============================================================================
--- wmapro/wma3dec.c	Sun May 31 01:03:56 2009	(r4351)
+++ wmapro/wma3dec.c	Sun May 31 01:18:02 2009	(r4352)
@@ -583,6 +583,7 @@ static void wma_decode_decorrelation_mat
     int i;
     int offset = 0;
     char rotation_offset[MAX_CHANNELS * MAX_CHANNELS];
+    memset(chgroup->decorrelation_matrix,0,sizeof(float) *s->num_channels * s->num_channels);
 
     for(i=0;i<chgroup->num_channels  * (chgroup->num_channels - 1) >> 1;i++)
         rotation_offset[i] = get_bits(&s->gb,6);
@@ -637,10 +638,6 @@ static int wma_decode_channel_transform(
      * 1 + MAX_CHANNELS * ( MAX_CHANNELS + 2 + 3 * MAX_CHANNELS * MAX_CHANNELS + MAX_CHANNELS + MAX_BANDS + 1)
      */
 
-    for(i=0;i< s->num_channels;i++){
-        memset(s->chgroup[i].decorrelation_matrix,0,sizeof(float) *s->num_channels * s->num_channels);
-    }
-
     /** in the one channel case channel transforms are pointless */
     s->num_chgroups = 0;
     if(s->num_channels > 1){


More information about the FFmpeg-soc mailing list