Fix bug when cb4x4 is disabled
When cb4x4 is disabled and global-motion is enabled, the function
av1_append_sub8x8_mvs_for_idx accidentally fetched
cm->global_motion[ref] instead of cm->global_motion[rf[0]],
ie. it used the reference *index* instead of the reference *frame*.
Change-Id: Ieebf60f6b7c0a1cbbc083a70d4451ad799e27fe3
diff --git a/av1/common/mvref_common.c b/av1/common/mvref_common.c
index 77cd715..afc78c0 100644
--- a/av1/common/mvref_common.c
+++ b/av1/common/mvref_common.c
@@ -929,10 +929,10 @@
assert(MAX_MV_REF_CANDIDATES == 2);
#if CONFIG_GLOBAL_MOTION
- zeromv.as_int =
- gm_get_motion_vector(&cm->global_motion[ref], cm->allow_high_precision_mv,
- mi->mbmi.sb_type, mi_col, mi_row, block)
- .as_int;
+ zeromv.as_int = gm_get_motion_vector(&cm->global_motion[rf[0]],
+ cm->allow_high_precision_mv,
+ mi->mbmi.sb_type, mi_col, mi_row, block)
+ .as_int;
#else
zeromv.as_int = 0;
#endif