summaryrefslogtreecommitdiffstats
path: root/video/sws_utils.c
diff options
context:
space:
mode:
authorKacper Michajłow <kasper93@gmail.com>2023-01-29 15:02:03 +0100
committerDudemanguy <random342@airmail.cc>2023-02-02 14:23:02 +0000
commitbc7a1262376677b8185daebf7db7c1cc5b30762f (patch)
tree51771a556f85f0bb93729740abc99f1c8f402ef0 /video/sws_utils.c
parent87fb254deb527ee0336e66481d1f39809a4e1d2d (diff)
downloadmpv-bc7a1262376677b8185daebf7db7c1cc5b30762f.tar.bz2
mpv-bc7a1262376677b8185daebf7db7c1cc5b30762f.tar.xz
sws_utils: add check for HAVE_ZIMG to suppress warnings
Diffstat (limited to 'video/sws_utils.c')
-rw-r--r--video/sws_utils.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/video/sws_utils.c b/video/sws_utils.c
index fb3e844cb0..3af60977ad 100644
--- a/video/sws_utils.c
+++ b/video/sws_utils.c
@@ -127,11 +127,13 @@ bool mp_sws_supported_format(int imgfmt)
&& sws_isSupportedOutput(av_format);
}
+#if HAVE_ZIMG
static bool allow_zimg(struct mp_sws_context *ctx)
{
return ctx->force_scaler == MP_SWS_ZIMG ||
(ctx->force_scaler == MP_SWS_AUTO && ctx->allow_zimg);
}
+#endif
static bool allow_sws(struct mp_sws_context *ctx)
{
@@ -337,7 +339,10 @@ int mp_sws_reinit(struct mp_sws_context *ctx)
if (sws_init_context(ctx->sws, ctx->src_filter, ctx->dst_filter) < 0)
return -1;
+#if HAVE_ZIMG
success:
+#endif
+
ctx->force_reload = false;
*ctx->cached = *ctx;
return 1;