From: Marco Date: Wed, 29 Nov 2017 20:48:20 +0000 (-0800) Subject: vp9-svc: Clean conditon for allowing copy_partition. X-Git-Tag: v1.7.0~47 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=0e945223382694cf62a6fcd18b0b8e4970e90345;p=libvpx vp9-svc: Clean conditon for allowing copy_partition. Make condition explicit on non_reference_frame. No change in behavior. Change-Id: Iec5068bccd93c7c7be67634c5c090580b2dbb20d --- diff --git a/vp9/encoder/vp9_encodeframe.c b/vp9/encoder/vp9_encodeframe.c index d46a76074..dfeaa3e51 100644 --- a/vp9/encoder/vp9_encodeframe.c +++ b/vp9/encoder/vp9_encodeframe.c @@ -907,10 +907,7 @@ static int copy_partitioning(VP9_COMP *cpi, MACROBLOCK *x, MACROBLOCKD *xd, int layer = LAYER_IDS_TO_IDX(0, cpi->svc.temporal_layer_id, cpi->svc.number_temporal_layers); const LAYER_CONTEXT *lc = &cpi->svc.layer_context[layer]; - if (lc->is_key_frame || - (cpi->svc.temporal_layer_id != cpi->svc.number_temporal_layers - 1 && - cpi->svc.number_temporal_layers > 1)) - svc_copy_allowed = 0; + if (lc->is_key_frame || !cpi->svc.non_reference_frame) svc_copy_allowed = 0; frames_since_key_thresh = cpi->svc.number_spatial_layers << 1; } if (cpi->rc.frames_since_key > frames_since_key_thresh && svc_copy_allowed &&