From bf73801bec57fafbf160ee10d072d64b8bb510ba Mon Sep 17 00:00:00 2001 From: Aurelien Jacobs Date: Mon, 15 Dec 2008 00:00:16 +0000 Subject: vp56: don't reset dimensions to 0 in codec init Originally committed as revision 16140 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavcodec/vp6.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'libavcodec/vp6.c') diff --git a/libavcodec/vp6.c b/libavcodec/vp6.c index d8fc0efb3a..6ffde072f7 100644 --- a/libavcodec/vp6.c +++ b/libavcodec/vp6.c @@ -75,7 +75,8 @@ static int vp6_parse_header(VP56Context *s, const uint8_t *buf, int buf_size, /* buf[4] is number of displayed macroblock rows */ /* buf[5] is number of displayed macroblock cols */ - if (16*cols != s->avctx->coded_width || + if (!s->macroblocks || /* first frame */ + 16*cols != s->avctx->coded_width || 16*rows != s->avctx->coded_height) { avcodec_set_dimensions(s->avctx, 16*cols, 16*rows); if (s->avctx->extradata_size == 1) { -- cgit v1.2.3