Commit 168d3138 authored by Ronald S. Bultje's avatar Ronald S. Bultje

Cache splitmv motion vectors appropriately in decoder.

This fixes some problems in splitmv-related bitstream parsing in the
sb8x8 experiment.

Change-Id: Id168f9ec9c88626877d8f536e6f394b6f4f782e4
parent e931dac7
...@@ -692,7 +692,12 @@ static void read_mb_modes_mv(VP9D_COMP *pbi, MODE_INFO *mi, MB_MODE_INFO *mbmi, ...@@ -692,7 +692,12 @@ static void read_mb_modes_mv(VP9D_COMP *pbi, MODE_INFO *mi, MB_MODE_INFO *mbmi,
if (vp9_segfeature_active(xd, mbmi->segment_id, SEG_LVL_SKIP)) { if (vp9_segfeature_active(xd, mbmi->segment_id, SEG_LVL_SKIP)) {
mbmi->mode = ZEROMV; mbmi->mode = ZEROMV;
} else { } else {
mbmi->mode = mbmi->sb_type > BLOCK_SIZE_MB16X16 ? mbmi->mode =
#if CONFIG_SB8X8
mbmi->sb_type > BLOCK_SIZE_SB8X8 ?
#else
mbmi->sb_type > BLOCK_SIZE_MB16X16 ?
#endif
read_sb_mv_ref(r, mv_ref_p) read_sb_mv_ref(r, mv_ref_p)
: read_mv_ref(r, mv_ref_p); : read_mv_ref(r, mv_ref_p);
vp9_accum_mv_refs(cm, mbmi->mode, mbmi->mb_mode_context[ref_frame]); vp9_accum_mv_refs(cm, mbmi->mode, mbmi->mb_mode_context[ref_frame]);
...@@ -882,7 +887,11 @@ static void read_mb_modes_mv(VP9D_COMP *pbi, MODE_INFO *mi, MB_MODE_INFO *mbmi, ...@@ -882,7 +887,11 @@ static void read_mb_modes_mv(VP9D_COMP *pbi, MODE_INFO *mi, MB_MODE_INFO *mbmi,
} }
*/ */
#if !CONFIG_SB8X8 #if CONFIG_SB8X8
mi->bmi[j].as_mv[0].as_int = blockmv.as_int;
if (mbmi->second_ref_frame > 0)
mi->bmi[j].as_mv[1].as_int = secondmv.as_int;
#else
{ {
/* Fill (uniform) modes, mvs of jth subset. /* Fill (uniform) modes, mvs of jth subset.
Must do it here because ensuing subsets can Must do it here because ensuing subsets can
......
...@@ -765,7 +765,12 @@ static void pack_inter_mode_mvs(VP9_COMP *cpi, MODE_INFO *m, ...@@ -765,7 +765,12 @@ static void pack_inter_mode_mvs(VP9_COMP *cpi, MODE_INFO *m,
// If segment skip is not enabled code the mode. // If segment skip is not enabled code the mode.
if (!vp9_segfeature_active(xd, segment_id, SEG_LVL_SKIP)) { if (!vp9_segfeature_active(xd, segment_id, SEG_LVL_SKIP)) {
if (mi->sb_type > BLOCK_SIZE_MB16X16) { #if CONFIG_SB8X8
if (mi->sb_type > BLOCK_SIZE_SB8X8)
#else
if (mi->sb_type > BLOCK_SIZE_MB16X16)
#endif
{
write_sb_mv_ref(bc, mode, mv_ref_p); write_sb_mv_ref(bc, mode, mv_ref_p);
} else { } else {
write_mv_ref(bc, mode, mv_ref_p); write_mv_ref(bc, mode, mv_ref_p);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment