[FFmpeg-cvslog] vc1: fix decoding when end sequence is present

Baptiste Coudurier git
Thu Mar 3 18:23:05 CET 2011


ffmpeg | branch: master | Baptiste Coudurier <baptiste.coudurier at gmail.com> | Wed Mar  2 11:17:33 2011 +0000| [4778b4dd77643267639d824ea33964ee7a98439d] | committer: Michael Niedermayer

vc1: fix decoding when end sequence is present

Signed-off-by: Mans Rullgard <mans at mansr.com>
(cherry picked from commit fb985071263e6b3daff1c3d987df482b0146c2a0)

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=4778b4dd77643267639d824ea33964ee7a98439d
---

 libavcodec/vc1dec.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/libavcodec/vc1dec.c b/libavcodec/vc1dec.c
index ed92d8c..b27b6d0 100644
--- a/libavcodec/vc1dec.c
+++ b/libavcodec/vc1dec.c
@@ -3149,7 +3149,7 @@ static int vc1_decode_frame(AVCodecContext *avctx,
     const uint8_t *buf_start = buf;
 
     /* no supplementary picture */
-    if (buf_size == 0) {
+    if (buf_size == 0 || (buf_size == 4 && AV_RB32(buf) == VC1_CODE_ENDOFSEQ)) {
         /* special case for last picture */
         if (s->low_delay==0 && s->next_picture_ptr) {
             *pict= *(AVFrame*)s->next_picture_ptr;




More information about the ffmpeg-cvslog mailing list