[FFmpeg-soc] [soc]: r2650 - mlp/mlpdec.c

ramiro subversion at mplayerhq.hu
Tue Jul 1 18:54:41 CEST 2008


Author: ramiro
Date: Tue Jul  1 18:54:41 2008
New Revision: 2650

Log:
Clean up function that has just been copied over.

Modified:
   mlp/mlpdec.c

Modified: mlp/mlpdec.c
==============================================================================
--- mlp/mlpdec.c	(original)
+++ mlp/mlpdec.c	Tue Jul  1 18:54:41 2008
@@ -303,24 +303,23 @@ static inline int read_huff_channels(MLP
             m->bypassed_lsbs[pos + s->blockpos][mat] = get_bits1(gbp);
 
     for (channel = s->min_channel; channel <= s->max_channel; channel++) {
-    int codebook = m->codebook[channel];
-    int quant_step_size = s->quant_step_size[channel];
-    int lsb_bits = m->huff_lsbs[channel] - quant_step_size;
-    int result = 0;
-
-    if (codebook > 0)
-        result = get_vlc2(gbp, huff_vlc[codebook-1].table,
-                          VLC_BITS, (9 + VLC_BITS - 1) / VLC_BITS);
+        int codebook = m->codebook[channel];
+        int quant_step_size = s->quant_step_size[channel];
+        int lsb_bits = m->huff_lsbs[channel] - quant_step_size;
+        int result = 0;
 
-    if (result < 0)
-        return -1;
+        if (codebook > 0)
+            result = get_vlc2(gbp, huff_vlc[codebook-1].table,
+                            VLC_BITS, (9 + VLC_BITS - 1) / VLC_BITS);
 
-    if (lsb_bits > 0)
-        result = (result << lsb_bits) + get_bits(gbp, lsb_bits);
+        if (result < 0)
+            return -1;
 
-    result += m->sign_huff_offset[channel];
+        if (lsb_bits > 0)
+            result = (result << lsb_bits) + get_bits(gbp, lsb_bits);
 
-    result <<= quant_step_size;
+        result  += m->sign_huff_offset[channel];
+        result <<= quant_step_size;
 
         m->sample_buffer[pos + s->blockpos][channel] = result;
     }



More information about the FFmpeg-soc mailing list