diff options
author | Anton Khirnov <anton@khirnov.net> | 2015-01-17 22:28:46 +0100 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2015-03-21 11:27:15 +0100 |
commit | bc98e8c0e0a8babfea35c98855e366b29cbe1191 (patch) | |
tree | 0dbf428535cd1236545a6c31b3d3f57c7d65b911 /libavcodec/h264_slice.c | |
parent | 6490a0c0fbe0e55f765ea2aa2e8495181ea1f719 (diff) | |
download | ffmpeg-bc98e8c0e0a8babfea35c98855e366b29cbe1191.tar.gz |
h264: move mb_field_decoding_flag into the per-slice context
Diffstat (limited to 'libavcodec/h264_slice.c')
-rw-r--r-- | libavcodec/h264_slice.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libavcodec/h264_slice.c b/libavcodec/h264_slice.c index 7ad25b9cb2..218c968fee 100644 --- a/libavcodec/h264_slice.c +++ b/libavcodec/h264_slice.c @@ -1373,7 +1373,7 @@ int ff_h264_decode_slice_header(H264Context *h, H264SliceContext *sl, H264Contex h->mb_aff_frame = h->sps.mb_aff; } } - h->mb_field_decoding_flag = h->picture_structure != PICT_FRAME; + sl->mb_field_decoding_flag = h->picture_structure != PICT_FRAME; if (h0->current_slice != 0) { if (last_pic_structure != h->picture_structure || @@ -1914,7 +1914,7 @@ static int fill_filter_caches(H264Context *h, H264SliceContext *sl, int mb_type) uint8_t *nnz; uint8_t *nnz_cache; - top_xy = mb_xy - (h->mb_stride << MB_FIELD(h)); + top_xy = mb_xy - (h->mb_stride << MB_FIELD(sl)); /* Wow, what a mess, why didn't they simplify the interlacing & intra * stuff, I can't imagine that these complex rules are worth it. */ @@ -2071,7 +2071,7 @@ static void loop_filter(H264Context *h, H264SliceContext *sl, int start_x, int e if (FRAME_MBAFF(h)) h->mb_mbaff = - h->mb_field_decoding_flag = !!IS_INTERLACED(mb_type); + sl->mb_field_decoding_flag = !!IS_INTERLACED(mb_type); sl->mb_x = mb_x; sl->mb_y = mb_y; @@ -2085,7 +2085,7 @@ static void loop_filter(H264Context *h, H264SliceContext *sl, int start_x, int e mb_y * h->uvlinesize * block_h; // FIXME simplify above - if (MB_FIELD(h)) { + if (MB_FIELD(sl)) { linesize = sl->mb_linesize = h->linesize * 2; uvlinesize = sl->mb_uvlinesize = h->uvlinesize * 2; if (mb_y & 1) { // FIXME move out of this function? @@ -2127,7 +2127,7 @@ static void predict_field_decoding_flag(H264Context *h, H264SliceContext *sl) h->cur_pic.mb_type[mb_xy - 1] : (h->slice_table[mb_xy - h->mb_stride] == sl->slice_num) ? h->cur_pic.mb_type[mb_xy - h->mb_stride] : 0; - h->mb_mbaff = h->mb_field_decoding_flag = IS_INTERLACED(mb_type) ? 1 : 0; + h->mb_mbaff = sl->mb_field_decoding_flag = IS_INTERLACED(mb_type) ? 1 : 0; } /** |