diff options
author | Marco Paniconi <marpan@google.com> | 2019-09-20 08:45:04 -0700 |
---|---|---|
committer | Marco Paniconi <marpan@google.com> | 2019-09-20 08:56:47 -0700 |
commit | b8d86733e9d9c58e17028720751f96dad2df7a09 (patch) | |
tree | ceb502a10fe3a0772792e1d9fd15ac2aaa4fac32 /vp9/encoder/vp9_encoder.c | |
parent | 616f02c1700e54d584e93b9071e56ef9ecc5b05a (diff) | |
download | libvpx-b8d86733e9d9c58e17028720751f96dad2df7a09.tar libvpx-b8d86733e9d9c58e17028720751f96dad2df7a09.tar.gz libvpx-b8d86733e9d9c58e17028720751f96dad2df7a09.tar.bz2 libvpx-b8d86733e9d9c58e17028720751f96dad2df7a09.zip |
vp9-svc: Fix to forced key frame for spatial layers
Condition to disallow key frames on spatial
enhancement layers should be based on the
first_spatial_layer_to_encode, which need not be
layer 0.
Change-Id: If6bc67568151c38c9c98290e5838a23b3ab18e8a
Diffstat (limited to 'vp9/encoder/vp9_encoder.c')
-rw-r--r-- | vp9/encoder/vp9_encoder.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/vp9/encoder/vp9_encoder.c b/vp9/encoder/vp9_encoder.c index 8729cdf4a..5bbb90f23 100644 --- a/vp9/encoder/vp9_encoder.c +++ b/vp9/encoder/vp9_encoder.c @@ -7356,10 +7356,11 @@ int vp9_get_compressed_data(VP9_COMP *cpi, unsigned int *frame_flags, if (source != NULL) { cm->show_frame = 1; cm->intra_only = 0; - // if the flags indicate intra frame, but if the current picture is for - // non-zero spatial layer, it should not be an intra picture. + // If the flags indicate intra frame, but if the current picture is for + // spatial layer above first_spatial_layer_to_encode, it should not be an + // intra picture. if ((source->flags & VPX_EFLAG_FORCE_KF) && cpi->use_svc && - cpi->svc.spatial_layer_id > 0) { + cpi->svc.spatial_layer_id > cpi->svc.first_spatial_layer_to_encode) { source->flags &= ~(unsigned int)(VPX_EFLAG_FORCE_KF); } |