diff options
author | Jeff Downs <heydowns@borg.com> | 2007-09-26 13:28:13 +0000 |
---|---|---|
committer | Andreas Ă–man <andreas@lonelycoder.com> | 2007-09-26 13:28:13 +0000 |
commit | 2ddcf84bb713f5ae2ff0f89fa361294253a822a1 (patch) | |
tree | 27a41256cb501ff20a48c8c178863d07474284b1 /libavcodec/mpegvideo.c | |
parent | b925ef61dd7b6ea847b0811b4b48abf51abd534c (diff) | |
download | ffmpeg-2ddcf84bb713f5ae2ff0f89fa361294253a822a1.tar.gz |
h264/PAFF preparation: use DELAYED_PIC_REF to mark non-refs frames as held for delayed output
patch by Jeff Downs, heydowns a borg d com
original thread:
Subject: [FFmpeg-devel] [PATCH] Implement PAFF in H.264
Date: 18/09/07 20:30
Originally committed as revision 10592 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/mpegvideo.c')
-rw-r--r-- | libavcodec/mpegvideo.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/libavcodec/mpegvideo.c b/libavcodec/mpegvideo.c index 30fb0faf07..c2c8f13d4d 100644 --- a/libavcodec/mpegvideo.c +++ b/libavcodec/mpegvideo.c @@ -907,8 +907,13 @@ alloc: pic= (AVFrame*)&s->picture[i]; } - pic->reference= (s->pict_type != B_TYPE || s->codec_id == CODEC_ID_H264) - && !s->dropable ? 3 : 0; + pic->reference= 0; + if (!s->dropable){ + if (s->codec_id == CODEC_ID_H264) + pic->reference = s->picture_structure; + else if (s->pict_type != B_TYPE) + pic->reference = 3; + } pic->coded_picture_number= s->coded_picture_number++; |