Merge remote-tracking branch 'qatar/master'
authorMichael Niedermayer <michaelni@gmx.at>
Fri, 28 Feb 2014 01:06:34 +0000 (02:06 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Fri, 28 Feb 2014 01:08:11 +0000 (02:08 +0100)
* qatar/master:
  Give IDCT matrix transpose macro a more descriptive name

Merged-by: Michael Niedermayer <michaelni@gmx.at>
1  2 
libavcodec/h264.c
libavcodec/vp3.c
libavcodec/vp56.c

@@@ -2975,33 -2904,33 +2975,33 @@@ static void init_scan_tables(H264Contex
  {
      int i;
      for (i = 0; i < 16; i++) {
- #define T(x) (x >> 2) | ((x << 2) & 0xF)
-         h->zigzag_scan[i] = T(zigzag_scan[i]);
-         h->field_scan[i]  = T(field_scan[i]);
- #undef T
+ #define TRANSPOSE(x) (x >> 2) | ((x << 2) & 0xF)
+         h->zigzag_scan[i] = TRANSPOSE(zigzag_scan[i]);
+         h->field_scan[i]  = TRANSPOSE(field_scan[i]);
+ #undef TRANSPOSE
      }
      for (i = 0; i < 64; i++) {
- #define T(x) (x >> 3) | ((x & 7) << 3)
-         h->zigzag_scan8x8[i]       = T(ff_zigzag_direct[i]);
-         h->zigzag_scan8x8_cavlc[i] = T(zigzag_scan8x8_cavlc[i]);
-         h->field_scan8x8[i]        = T(field_scan8x8[i]);
-         h->field_scan8x8_cavlc[i]  = T(field_scan8x8_cavlc[i]);
- #undef T
+ #define TRANSPOSE(x) (x >> 3) | ((x & 7) << 3)
+         h->zigzag_scan8x8[i]       = TRANSPOSE(ff_zigzag_direct[i]);
+         h->zigzag_scan8x8_cavlc[i] = TRANSPOSE(zigzag_scan8x8_cavlc[i]);
+         h->field_scan8x8[i]        = TRANSPOSE(field_scan8x8[i]);
+         h->field_scan8x8_cavlc[i]  = TRANSPOSE(field_scan8x8_cavlc[i]);
+ #undef TRANSPOSE
      }
      if (h->sps.transform_bypass) { // FIXME same ugly
 -        h->zigzag_scan_q0          = zigzag_scan;
 -        h->zigzag_scan8x8_q0       = ff_zigzag_direct;
 -        h->zigzag_scan8x8_cavlc_q0 = zigzag_scan8x8_cavlc;
 -        h->field_scan_q0           = field_scan;
 -        h->field_scan8x8_q0        = field_scan8x8;
 -        h->field_scan8x8_cavlc_q0  = field_scan8x8_cavlc;
 +        memcpy(h->zigzag_scan_q0          , zigzag_scan             , sizeof(h->zigzag_scan_q0         ));
 +        memcpy(h->zigzag_scan8x8_q0       , ff_zigzag_direct        , sizeof(h->zigzag_scan8x8_q0      ));
 +        memcpy(h->zigzag_scan8x8_cavlc_q0 , zigzag_scan8x8_cavlc    , sizeof(h->zigzag_scan8x8_cavlc_q0));
 +        memcpy(h->field_scan_q0           , field_scan              , sizeof(h->field_scan_q0          ));
 +        memcpy(h->field_scan8x8_q0        , field_scan8x8           , sizeof(h->field_scan8x8_q0       ));
 +        memcpy(h->field_scan8x8_cavlc_q0  , field_scan8x8_cavlc     , sizeof(h->field_scan8x8_cavlc_q0 ));
      } else {
 -        h->zigzag_scan_q0          = h->zigzag_scan;
 -        h->zigzag_scan8x8_q0       = h->zigzag_scan8x8;
 -        h->zigzag_scan8x8_cavlc_q0 = h->zigzag_scan8x8_cavlc;
 -        h->field_scan_q0           = h->field_scan;
 -        h->field_scan8x8_q0        = h->field_scan8x8;
 -        h->field_scan8x8_cavlc_q0  = h->field_scan8x8_cavlc;
 +        memcpy(h->zigzag_scan_q0          , h->zigzag_scan          , sizeof(h->zigzag_scan_q0         ));
 +        memcpy(h->zigzag_scan8x8_q0       , h->zigzag_scan8x8       , sizeof(h->zigzag_scan8x8_q0      ));
 +        memcpy(h->zigzag_scan8x8_cavlc_q0 , h->zigzag_scan8x8_cavlc , sizeof(h->zigzag_scan8x8_cavlc_q0));
 +        memcpy(h->field_scan_q0           , h->field_scan           , sizeof(h->field_scan_q0          ));
 +        memcpy(h->field_scan8x8_q0        , h->field_scan8x8        , sizeof(h->field_scan8x8_q0       ));
 +        memcpy(h->field_scan8x8_cavlc_q0  , h->field_scan8x8_cavlc  , sizeof(h->field_scan8x8_cavlc_q0 ));
      }
  }
  
Simple merge
Simple merge