shithub: libvpx

Download patch

ref: 00e49e4e6860ccfd6b9b35e2473debe0ab9551b2
parent: 93d1822d5f49363a0220a75d3d041ada02338b1f
author: Angie Chiang <angiebird@google.com>
date: Tue Jan 29 11:00:13 EST 2019

Fix bug in predict_mv_mode

Use kMvPreCheckLines in the for loops.

Change-Id: I60204c6294560d47421a8621d907dfa95c9dde18

--- a/vp9/encoder/vp9_encoder.c
+++ b/vp9/encoder/vp9_encoder.c
@@ -6219,7 +6219,7 @@
   // no new mv
   // diagnal scan order
   tmp_idx = 0;
-  for (idx = 0; idx < kMvPreCheckSize; ++idx) {
+  for (idx = 0; idx < kMvPreCheckLines; ++idx) {
     int r;
     for (r = 0; r <= idx; ++r) {
       int c = idx - r;
@@ -6246,7 +6246,7 @@
                            &select_mv_arr[mi_row * stride + mi_col]);
   // We start from idx = 1 because idx = 0 is evaluated as NEW_MV_MODE
   // beforehand.
-  for (idx = 1; idx < kMvPreCheckSize; ++idx) {
+  for (idx = 1; idx < kMvPreCheckLines; ++idx) {
     int r;
     for (r = 0; r <= idx; ++r) {
       int c = idx - r;
@@ -6267,7 +6267,7 @@
   tmp_idx = 0;
   if (no_new_mv_rd < new_mv_rd) {
     *rd = no_new_mv_rd;
-    for (idx = 0; idx < kMvPreCheckSize; ++idx) {
+    for (idx = 0; idx < kMvPreCheckLines; ++idx) {
       int r;
       for (r = 0; r <= idx; ++r) {
         int c = idx - r;