From: Alex Converse Date: Wed, 17 Aug 2016 21:20:34 +0000 (-0700) Subject: Don't send segment probability updates when the map isn't updated. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=fd96aec9c69c9a24290dc990c7c81a67f92dd57f;p=libvpx Don't send segment probability updates when the map isn't updated. BUG=webm:1275 Change-Id: I7d4bbaaf2f2146b023e1902fbc535a70e490cf2d --- diff --git a/vp10/decoder/decodeframe.c b/vp10/decoder/decodeframe.c index 4c2054a62..67f685f8d 100644 --- a/vp10/decoder/decodeframe.c +++ b/vp10/decoder/decodeframe.c @@ -3462,7 +3462,7 @@ static int read_compressed_header(VP10Decoder *pbi, const uint8_t *data, for (k = 0; k < SKIP_CONTEXTS; ++k) vp10_diff_update_prob(&r, &fc->skip_probs[k]); - if (cm->seg.enabled) { + if (cm->seg.enabled && cm->seg.update_map) { if (cm->seg.temporal_update) { for (k = 0; k < PREDICTION_PROBS; k++) vp10_diff_update_prob(&r, &cm->fc->seg.pred_probs[k]); diff --git a/vp10/encoder/bitstream.c b/vp10/encoder/bitstream.c index 81d8991f6..d89a52e56 100644 --- a/vp10/encoder/bitstream.c +++ b/vp10/encoder/bitstream.c @@ -2543,9 +2543,9 @@ static void encode_segmentation(VP10_COMMON *cm, MACROBLOCKD *xd, static void update_seg_probs(VP10_COMP *cpi, vp10_writer *w) { VP10_COMMON *cm = &cpi->common; - if (!cpi->common.seg.enabled) return; + if (!cm->seg.enabled || !cm->seg.update_map) return; - if (cpi->common.seg.temporal_update) { + if (cm->seg.temporal_update) { int i; for (i = 0; i < PREDICTION_PROBS; i++)