Index: source/libvpx/vp9/encoder/vp9_encoder.c |
diff --git a/source/libvpx/vp9/encoder/vp9_encoder.c b/source/libvpx/vp9/encoder/vp9_encoder.c |
index d9ecb9a1cd534866762e222eb43e63f42e044b36..02cafe5cbd29958c263990757be701258f9251a6 100644 |
--- a/source/libvpx/vp9/encoder/vp9_encoder.c |
+++ b/source/libvpx/vp9/encoder/vp9_encoder.c |
@@ -686,7 +686,7 @@ static int alloc_context_buffers_ext(VP9_COMP *cpi) { |
return 0; |
} |
-void vp9_alloc_compressor_data(VP9_COMP *cpi) { |
+static void alloc_compressor_data(VP9_COMP *cpi) { |
VP9_COMMON *cm = &cpi->common; |
vp9_alloc_context_buffers(cm, cm->width, cm->height); |
@@ -775,7 +775,7 @@ static void init_config(struct VP9_COMP *cpi, VP9EncoderConfig *oxcf) { |
cm->width = oxcf->width; |
cm->height = oxcf->height; |
- vp9_alloc_compressor_data(cpi); |
+ alloc_compressor_data(cpi); |
cpi->svc.temporal_layering_mode = oxcf->temporal_layering_mode; |
@@ -1510,7 +1510,7 @@ void vp9_change_config(struct VP9_COMP *cpi, const VP9EncoderConfig *oxcf) { |
if (cpi->initial_width) { |
if (cm->width > cpi->initial_width || cm->height > cpi->initial_height) { |
vp9_free_context_buffers(cm); |
- vp9_alloc_compressor_data(cpi); |
+ alloc_compressor_data(cpi); |
realloc_segmentation_maps(cpi); |
cpi->initial_width = cpi->initial_height = 0; |
} |
@@ -3270,6 +3270,7 @@ static void encode_without_recode_loop(VP9_COMP *cpi, |
if (cpi->oxcf.aq_mode == CYCLIC_REFRESH_AQ && |
cm->frame_type != KEY_FRAME && |
!cpi->use_svc && |
+ cpi->ext_refresh_frame_flags_pending == 0 && |
(cpi->oxcf.pass == 0 && cpi->oxcf.rc_mode == VPX_CBR)) |
vp9_cyclic_refresh_check_golden_update(cpi); |
@@ -3578,7 +3579,6 @@ static void set_ext_overrides(VP9_COMP *cpi) { |
cpi->refresh_last_frame = cpi->ext_refresh_last_frame; |
cpi->refresh_golden_frame = cpi->ext_refresh_golden_frame; |
cpi->refresh_alt_ref_frame = cpi->ext_refresh_alt_ref_frame; |
- cpi->ext_refresh_frame_flags_pending = 0; |
} |
} |
@@ -3747,6 +3747,7 @@ static void encode_frame_to_data_rate(VP9_COMP *cpi, |
if (vp9_rc_drop_frame(cpi)) { |
vp9_rc_postencode_update_drop_frame(cpi); |
++cm->current_video_frame; |
+ cpi->ext_refresh_frame_flags_pending = 0; |
return; |
} |
} |
@@ -3828,6 +3829,8 @@ static void encode_frame_to_data_rate(VP9_COMP *cpi, |
} |
} |
+ cpi->ext_refresh_frame_flags_pending = 0; |
+ |
if (cpi->refresh_golden_frame == 1) |
cpi->frame_flags |= FRAMEFLAGS_GOLDEN; |
else |