lavfi/vf_drawtext: switch to query_func2()

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

View File

@ -1077,9 +1077,12 @@ static av_cold int init(AVFilterContext *ctx)
return 0; return 0;
} }
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_draw_supported_pixel_formats(0)); return ff_set_common_formats2(ctx, cfg_in, cfg_out,
ff_draw_supported_pixel_formats(0));
} }
static int glyph_enu_border_free(void *opaque, void *elem) static int glyph_enu_border_free(void *opaque, void *elem)
@ -1915,7 +1918,7 @@ const AVFilter ff_vf_drawtext = {
.uninit = uninit, .uninit = uninit,
FILTER_INPUTS(avfilter_vf_drawtext_inputs), FILTER_INPUTS(avfilter_vf_drawtext_inputs),
FILTER_OUTPUTS(ff_video_default_filterpad), FILTER_OUTPUTS(ff_video_default_filterpad),
FILTER_QUERY_FUNC(query_formats), FILTER_QUERY_FUNC2(query_formats),
.process_command = command, .process_command = command,
.flags = AVFILTER_FLAG_SUPPORT_TIMELINE_GENERIC, .flags = AVFILTER_FLAG_SUPPORT_TIMELINE_GENERIC,
}; };