Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul B Mahol <onemda@gmail.com>2013-11-01 19:29:20 +0400
committerPaul B Mahol <onemda@gmail.com>2013-11-01 23:05:35 +0400
commit256b986c04aa327a9e8b595e08f42fdc50f0e121 (patch)
treefeb1c624bc1410cb0f231b89154f5b0c63c072c7 /libavcodec/exr.c
parent01507ab3699222f5a1be58625e916c173f1be0da (diff)
avcodec/exr: stop using deprecated avcodec_set_dimensions()
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Diffstat (limited to 'libavcodec/exr.c')
-rw-r--r--libavcodec/exr.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/libavcodec/exr.c b/libavcodec/exr.c
index ef4fc36c60..f231b70375 100644
--- a/libavcodec/exr.c
+++ b/libavcodec/exr.c
@@ -35,6 +35,7 @@
#include "get_bits.h"
#include "avcodec.h"
#include "bytestream.h"
+#include "internal.h"
#include "mathops.h"
#include "thread.h"
#include "libavutil/imgutils.h"
@@ -1184,9 +1185,6 @@ static int decode_frame(AVCodecContext *avctx,
return AVERROR_PATCHWELCOME;
}
- if (av_image_check_size(w, h, 0, avctx))
- return AVERROR_INVALIDDATA;
-
// Verify the xmin, xmax, ymin, ymax and xdelta before setting the actual image size
if (s->xmin > s->xmax ||
s->ymin > s->ymax ||
@@ -1196,9 +1194,8 @@ static int decode_frame(AVCodecContext *avctx,
return AVERROR_INVALIDDATA;
}
- if (w != avctx->width || h != avctx->height) {
- avcodec_set_dimensions(avctx, w, h);
- }
+ if ((ret = ff_set_dimensions(avctx, w, h)) < 0)
+ return ret;
s->desc = av_pix_fmt_desc_get(avctx->pix_fmt);
out_line_size = avctx->width * 2 * s->desc->nb_components;