From a8fa1bde720a8ab36eea27bbefe9a7f99b0737b3 Mon Sep 17 00:00:00 2001 From: Marco Paniconi Date: Fri, 17 May 2019 10:50:42 -0700 Subject: [PATCH] vp9-rtc: Increase qp thresh for overshoot detection For video mode (non-screen) in CBR real-time mode: increase the qp thresh to trigger setting to active_worst on scene changes. Avoid big overshoots in content with scene changes. Change-Id: I74721b07b0d7b742cbef468ece70cca7da0f89eb --- vp9/encoder/vp9_ratectrl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vp9/encoder/vp9_ratectrl.c b/vp9/encoder/vp9_ratectrl.c index e764124..c0d84f7 100644 --- a/vp9/encoder/vp9_ratectrl.c +++ b/vp9/encoder/vp9_ratectrl.c @@ -3044,7 +3044,7 @@ int vp9_encodedframe_overshoot(VP9_COMP *cpi, int frame_size, int *q) { // Lower thresh_qp for video (more overshoot at lower Q) to be // more conservative for video. if (cpi->oxcf.content != VP9E_CONTENT_SCREEN) - thresh_qp = rc->worst_quality >> 1; + thresh_qp = 3 * (rc->worst_quality >> 2); // If this decision is not based on an encoded frame size but just on // scene/slide change detection (i.e., re_encode_overshoot_cbr_rt == // FAST_DETECTION_MAXQ), for now skip the (frame_size > thresh_rate) -- 2.7.4