]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/xl.c
imgconvert: fix 2 "discards const qualifier from pointer target type"
[ffmpeg] / libavcodec / xl.c
index 8c5ccd387a6ab2d9798e8820038369be6d45a358..df354893a5fda435f742607e41bae166c1612e66 100644 (file)
@@ -27,6 +27,7 @@
 #include "libavutil/common.h"
 #include "libavutil/intreadwrite.h"
 #include "avcodec.h"
+#include "internal.h"
 
 typedef struct VideoXLContext{
     AVCodecContext *avctx;
@@ -41,7 +42,7 @@ static const int xl_table[32] = {
 };
 
 static int decode_frame(AVCodecContext *avctx,
-                        void *data, int *data_size,
+                        void *data, int *got_frame,
                         AVPacket *avpkt)
 {
     const uint8_t *buf = avpkt->data;
@@ -68,7 +69,7 @@ static int decode_frame(AVCodecContext *avctx,
         avctx->release_buffer(avctx, p);
 
     p->reference = 0;
-    if ((ret = avctx->get_buffer(avctx, p)) < 0) {
+    if ((ret = ff_get_buffer(avctx, p)) < 0) {
         av_log(avctx, AV_LOG_ERROR, "get_buffer() failed\n");
         return ret;
     }
@@ -127,7 +128,7 @@ static int decode_frame(AVCodecContext *avctx,
         V += a->pic.linesize[2];
     }
 
-    *data_size = sizeof(AVFrame);
+    *got_frame = 1;
     *(AVFrame*)data = a->pic;
 
     return buf_size;