diff options
Diffstat (limited to 'libavcodec/h263dec.c')
-rw-r--r-- | libavcodec/h263dec.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/libavcodec/h263dec.c b/libavcodec/h263dec.c index 98215bf..cc3bff1 100644 --- a/libavcodec/h263dec.c +++ b/libavcodec/h263dec.c @@ -325,14 +325,16 @@ static int mpeg4_find_frame_end(MpegEncContext *s, uint8_t *buf, int buf_size){ } } } - - for(; i<buf_size; i++){ + + if(vop_found){ + for(; i<buf_size; i++){ state= (state<<8) | buf[i]; if((state&0xFFFFFF00) == 0x100){ pc->frame_start_found=0; pc->state=-1; return i-3; } + } } pc->frame_start_found= vop_found; pc->state= state; |