VP8: Adjust rate correction factor for drop due to overshoot.
Change-Id: Id70ca2e18a46247720eb631ae13a8430bd8b0954
This commit is contained in:
@@ -1596,6 +1596,10 @@ int vp8_drop_encodedframe_overshoot(VP8_COMP *cpi, int Q) {
|
|||||||
// Drop this frame: advance frame counters, and set force_maxqp flag.
|
// Drop this frame: advance frame counters, and set force_maxqp flag.
|
||||||
cpi->common.current_video_frame++;
|
cpi->common.current_video_frame++;
|
||||||
cpi->frames_since_key++;
|
cpi->frames_since_key++;
|
||||||
|
// Adjust rate correction factor upwards.
|
||||||
|
cpi->rate_correction_factor *= 2.0;
|
||||||
|
if (cpi->rate_correction_factor > MAX_BPB_FACTOR)
|
||||||
|
cpi->rate_correction_factor = MAX_BPB_FACTOR;
|
||||||
// Flag to indicate we will force next frame to be encoded at max QP.
|
// Flag to indicate we will force next frame to be encoded at max QP.
|
||||||
cpi->force_maxqp = 1;
|
cpi->force_maxqp = 1;
|
||||||
return 1;
|
return 1;
|
||||||
|
Reference in New Issue
Block a user