From f69574cf7aca4fe4d57a2155e925f37fc863474d Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Sat, 17 Jan 2015 22:28:46 +0100 Subject: h264: move non_zero_count_cache into the per-slice context --- libavcodec/h264.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'libavcodec/h264.c') diff --git a/libavcodec/h264.c b/libavcodec/h264.c index 8de0673122..2b29389d60 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -56,11 +56,12 @@ static void h264_er_decode_mb(void *opaque, int ref, int mv_dir, int mv_type, int mb_x, int mb_y, int mb_intra, int mb_skipped) { H264Context *h = opaque; + H264SliceContext *sl = &h->slice_ctx[0]; h->mb_x = mb_x; h->mb_y = mb_y; h->mb_xy = mb_x + mb_y * h->mb_stride; - memset(h->non_zero_count_cache, 0, sizeof(h->non_zero_count_cache)); + memset(sl->non_zero_count_cache, 0, sizeof(sl->non_zero_count_cache)); assert(ref >= 0); /* FIXME: It is possible albeit uncommon that slice references * differ between slices. We take the easy approach and ignore -- cgit v1.2.3