summaryrefslogtreecommitdiff
path: root/libavcodec/vp5.c
diff options
context:
space:
mode:
authorAurelien Jacobs <aurel@gnuage.org>2008-12-15 00:00:16 +0000
committerAurelien Jacobs <aurel@gnuage.org>2008-12-15 00:00:16 +0000
commitbf73801bec57fafbf160ee10d072d64b8bb510ba (patch)
tree5920fb567b7f16893be3d11b73c75d0aa6ead9c5 /libavcodec/vp5.c
parentb9b2b8c93b40a2d96f25362e9c8d7611d0adc3c7 (diff)
downloadffmpeg-bf73801bec57fafbf160ee10d072d64b8bb510ba.tar.gz
vp56: don't reset dimensions to 0 in codec init
Originally committed as revision 16140 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/vp5.c')
-rw-r--r--libavcodec/vp5.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/vp5.c b/libavcodec/vp5.c
index 7b39c81cb4..e47db0d2c1 100644
--- a/libavcodec/vp5.c
+++ b/libavcodec/vp5.c
@@ -58,7 +58,8 @@ static int vp5_parse_header(VP56Context *s, const uint8_t *buf, int buf_size,
vp56_rac_gets(c, 8); /* number of displayed macroblock rows */
vp56_rac_gets(c, 8); /* number of displayed macroblock cols */
vp56_rac_gets(c, 2);
- 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);
return 2;