changeset 5390:479d93117d3c libavcodec

use enum value instead of numerical value for acmod
author jbr
date Mon, 23 Jul 2007 22:47:49 +0000
parents cf99cf2d3af9
children 6c1633a8dbc3
files ac3dec.c
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/ac3dec.c	Mon Jul 23 22:23:37 2007 +0000
+++ b/ac3dec.c	Mon Jul 23 22:47:49 2007 +0000
@@ -1348,7 +1348,7 @@
             for (i = 0; i < nfchans; i++)
                 ctx->chincpl[i] = get_bits1(gb);
 
-            if (acmod == 0x02)
+            if (acmod == AC3_ACMOD_STEREO)
                 ctx->phsflginu = get_bits1(gb); //phase flag in use
 
             ctx->cplbegf = get_bits(gb, 4);
@@ -1392,13 +1392,13 @@
                     }
                 }
 
-        if (acmod == 0x02 && ctx->phsflginu && (ctx->cplcoe & 1 || ctx->cplcoe & 2))
+        if (acmod == AC3_ACMOD_STEREO && ctx->phsflginu && (ctx->cplcoe & 1 || ctx->cplcoe & 2))
             for (bnd = 0; bnd < ctx->ncplbnd; bnd++)
                 if (get_bits1(gb))
                     ctx->cplco[1][bnd] = -ctx->cplco[1][bnd];
     }
 
-    if (acmod == 0x02) {/* rematrixing */
+    if (acmod == AC3_ACMOD_STEREO) {/* rematrixing */
         ctx->rematstr = get_bits1(gb);
         if (ctx->rematstr) {
             if (!(ctx->cplinu) || ctx->cplbegf > 2)