diff options
author | Anton Khirnov <anton@khirnov.net> | 2013-10-27 10:02:26 +0100 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2013-10-31 20:14:15 +0100 |
commit | a87739388da6d00a757885428d42554e7eabf453 (patch) | |
tree | 367227cc864742b3cc5bc4be18edd095cf387bb1 | |
parent | 06e7a20244453a53db9b83d798b116a9a9f64bdc (diff) | |
download | ffmpeg-a87739388da6d00a757885428d42554e7eabf453.tar.gz |
eatgv: stop using deprecated avcodec_set_dimensions
-rw-r--r-- | libavcodec/eatgv.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/libavcodec/eatgv.c b/libavcodec/eatgv.c index fabc5167bb..92d914ef54 100644 --- a/libavcodec/eatgv.c +++ b/libavcodec/eatgv.c @@ -269,9 +269,10 @@ static int tgv_decode_frame(AVCodecContext *avctx, s->width = AV_RL16(&buf[0]); s->height = AV_RL16(&buf[2]); if (s->avctx->width != s->width || s->avctx->height != s->height) { - avcodec_set_dimensions(s->avctx, s->width, s->height); av_freep(&s->frame_buffer); av_frame_unref(&s->last_frame); + if ((ret = ff_set_dimensions(s->avctx, s->width, s->height)) < 0) + return ret; } pal_count = AV_RL16(&buf[6]); @@ -282,9 +283,6 @@ static int tgv_decode_frame(AVCodecContext *avctx, } } - if ((ret = av_image_check_size(s->width, s->height, 0, avctx)) < 0) - return ret; - if ((ret = ff_get_buffer(avctx, frame, AV_GET_BUFFER_FLAG_REF)) < 0) return ret; |