ref: e765435293a4aa88fe28fa67b17c581f385475a6
parent: e094e151de32659fae15b3567e5dead4a5ba310d
author: Marco <marpan@google.com>
date: Thu Sep 29 07:15:26 EDT 2016
vp9: On change_config() only call update_frame_size if needed. change_config() may be called often in real-time application, to update bitrate/framerate or qp-max/min. No need to do update_frame_size() unless frame size has changed. Change-Id: I23a51deade1e03adc91c468f9ffde3235298770c
--- a/vp9/encoder/vp9_encoder.c
+++ b/vp9/encoder/vp9_encoder.c
@@ -1481,7 +1481,9 @@
}
}
- update_frame_size(cpi);
+ if (cm->current_video_frame == 0 || last_w != cpi->oxcf.width ||
+ last_h != cpi->oxcf.height)
+ update_frame_size(cpi);
if (last_w != cpi->oxcf.width || last_h != cpi->oxcf.height) {
memset(cpi->consec_zero_mv, 0,