summaryrefslogtreecommitdiff
path: root/libavcodec/svq1.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2002-07-16 10:19:00 +0000
committerMichael Niedermayer <michaelni@gmx.at>2002-07-16 10:19:00 +0000
commit22b13d5b4c5d4aa2ee234a7ba00b453036e4419e (patch)
tree8a92dc49e9503a3f4184389509762b3746009a0b /libavcodec/svq1.c
parent3cf33c37e7bd9287c9de81bc2ec205237959c423 (diff)
grayscale only decoding
Originally committed as revision 766 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/svq1.c')
-rw-r--r--libavcodec/svq1.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/svq1.c b/libavcodec/svq1.c
index 910a31b32c..b43b10af37 100644
--- a/libavcodec/svq1.c
+++ b/libavcodec/svq1.c
@@ -2586,6 +2586,7 @@ static int svq1_decode_frame(AVCodecContext *avctx,
height = (s->height+15)&~15;
linesize= s->linesize;
} else {
+ if(s->flags&CODEC_FLAG_GRAY) break;
width = (s->width/4+15)&~15;
height = (s->height/4+15)&~15;
linesize= s->uvlinesize;
@@ -2658,6 +2659,7 @@ static int svq1_decode_init(AVCodecContext *avctx)
avctx->mbskip_table= s->mbskip_table;
avctx->pix_fmt = PIX_FMT_YUV410P;
avctx->has_b_frames= s->has_b_frames=1; // not true, but DP frames and these behave like unidirectional b frames
+ s->flags= avctx->flags;
if (MPV_common_init(s) < 0) return -1;
return 0;
}