]> granicus.if.org Git - libvpx/commitdiff
Condition the zbin_boost increase to 1 layer.
authorMarco Paniconi <marpan@google.com>
Tue, 4 Jun 2013 17:50:43 +0000 (10:50 -0700)
committerMarco Paniconi <marpan@google.com>
Tue, 4 Jun 2013 21:19:52 +0000 (14:19 -0700)
Condition the existing zbin boost logic for gf/altf mode to temporal layers==1,
since gf/altf reference frames are used in temporal layers as reference frames.

Change-Id: I618bb20730e5f193e078215d06f54997c363dd7b

vp8/encoder/encodeframe.c

index 5baeb3c5ba2a1443ac0740d464a749926d04c02c..b550f6be1cfd5a143958a46fb3e129ead227518c 100644 (file)
@@ -1299,8 +1299,9 @@ int vp8cx_encode_inter_macroblock
     }
 
     {
-        /* Experimental code. Special case for gf and arf zeromv modes.
-         * Increase zbin size to supress noise
+        /* Experimental code.
+         * Special case for gf and arf zeromv modes, for 1 temporal layer.
+         * Increase zbin size to supress noise.
          */
         x->zbin_mode_boost = 0;
         if (x->zbin_mode_boost_enabled)
@@ -1309,7 +1310,8 @@ int vp8cx_encode_inter_macroblock
             {
                 if (xd->mode_info_context->mbmi.mode == ZEROMV)
                 {
-                    if (xd->mode_info_context->mbmi.ref_frame != LAST_FRAME)
+                    if (xd->mode_info_context->mbmi.ref_frame != LAST_FRAME &&
+                        cpi->oxcf.number_of_layers == 1)
                         x->zbin_mode_boost = GF_ZEROMV_ZBIN_BOOST;
                     else
                         x->zbin_mode_boost = LF_ZEROMV_ZBIN_BOOST;