Merge "Simplifying vp9_is_upper_layer_key_frame()."

This commit is contained in:
Dmitry Kovalev
2014-05-01 18:27:56 -07:00
committed by Gerrit Code Review

View File

@@ -221,15 +221,9 @@ void vp9_inc_frame_in_layer(SVC *svc) {
++lc->current_video_frame_in_layer; ++lc->current_video_frame_in_layer;
} }
int vp9_is_upper_layer_key_frame(const struct VP9_COMP *const cpi) { int vp9_is_upper_layer_key_frame(const VP9_COMP *cpi) {
int is_upper_layer_key_frame = 0; return cpi->use_svc &&
cpi->svc.number_temporal_layers == 1 &&
if (cpi->use_svc && cpi->svc.number_temporal_layers == 1 && cpi->svc.spatial_layer_id > 0 &&
cpi->svc.spatial_layer_id > 0) { cpi->svc.layer_context[cpi->svc.spatial_layer_id].is_key_frame;
if (cpi->svc.layer_context[cpi->svc.spatial_layer_id].is_key_frame) {
is_upper_layer_key_frame = 1;
}
}
return is_upper_layer_key_frame;
} }