From bfa1b7577dd646e84acafd0c82a8c2c6fe9c2a0a Mon Sep 17 00:00:00 2001 From: Niklas Haas Date: Fri, 12 Jan 2024 14:12:44 +0100 Subject: [PATCH] avfilter/vf_zscale: fix query_formats Wrong field assignment as a result of copy/paste error. --- libavfilter/vf_zscale.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/libavfilter/vf_zscale.c b/libavfilter/vf_zscale.c index 3b14ce4f33..1c55282842 100644 --- a/libavfilter/vf_zscale.c +++ b/libavfilter/vf_zscale.c @@ -225,20 +225,20 @@ static int query_formats(AVFilterContext *ctx) if (ret < 0) return ret; - if ((ret = ff_formats_ref(ff_all_color_spaces(), &ctx->inputs[0]->outcfg.formats)) < 0 || - (ret = ff_formats_ref(ff_all_color_ranges(), &ctx->inputs[0]->outcfg.formats)) < 0) + if ((ret = ff_formats_ref(ff_all_color_spaces(), &ctx->inputs[0]->outcfg.color_spaces)) < 0 || + (ret = ff_formats_ref(ff_all_color_ranges(), &ctx->inputs[0]->outcfg.color_ranges)) < 0) return ret; formats = s->colorspace != ZIMG_MATRIX_UNSPECIFIED && s->colorspace > 0 ? ff_make_formats_list_singleton(s->colorspace) : ff_all_color_spaces(); - if ((ret = ff_formats_ref(formats, &ctx->outputs[0]->incfg.formats)) < 0) + if ((ret = ff_formats_ref(formats, &ctx->outputs[0]->incfg.color_spaces)) < 0) return ret; formats = s->range != -1 ? ff_make_formats_list_singleton(convert_range_from_zimg(s->range)) : ff_all_color_ranges(); - if ((ret = ff_formats_ref(formats, &ctx->outputs[0]->incfg.formats)) < 0) + if ((ret = ff_formats_ref(formats, &ctx->outputs[0]->incfg.color_ranges)) < 0) return ret; return 0;