summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAngie Chiang <angiebird@google.com>2019-01-29 16:00:13 -0800
committerAngie Chiang <angiebird@google.com>2019-01-29 16:00:13 -0800
commit00e49e4e6860ccfd6b9b35e2473debe0ab9551b2 (patch)
tree48560f072e4ac42f2563ba4ecbbaa3c4f0a3bdd0
parent93d1822d5f49363a0220a75d3d041ada02338b1f (diff)
downloadlibvpx-00e49e4e6860ccfd6b9b35e2473debe0ab9551b2.tar
libvpx-00e49e4e6860ccfd6b9b35e2473debe0ab9551b2.tar.gz
libvpx-00e49e4e6860ccfd6b9b35e2473debe0ab9551b2.tar.bz2
libvpx-00e49e4e6860ccfd6b9b35e2473debe0ab9551b2.zip
Fix bug in predict_mv_mode
Use kMvPreCheckLines in the for loops. Change-Id: I60204c6294560d47421a8621d907dfa95c9dde18
-rw-r--r--vp9/encoder/vp9_encoder.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/vp9/encoder/vp9_encoder.c b/vp9/encoder/vp9_encoder.c
index a6117b190..df3d86bf6 100644
--- a/vp9/encoder/vp9_encoder.c
+++ b/vp9/encoder/vp9_encoder.c
@@ -6219,7 +6219,7 @@ static void predict_mv_mode(VP9_COMP *cpi, MACROBLOCK *x,
// 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 @@ static void predict_mv_mode(VP9_COMP *cpi, MACROBLOCK *x,
&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 @@ static void predict_mv_mode(VP9_COMP *cpi, MACROBLOCK *x,
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;