summaryrefslogtreecommitdiff
path: root/libavcodec/h264_refs.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-06-04 04:25:14 +0200
committerMichael Niedermayer <michaelni@gmx.at>2014-06-04 04:25:14 +0200
commit19c9d1e8e71da04c3ac940206619c0a2d01e5193 (patch)
treeb88e36b6c3c445a088eeed32b216f5eed21ef659 /libavcodec/h264_refs.c
parentfbaf73a33d505a32431ede6599f5b742ade045e1 (diff)
avcodec/h264: in the absence of recovery points, be more tolerant on accepting plain I frames
Fixes: Ticket3652 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/h264_refs.c')
-rw-r--r--libavcodec/h264_refs.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/h264_refs.c b/libavcodec/h264_refs.c
index 9bb065d24d..de1f60a41f 100644
--- a/libavcodec/h264_refs.c
+++ b/libavcodec/h264_refs.c
@@ -775,7 +775,7 @@ int ff_h264_execute_ref_pic_marking(H264Context *h, MMCO *mmco, int mmco_count)
if ( err >= 0
&& h->long_ref_count==0
&& (h->short_ref_count<=2 || h->pps.ref_count[0] <= 1 && h->pps.ref_count[1] <= 1 && pps_count == 1)
- && h->pps.ref_count[0]<=2 + (h->picture_structure != PICT_FRAME)
+ && h->pps.ref_count[0]<=2 + (h->picture_structure != PICT_FRAME) + (2*!h->has_recovery_point)
&& h->cur_pic_ptr->f.pict_type == AV_PICTURE_TYPE_I){
h->cur_pic_ptr->recovered |= 1;
if(!h->avctx->has_b_frames)