]> granicus.if.org Git - libvpx/commitdiff
Always extend macroblock edges in the decoder.
authorRonald S. Bultje <rbultje@google.com>
Thu, 25 Oct 2012 19:46:26 +0000 (12:46 -0700)
committerRonald S. Bultje <rbultje@google.com>
Thu, 25 Oct 2012 19:46:39 +0000 (12:46 -0700)
This fixes edge extension if SB [0,1] doesn't use B_PRED but [1,1] does.

Change-Id: I48354a9dba0de16472938824f5e6db87ce61979f

vp8/decoder/decodframe.c

index d78fea2ecbbfe5c098458bb80afe1223f8be8bbd..78ba590e08744236d607deb11d6fe5923b337f41 100644 (file)
@@ -202,7 +202,7 @@ static void skip_recon_mb(VP8D_COMP *pbi, MACROBLOCKD *xd) {
 }
 
 static void decode_macroblock(VP8D_COMP *pbi, MACROBLOCKD *xd,
-                              int mb_row, unsigned int mb_col,
+                              unsigned int mb_col,
                               BOOL_DECODER* const bc) {
   int eobtotal = 0;
   MB_PREDICTION_MODE mode;
@@ -355,8 +355,6 @@ static void decode_macroblock(VP8D_COMP *pbi, MACROBLOCKD *xd,
                                               b->dst_stride);
     }
   } else if (mode == B_PRED) {
-    vp8_intra_prediction_down_copy(xd, mb_col == pc->mb_cols - 1 &&
-                                       !(mb_row & 1));
     for (i = 0; i < 16; i++) {
       BLOCKD *b = &xd->block[i];
       int b_mode = xd->mode_info_context->bmi[i].as_mode.first;
@@ -660,7 +658,9 @@ decode_sb_row(VP8D_COMP *pbi, VP8_COMMON *pc, int mbrow, MACROBLOCKD *xd,
         mi[pc->mode_info_stride + 1] = mi[0];
       }
 #endif
-      decode_macroblock(pbi, xd, mb_row, mb_col, bc);
+      vp8_intra_prediction_down_copy(xd, mb_col == pc->mb_cols - 1 &&
+                                     !(mb_row & 1));
+      decode_macroblock(pbi, xd, mb_col, bc);
 #if CONFIG_SUPERBLOCKS
       if (xd->mode_info_context->mbmi.encoded_as_sb) {
         mi[1].mbmi.txfm_size = mi[0].mbmi.txfm_size;