shithub: libvpx

Download patch

ref: d3764f7f1845034b691e2aa2a27d7a206c375334
parent: 3cf77ccef783210c323d408f625e4d3f2004b23f
parent: ff2d69573ef31cf1b85c3425551538534f5029e2
author: Ronald S. Bultje <[email protected]>
date: Tue Apr 30 13:41:57 EDT 2013

Merge "Use more restrictive block radius for 8x8 block MV references." into experimental

--- a/vp9/common/vp9_mvref_common.c
+++ b/vp9/common/vp9_mvref_common.c
@@ -13,6 +13,11 @@
 #define MVREF_NEIGHBOURS 8
 
 #if CONFIG_SB8X8
+static int b_mv_ref_search[MVREF_NEIGHBOURS][2] = {
+  {0, -1}, {-1, 0}, {-1, -1}, {0, -2},
+  {-2, 0}, {-1, -2}, {-2, -1}, {-2, -2}
+};
+
 static int mb_mv_ref_search[MVREF_NEIGHBOURS][2] = {
     {0, -1}, {-1, 0}, {-1, -1}, {0, -3},
     {-3, 0}, {-1, -3}, {-3, -1}, {-3, -3}
@@ -185,8 +190,15 @@
     mv_ref_search = sb64_mv_ref_search;
   } else if (mbmi->sb_type >= BLOCK_SIZE_SB32X32) {
     mv_ref_search = sb_mv_ref_search;
+#if CONFIG_SB8X8
+  } else if (mbmi->sb_type >= BLOCK_SIZE_MB16X16) {
+    mv_ref_search = mb_mv_ref_search;
   } else {
+    mv_ref_search = b_mv_ref_search;
+#else
+  } else {
     mv_ref_search = mb_mv_ref_search;
+#endif
   }
 
   // We first scan for candidate vectors that match the current reference frame