lavfi/vf_copy: switch to query_func2()

This commit is contained in:
Anton Khirnov 2024-10-04 10:09:29 +02:00
parent bc418fd872
commit da8cc791e2
1 changed files with 6 additions and 3 deletions

View File

@ -28,9 +28,12 @@
#include "formats.h" #include "formats.h"
#include "video.h" #include "video.h"
static int query_formats(AVFilterContext *ctx) static int query_formats(const AVFilterContext *ctx,
AVFilterFormatsConfig **cfg_in,
AVFilterFormatsConfig **cfg_out)
{ {
return ff_set_common_formats(ctx, ff_formats_pixdesc_filter(0, AV_PIX_FMT_FLAG_HWACCEL)); return ff_set_common_formats2(ctx, cfg_in, cfg_out,
ff_formats_pixdesc_filter(0, AV_PIX_FMT_FLAG_HWACCEL));
} }
static int filter_frame(AVFilterLink *inlink, AVFrame *in) static int filter_frame(AVFilterLink *inlink, AVFrame *in)
@ -72,5 +75,5 @@ const AVFilter ff_vf_copy = {
.flags = AVFILTER_FLAG_METADATA_ONLY, .flags = AVFILTER_FLAG_METADATA_ONLY,
FILTER_INPUTS(avfilter_vf_copy_inputs), FILTER_INPUTS(avfilter_vf_copy_inputs),
FILTER_OUTPUTS(ff_video_default_filterpad), FILTER_OUTPUTS(ff_video_default_filterpad),
FILTER_QUERY_FUNC(query_formats), FILTER_QUERY_FUNC2(query_formats),
}; };