diff options
author | Timothy Gu <timothygu99@gmail.com> | 2016-08-03 19:46:06 -0700 |
---|---|---|
committer | Timothy Gu <timothygu99@gmail.com> | 2016-08-03 19:50:06 -0700 |
commit | de625312862a99500ce7aa1703b5d783ae66d704 (patch) | |
tree | 0590e6448b83540302ca747e80d3ee7309a088c4 /libavcodec/h264dec.c | |
parent | e0c8250a59adbf7135adb870be275df05a61e052 (diff) | |
parent | e26c64148be8a20ace7512d96503172fb5e9753b (diff) | |
download | ffmpeg-de625312862a99500ce7aa1703b5d783ae66d704.tar.gz |
Merge commit 'e26c64148be8a20ace7512d96503172fb5e9753b'
* commit 'e26c64148be8a20ace7512d96503172fb5e9753b':
h264: discard slices of redundant pictures right after parsing the slice header
Conflicts:
libavcodec/h264_slice.c
libavcodec/h264dec.c
TODO: fix indentation
Merged-by: Timothy Gu <timothygu99@gmail.com>
Diffstat (limited to 'libavcodec/h264dec.c')
-rw-r--r-- | libavcodec/h264dec.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/libavcodec/h264dec.c b/libavcodec/h264dec.c index 977977431e..c72a7fcc16 100644 --- a/libavcodec/h264dec.c +++ b/libavcodec/h264dec.c @@ -799,6 +799,9 @@ again: if ((err = ff_h264_decode_slice_header(h, sl, nal))) break; + if (sl->redundant_pic_count > 0) + break; + if (h->sei.recovery_point.recovery_frame_cnt >= 0) { const int sei_recovery_frame_cnt = h->sei.recovery_point.recovery_frame_cnt; @@ -845,7 +848,6 @@ again: #endif } - if (sl->redundant_pic_count == 0) { if (avctx->hwaccel) { ret = avctx->hwaccel->decode_slice(avctx, nal->raw_data, @@ -864,7 +866,6 @@ again: #endif } else context_count++; - } break; case H264_NAL_DPA: case H264_NAL_DPB: |