[FFmpeg-soc] [soc]: r858 - dirac/libavcodec/dirac.c

marco subversion at mplayerhq.hu
Thu Aug 16 14:36:07 CEST 2007


Author: marco
Date: Thu Aug 16 14:36:07 2007
New Revision: 858

Log:
simplify checking for a zero codeblock

Modified:
   dirac/libavcodec/dirac.c

Modified: dirac/libavcodec/dirac.c
==============================================================================
--- dirac/libavcodec/dirac.c	(original)
+++ dirac/libavcodec/dirac.c	Thu Aug 16 14:36:07 2007
@@ -926,7 +926,6 @@ static void codeblock(DiracContext *s, i
                       subband_t orientation, int x, int y,
                       int qoffset, int qfactor) {
     int blockcnt_one = (s->codeblocksh[level] + s->codeblocksv[level]) == 2;
-    int zero = 0;
     int left, right, top, bottom;
     int v, h;
 
@@ -937,12 +936,10 @@ static void codeblock(DiracContext *s, i
 
     if (!blockcnt_one) {
         /* Determine if this codeblock is a zero block.  */
-        zero = dirac_arith_get_bit(&s->arith, ARITH_CONTEXT_ZERO_BLOCK);
+        if (dirac_arith_get_bit(&s->arith, ARITH_CONTEXT_ZERO_BLOCK))
+            return;
     }
 
-    if (zero)
-        return; /* All coefficients remain 0.  */
-
     for (v = top; v < bottom; v++)
         for (h = left; h < right; h++)
             coeff_unpack(s, data, level, orientation, v, h,



More information about the FFmpeg-soc mailing list