summaryrefslogtreecommitdiff
path: root/libavcodec/h264.c
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2016-04-13 13:52:36 +0200
committerAnton Khirnov <anton@khirnov.net>2016-04-24 10:06:25 +0200
commitb77fffa127663028169c5ed543956af4b9496c29 (patch)
tree0ad482e842fa0ce76c01ef0c452528e567148559 /libavcodec/h264.c
parent370ddc7b38d6b27b54fc2f5ee5f3dd9506f8c7c8 (diff)
h264: make slice threading work with deblocking_filter=1
In such a case, decode the MBs in parallel without the loop filter, then execute the filter serially. The ref2frm array was previously moved to H264SliceContext. That was incorrect, since it applies to all the slices and should properly be in H264Context (it did not actually break decoding, since this distinction only becomes relevant with slice threading and deblocking_filter=1, which was not implemented before this commit). The ref2frm array is thus moved back to H264Context.
Diffstat (limited to 'libavcodec/h264.c')
-rw-r--r--libavcodec/h264.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c
index c024d7e03a..27cbcd21aa 100644
--- a/libavcodec/h264.c
+++ b/libavcodec/h264.c
@@ -837,7 +837,6 @@ static int decode_nal_units(H264Context *h, const uint8_t *buf, int buf_size)
nal->ref_idc == 0 && nal->type != NAL_SEI)
continue;
-again:
// FIXME these should stop being context-global variables
h->nal_ref_idc = nal->ref_idc;
h->nal_unit_type = nal->type;
@@ -947,10 +946,6 @@ again:
if (err < 0) {
av_log(h->avctx, AV_LOG_ERROR, "decode_slice_header error\n");
sl->ref_count[0] = sl->ref_count[1] = sl->list_count = 0;
- } else if (err == 1) {
- /* Slice could not be decoded in parallel mode, restart. */
- sl = &h->slice_ctx[0];
- goto again;
}
}
if (context_count) {