[FFmpeg-cvslog] kgv1dec: stop using deprecated avcodec_set_dimensions

Anton Khirnov git at videolan.org
Fri Nov 1 15:13:53 CET 2013


ffmpeg | branch: master | Anton Khirnov <anton at khirnov.net> | Sun Oct 27 10:02:26 2013 +0100| [d62b24a3f6bfd541704b258d8495eac58d8866dd] | committer: Anton Khirnov

kgv1dec: stop using deprecated avcodec_set_dimensions

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=d62b24a3f6bfd541704b258d8495eac58d8866dd
---

 libavcodec/kgv1dec.c |    6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/libavcodec/kgv1dec.c b/libavcodec/kgv1dec.c
index 1774f36..62b5c6e 100644
--- a/libavcodec/kgv1dec.c
+++ b/libavcodec/kgv1dec.c
@@ -61,12 +61,10 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *got_frame,
     h = (buf[1] + 1) * 8;
     buf += 2;
 
-    if ((res = av_image_check_size(w, h, 0, avctx)) < 0)
-        return res;
-
     if (w != avctx->width || h != avctx->height) {
         av_frame_unref(&c->prev);
-        avcodec_set_dimensions(avctx, w, h);
+        if ((res = ff_set_dimensions(avctx, w, h)) < 0)
+            return res;
     }
 
     maxcnt = w * h;



More information about the ffmpeg-cvslog mailing list