]> granicus.if.org Git - libvpx/commitdiff
Prevent accidental changes to the previous frame mode_infos
authorGuillaume Martres <gmartres@google.com>
Thu, 10 Oct 2013 17:38:34 +0000 (10:38 -0700)
committerGuillaume Martres <gmartres@google.com>
Thu, 10 Oct 2013 19:18:12 +0000 (12:18 -0700)
This is needed to fix mbgraph but shouldn't affect anything else

Change-Id: I2f515052f62e348cd3794b7ff0c139802225ea95

vp9/decoder/vp9_onyxd_if.c
vp9/encoder/vp9_onyx_if.c

index a42c2cf30d64a0e6563afb8d877fbac43539ded1..3875d743add6e1259f9d88afed6719f318c6640e 100644 (file)
@@ -397,6 +397,10 @@ int vp9_receive_compressed_data(VP9D_PTR ptr,
     cm->mi_grid_visible = cm->mi_grid_base + cm->mode_info_stride + 1;
     cm->prev_mi_grid_visible = cm->prev_mi_grid_base + cm->mode_info_stride + 1;
 
+    pbi->mb.mi_8x8 = cm->mi_grid_visible;
+    pbi->mb.mi_8x8[0] = cm->mi;
+    pbi->mb.this_mi = cm->mi;
+
     cm->current_video_frame++;
   }
 
index ff1d17945f586bdceca5d27e35f7546ecc6a0c5d..c4e56d401c8e52387f6ed3535f23ec21030895b1 100644 (file)
@@ -3453,6 +3453,10 @@ static void encode_frame_to_data_rate(VP9_COMP *cpi,
     cm->mi = cm->mip + cm->mode_info_stride + 1;
     cm->mi_grid_visible = cm->mi_grid_base + cm->mode_info_stride + 1;
 
+    cpi->mb.e_mbd.mi_8x8 = cm->mi_grid_visible;
+    cpi->mb.e_mbd.mi_8x8[0] = cm->mi;
+    cpi->mb.e_mbd.this_mi = cm->mi;
+
     // Don't increment frame counters if this was an altref buffer
     // update not a real frame
     ++cm->current_video_frame;