shithub: libvpx

Download patch

ref: 8502a95a0de1bc06fa790759511cfcf3f7049b19
parent: 8446af7e9a12c5725e845564f40272dd9185c1cc
author: Jerome Jiang <jianj@google.com>
date: Thu May 24 10:03:43 EDT 2018

VP9: Fix issues with high bitdepth in real-time.

Disable denoiser, skin detection and aq-mode for high bitdepth for now.

BUG=webm:1534

Change-Id: I361a4e20b2319041148af497bf7043bfd5c5f589

--- a/vp9/encoder/vp9_aq_cyclicrefresh.c
+++ b/vp9/encoder/vp9_aq_cyclicrefresh.c
@@ -428,7 +428,9 @@
   double weight_segment = 0;
   int thresh_low_motion = (cm->width < 720) ? 55 : 20;
   cr->apply_cyclic_refresh = 1;
-  if (cm->frame_type == KEY_FRAME || cpi->svc.temporal_layer_id > 0 ||
+  // TODO(jianj): Look into issue of cyclic refresh with high bitdepth.
+  if (cm->bit_depth > 8 || cm->frame_type == KEY_FRAME ||
+      cpi->svc.temporal_layer_id > 0 ||
       (cpi->use_svc &&
        cpi->svc.layer_context[cpi->svc.temporal_layer_id].is_key_frame) ||
       (!cpi->use_svc && rc->avg_frame_low_motion < thresh_low_motion &&
--- a/vp9/encoder/vp9_encoder.c
+++ b/vp9/encoder/vp9_encoder.c
@@ -3753,7 +3753,8 @@
     }
   }
 
-  if (cpi->oxcf.speed >= 5 && cpi->oxcf.pass == 0 &&
+  // TODO(jianj): Look into issue of skin detection with high bitdepth.
+  if (cm->bit_depth == 8 && cpi->oxcf.speed >= 5 && cpi->oxcf.pass == 0 &&
       cpi->oxcf.rc_mode == VPX_CBR &&
       cpi->oxcf.content != VP9E_CONTENT_SCREEN &&
       cpi->oxcf.aq_mode == CYCLIC_REFRESH_AQ) {
--- a/vp9/vp9_cx_iface.c
+++ b/vp9/vp9_cx_iface.c
@@ -709,6 +709,8 @@
                                                   va_list args) {
   struct vp9_extracfg extra_cfg = ctx->extra_cfg;
   extra_cfg.noise_sensitivity = CAST(VP9E_SET_NOISE_SENSITIVITY, args);
+  // TODO(jianj): Look into issue of noise estimation with high bitdepth.
+  if (ctx->cfg.g_bit_depth > 8) extra_cfg.noise_sensitivity = 0;
   return update_extra_cfg(ctx, &extra_cfg);
 }