From c118d8f6cc9950ef74d6b5c24bc3a3e56c4b7d42 Mon Sep 17 00:00:00 2001 From: wm4 Date: Thu, 15 Jan 2015 20:10:08 +0100 Subject: image_writer: check for conversion errors This can happen when e.g. a VO returns a screenshot in an unsupported format. --- video/sws_utils.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'video/sws_utils.h') diff --git a/video/sws_utils.h b/video/sws_utils.h index cf9aa827b2..7c7c1af34b 100644 --- a/video/sws_utils.h +++ b/video/sws_utils.h @@ -18,11 +18,11 @@ extern const int mp_sws_fast_flags; bool mp_sws_supported_format(int imgfmt); -void mp_image_swscale(struct mp_image *dst, struct mp_image *src, - int my_sws_flags); +int mp_image_swscale(struct mp_image *dst, struct mp_image *src, + int my_sws_flags); -void mp_image_sw_blur_scale(struct mp_image *dst, struct mp_image *src, - float gblur); +int mp_image_sw_blur_scale(struct mp_image *dst, struct mp_image *src, + float gblur); struct mp_sws_context { // Can be set for verbose error printing. -- cgit v1.2.3