gecko-dev/media/libvpx/I9713c9f0.patch

34 строки
1.3 KiB
Diff

# HG changeset patch
# Parent d0bb669a2e26f138d416333b21f55151503dcdf9
# User Timothy B. Terriberry <tterribe@vt.edu>
decoder: reset segmentation map on keyframes
Upstream Change-Id: I9713c9f070eb37b31b3b029d9ef96be9b6ea2def
diff --git a/media/libvpx/vp8/decoder/decodframe.c b/media/libvpx/vp8/decoder/decodframe.c
--- a/media/libvpx/vp8/decoder/decodframe.c
+++ b/media/libvpx/vp8/decoder/decodframe.c
@@ -830,16 +830,22 @@ int vp8_decode_frame(VP8D_COMP *pbi)
for (i = 0; i < MB_FEATURE_TREE_PROBS; i++)
{
/* If not explicitly set value is defaulted to 255 by memset above */
if (vp8_read_bit(bc))
xd->mb_segment_tree_probs[i] = (vp8_prob)vp8_read_literal(bc, 8);
}
}
}
+ else
+ {
+ /* No segmentation updates on this frame */
+ xd->update_mb_segmentation_map = 0;
+ xd->update_mb_segmentation_data = 0;
+ }
/* Read the loop filter level and type */
pc->filter_type = (LOOPFILTERTYPE) vp8_read_bit(bc);
pc->filter_level = vp8_read_literal(bc, 6);
pc->sharpness_level = vp8_read_literal(bc, 3);
/* Read in loop filter deltas applied at the MB level based on mode or ref frame. */
xd->mode_ref_lf_delta_update = 0;