diff options
author | Baptiste Coudurier <baptiste.coudurier@gmail.com> | 2007-03-14 11:12:02 +0000 |
---|---|---|
committer | Baptiste Coudurier <baptiste.coudurier@gmail.com> | 2007-03-14 11:12:02 +0000 |
commit | 1153be3be15f0eccbb5055839185c5bf2425bd79 (patch) | |
tree | 32a0ca2963d4e694fb28e0a211fcabe65a5f0b43 /libavcodec/h264.c | |
parent | 08cb1950209b53bf98bf2014ca584a6b0e138917 (diff) | |
download | ffmpeg-streaming-1153be3be15f0eccbb5055839185c5bf2425bd79.zip ffmpeg-streaming-1153be3be15f0eccbb5055839185c5bf2425bd79.tar.gz |
h264 complete frames parsing support
Originally committed as revision 8398 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/h264.c')
-rw-r--r-- | libavcodec/h264.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c index 10beead..70ec5d3 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -8048,6 +8048,9 @@ static int h264_parse(AVCodecParserContext *s, ParseContext *pc = &h->s.parse_context; int next; + if(s->flags & PARSER_FLAG_COMPLETE_FRAMES){ + next= buf_size; + }else{ next= find_frame_end(h, buf, buf_size); if (ff_combine_frame(pc, next, (uint8_t **)&buf, &buf_size) < 0) { @@ -8059,6 +8062,7 @@ static int h264_parse(AVCodecParserContext *s, if(next<0){ find_frame_end(h, &pc->buffer[pc->last_index + next], -next); //update state } + } *poutbuf = (uint8_t *)buf; *poutbuf_size = buf_size; |