]> granicus.if.org Git - libvpx/commitdiff
disable segmentation on enhancement layers
authorJim Bankoski <jimbankoski@google.com>
Mon, 24 Sep 2012 14:53:26 +0000 (07:53 -0700)
committerJim Bankoski <jimbankoski@google.com>
Mon, 24 Sep 2012 14:53:26 +0000 (07:53 -0700)
This should avoid problems with blocks gettings high quality
improvement despite having recently moved:

Change-Id: Ic0af0de2d6577807fa3c553f47b55d547ef36359

vp8/encoder/onyx_if.c

index 488558791d6191d61c93e47727669704a122395a..9171d0752a788feec112a70ff846636f45bdf0ac 100644 (file)
@@ -3777,8 +3777,13 @@ static void encode_frame_to_data_rate
     /* Setup background Q adjustment for error resilient mode.
      * For multi-layer encodes only enable this for the base layer.
      */
-    if (cpi->cyclic_refresh_mode_enabled && (cpi->current_layer==0))
+    if (cpi->cyclic_refresh_mode_enabled)
+    {
+      if (cpi->current_layer==0)
         cyclic_background_refresh(cpi, Q, 0);
+      else
+        disable_segmentation(cpi);
+    }
 
     vp8_compute_frame_size_bounds(cpi, &frame_under_shoot_limit, &frame_over_shoot_limit);
 
@@ -3933,8 +3938,13 @@ static void encode_frame_to_data_rate
                * and background refresh.
                */
               Q = vp8_regulate_q(cpi, cpi->this_frame_target);
-              if (cpi->cyclic_refresh_mode_enabled && (cpi->current_layer==0))
-                cyclic_background_refresh(cpi, Q, 0);
+              if (cpi->cyclic_refresh_mode_enabled)
+              {
+                if (cpi->current_layer==0)
+                  cyclic_background_refresh(cpi, Q, 0);
+                else
+                  disable_segmentation(cpi);
+              }
               vp8_set_quantizer(cpi, Q);
             }