vp9: Some adjustments to scene-cut detection. Change only affects 1 pass vbr mode, speed >=5. Increase min_thresh, decrease boost, and set a min/max value for gf_interval. Change-Id: I9c1e1a1ab0c5780064eb62714ee39a72ea4d2107
diff --git a/vp9/encoder/vp9_ratectrl.c b/vp9/encoder/vp9_ratectrl.c index ebe0810..545441b 100644 --- a/vp9/encoder/vp9_ratectrl.c +++ b/vp9/encoder/vp9_ratectrl.c
@@ -2048,7 +2048,7 @@ // for cases where there is small change from content that is completely // static. if (cpi->oxcf.rc_mode == VPX_VBR) { - min_thresh = 30000; + min_thresh = 40000; thresh = 2.0f; } if (avg_sad > @@ -2062,14 +2062,15 @@ // For VBR, under scene change/high content change, force golden refresh. if (cpi->oxcf.rc_mode == VPX_VBR && rc->high_source_sad && - cpi->refresh_golden_frame == 0 && cpi->ext_refresh_frame_flags_pending == 0) { int target; cpi->refresh_golden_frame = 1; + rc->gfu_boost = DEFAULT_GF_BOOST >> 1; + rc->baseline_gf_interval = VPXMIN(20, + VPXMAX(10, rc->baseline_gf_interval)); rc->frames_till_gf_update_due = rc->baseline_gf_interval; if (rc->frames_till_gf_update_due > rc->frames_to_key) rc->frames_till_gf_update_due = rc->frames_to_key; - rc->gfu_boost = DEFAULT_GF_BOOST; target = calc_pframe_target_size_one_pass_vbr(cpi); vp9_rc_set_frame_target(cpi, target); }