[FFmpeg-devel] [PATCH 15/24] lavfi/vf_overlay_qsv: switch to query_func2()
Anton Khirnov
anton at khirnov.net
Sat Oct 12 20:02:30 EEST 2024
---
libavfilter/vf_overlay_qsv.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/libavfilter/vf_overlay_qsv.c b/libavfilter/vf_overlay_qsv.c
index 39bc700637..17da4a4d1a 100644
--- a/libavfilter/vf_overlay_qsv.c
+++ b/libavfilter/vf_overlay_qsv.c
@@ -366,7 +366,9 @@ static int activate(AVFilterContext *ctx)
return ff_framesync_activate(&s->fs);
}
-static int overlay_qsv_query_formats(AVFilterContext *ctx)
+static int overlay_qsv_query_formats(const AVFilterContext *ctx,
+ AVFilterFormatsConfig **cfg_in,
+ AVFilterFormatsConfig **cfg_out)
{
int i;
int ret;
@@ -386,12 +388,12 @@ static int overlay_qsv_query_formats(AVFilterContext *ctx)
};
for (i = 0; i < ctx->nb_inputs; i++) {
- ret = ff_formats_ref(ff_make_format_list(main_in_fmts), &ctx->inputs[i]->outcfg.formats);
+ ret = ff_formats_ref(ff_make_format_list(main_in_fmts), &cfg_in[i]->formats);
if (ret < 0)
return ret;
}
- ret = ff_formats_ref(ff_make_format_list(out_pix_fmts), &ctx->outputs[0]->incfg.formats);
+ ret = ff_formats_ref(ff_make_format_list(out_pix_fmts), &cfg_out[0]->formats);
if (ret < 0)
return ret;
@@ -431,7 +433,7 @@ const AVFilter ff_vf_overlay_qsv = {
.activate = activate,
FILTER_INPUTS(overlay_qsv_inputs),
FILTER_OUTPUTS(overlay_qsv_outputs),
- FILTER_QUERY_FUNC(overlay_qsv_query_formats),
+ FILTER_QUERY_FUNC2(overlay_qsv_query_formats),
.priv_class = &overlay_qsv_class,
.flags_internal = FF_FILTER_FLAG_HWFRAME_AWARE,
.flags = AVFILTER_FLAG_HWDEVICE,
--
2.43.0
More information about the ffmpeg-devel
mailing list