aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorDavid Conrad <lessen42@gmail.com>2010-03-09 00:29:26 +0000
committerDavid Conrad <lessen42@gmail.com>2010-03-09 00:29:26 +0000
commitff65969fd86dbeb545e6eba8fce153e4aa42a2a1 (patch)
tree2c5d82691b7746e87120692893db96ddc4c7932c /libavcodec
parent7a4e8b59131cccd750cfcb78e41049982c66c1aa (diff)
downloadffmpeg-ff65969fd86dbeb545e6eba8fce153e4aa42a2a1.tar.gz
vp3: Set pict_type
Originally committed as revision 22361 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/vp3.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/vp3.c b/libavcodec/vp3.c
index 01438097b8..9e99ddebdc 100644
--- a/libavcodec/vp3.c
+++ b/libavcodec/vp3.c
@@ -1810,6 +1810,7 @@ static int vp3_decode_frame(AVCodecContext *avctx,
return buf_size;
s->current_frame.reference = 3;
+ s->current_frame.pict_type = s->keyframe ? FF_I_TYPE : FF_P_TYPE;
if (avctx->get_buffer(avctx, &s->current_frame) < 0) {
av_log(s->avctx, AV_LOG_ERROR, "get_buffer() failed\n");
goto error;
@@ -1836,7 +1837,9 @@ static int vp3_decode_frame(AVCodecContext *avctx,
} else {
if (!s->golden_frame.data[0]) {
av_log(s->avctx, AV_LOG_WARNING, "vp3: first frame not a keyframe\n");
+
s->golden_frame.reference = 3;
+ s->golden_frame.pict_type = FF_I_TYPE;
if (avctx->get_buffer(avctx, &s->golden_frame) < 0) {
av_log(s->avctx, AV_LOG_ERROR, "get_buffer() failed\n");
goto error;