diff options
author | Anton Khirnov <anton@khirnov.net> | 2016-04-14 20:53:59 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2016-06-12 20:27:52 +0200 |
commit | 6dd996c7c81575a1e4969987ab175a6df7beab3d (patch) | |
tree | d856c08d3b0ebc7f2bcbdcf1e811b2c2a5828676 /libavcodec/h264_slice.c | |
parent | 0bad254300356005af4aef00a706bf2e8eee96bc (diff) |
h264: move building the reference list out of h264_slice_header_parse()
This does not do any bitstream parsing and will allow moving out other
code in later commits.
Diffstat (limited to 'libavcodec/h264_slice.c')
-rw-r--r-- | libavcodec/h264_slice.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/libavcodec/h264_slice.c b/libavcodec/h264_slice.c index 2e9587997d..0c38121827 100644 --- a/libavcodec/h264_slice.c +++ b/libavcodec/h264_slice.c @@ -1347,9 +1347,6 @@ static int h264_slice_header_parse(H264Context *h, H264SliceContext *sl) sl->ref_count[1] = sl->ref_count[0] = 0; return ret; } - ret = ff_h264_build_ref_list(h, sl); - if (ret < 0) - return ret; } sl->pwt.use_weight = 0; @@ -1449,6 +1446,10 @@ int ff_h264_decode_slice_header(H264Context *h, H264SliceContext *sl) if (ret < 0) return ret; + ret = ff_h264_build_ref_list(h, sl); + if (ret < 0) + return ret; + if (h->ps.pps->weighted_bipred_idc == 2 && sl->slice_type_nos == AV_PICTURE_TYPE_B) { implicit_weight_table(h, sl, -1); |