diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2008-07-19 03:13:11 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2008-07-19 03:13:11 +0000 |
commit | 0ab515e9353181d8fe7eb42cf6123dcb06c47edf (patch) | |
tree | fe90ed597f06a67b96a3cd8a8cb2c0ab1f42a558 /libavcodec/h264.c | |
parent | 7645da9194a5e06b5811e50c74ba506e4a762692 (diff) | |
download | ffmpeg-0ab515e9353181d8fe7eb42cf6123dcb06c47edf.tar.gz |
simplify
Originally committed as revision 14291 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/h264.c')
-rw-r--r-- | libavcodec/h264.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c index 02f71d5bf4..725dc33244 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -7855,9 +7855,6 @@ static int decode_frame(AVCodecContext *avctx, out_of_order = !cross_idr && out->poc < h->outputed_poc; - if(pics <= s->avctx->has_b_frames || out_of_order) - out = NULL; - if(h->sps.bitstream_restriction_flag && s->avctx->has_b_frames >= h->sps.num_reorder_frames) { } else if((out_of_order && pics-1 == s->avctx->has_b_frames && pics < 15) @@ -7867,9 +7864,11 @@ static int decode_frame(AVCodecContext *avctx, { s->low_delay = 0; s->avctx->has_b_frames++; - out= NULL; } + if(pics <= s->avctx->has_b_frames || out_of_order) + out = NULL; + if(out_of_order || pics > s->avctx->has_b_frames){ for(i=out_idx; h->delayed_pic[i]; i++) h->delayed_pic[i] = h->delayed_pic[i+1]; |