summaryrefslogtreecommitdiff
path: root/libavcodec/avrndec.c
diff options
context:
space:
mode:
authorPaul B Mahol <onemda@gmail.com>2012-12-05 18:24:43 +0000
committerPaul B Mahol <onemda@gmail.com>2012-12-05 18:24:43 +0000
commit4012cd6c4f19f09cac86c9b8c9738f27bb691764 (patch)
tree605a9342eb74f30c32ce1a772880612e7066d930 /libavcodec/avrndec.c
parent835fd779a46d14d6999618546a9833b3f2af2326 (diff)
lavc: fix decode_frame() third parameter semantics for rest of video decoders
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Diffstat (limited to 'libavcodec/avrndec.c')
-rw-r--r--libavcodec/avrndec.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/libavcodec/avrndec.c b/libavcodec/avrndec.c
index 187dad5398..0fc431d4da 100644
--- a/libavcodec/avrndec.c
+++ b/libavcodec/avrndec.c
@@ -80,7 +80,8 @@ static av_cold int end(AVCodecContext *avctx)
return 0;
}
-static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPacket *avpkt)
+static int decode_frame(AVCodecContext *avctx, void *data,
+ int *got_frame, AVPacket *avpkt)
{
AVRnContext *a = avctx->priv_data;
AVFrame *p = &a->frame;
@@ -89,7 +90,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPac
int y, ret, true_height;
if(a->is_mjpeg)
- return ff_mjpeg_decode_frame(avctx, data, data_size, avpkt);
+ return ff_mjpeg_decode_frame(avctx, data, got_frame, avpkt);
true_height = buf_size / (2*avctx->width);
if(p->data[0])
@@ -123,7 +124,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPac
}
*(AVFrame*)data = a->frame;
- *data_size = sizeof(AVFrame);
+ *got_frame = 1;
return buf_size;
}