ref: fafec95702f64520e6759eb72df53683058c5511
parent: dfcefe06fafb7570ad60c92df9d0e5d9617c3b8f
parent: a413dbe594062788335d9d6b726548a664ad58fa
author: Yunqing Wang <[email protected]>
date: Fri Aug 12 19:52:14 EDT 2016
Merge "Fix another motion vector out of range bug"
--- a/vp9/encoder/vp9_rdopt.c
+++ b/vp9/encoder/vp9_rdopt.c
@@ -2347,8 +2347,6 @@
vp9_setup_pre_planes(xd, 0, scaled_ref_frame, mi_row, mi_col, NULL);
}
- vp9_set_mv_search_range(&x->mv_limits, &ref_mv);
-
// Work out the size of the first step in the mv step search.
// 0 here is maximum length first step. 1 is VPXMAX >> 1 etc.
if (cpi->sf.mv.auto_mv_step_size && cm->show_frame) {
@@ -2395,6 +2393,10 @@
}
}
}
+
+ // Note: MV limits are modified here. Always restore the original values
+ // after full-pixel motion search.
+ vp9_set_mv_search_range(&x->mv_limits, &ref_mv);
mvp_full = pred_mv[x->mv_best_ref_index[ref]];