shithub: libvpx

Download patch

ref: f6097ef2432221e916b8e37a20b8508f9b7cb018
parent: eb53c69ece6b97f65afed81fd4c2ef9624501ea7
parent: 15c43d9ac78785036f84ef35c6418b3db93ed4a0
author: Marco Paniconi <marpan@google.com>
date: Tue Sep 15 18:06:13 EDT 2015

Merge "SVC fix to set worst/best_quality per layer."

--- a/vp9/encoder/vp9_svc_layercontext.c
+++ b/vp9/encoder/vp9_svc_layercontext.c
@@ -554,6 +554,14 @@
                                cpi->svc.number_temporal_layers +
                                cpi->svc.temporal_layer_id];
 
+  // Setting the worst/best_quality via the encoder control: SET_SVC_PARAMETERS,
+  // only for non-BYPASS mode for now.
+  if (cpi->svc.temporal_layering_mode != VP9E_TEMPORAL_LAYERING_MODE_BYPASS) {
+    RATE_CONTROL *const lrc = &lc->rc;
+    lrc->worst_quality = vp9_quantizer_to_qindex(lc->max_q);
+    lrc->best_quality =  vp9_quantizer_to_qindex(lc->min_q);
+  }
+
   get_layer_resolution(cpi->oxcf.width, cpi->oxcf.height,
                        lc->scaling_factor_num, lc->scaling_factor_den,
                        &width, &height);