mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-12 10:15:22 +00:00
lavfi/vf_swaprect: convert to query_func2()
This commit is contained in:
parent
05aad90c69
commit
06292d34de
@ -56,13 +56,16 @@ static const AVOption swaprect_options[] = {
|
|||||||
|
|
||||||
AVFILTER_DEFINE_CLASS(swaprect);
|
AVFILTER_DEFINE_CLASS(swaprect);
|
||||||
|
|
||||||
static int query_formats(AVFilterContext *ctx)
|
static int query_formats(const AVFilterContext *ctx,
|
||||||
|
AVFilterFormatsConfig **cfg_in,
|
||||||
|
AVFilterFormatsConfig **cfg_out)
|
||||||
{
|
{
|
||||||
int reject_flags = AV_PIX_FMT_FLAG_PAL |
|
int reject_flags = AV_PIX_FMT_FLAG_PAL |
|
||||||
AV_PIX_FMT_FLAG_HWACCEL |
|
AV_PIX_FMT_FLAG_HWACCEL |
|
||||||
AV_PIX_FMT_FLAG_BITSTREAM;
|
AV_PIX_FMT_FLAG_BITSTREAM;
|
||||||
|
|
||||||
return ff_set_common_formats(ctx, ff_formats_pixdesc_filter(0, reject_flags));
|
return ff_set_common_formats2(ctx, cfg_in, cfg_out,
|
||||||
|
ff_formats_pixdesc_filter(0, reject_flags));
|
||||||
}
|
}
|
||||||
|
|
||||||
static const char *const var_names[] = { "w", "h", "a", "n", "t",
|
static const char *const var_names[] = { "w", "h", "a", "n", "t",
|
||||||
@ -251,7 +254,7 @@ const AVFilter ff_vf_swaprect = {
|
|||||||
.uninit = uninit,
|
.uninit = uninit,
|
||||||
FILTER_INPUTS(inputs),
|
FILTER_INPUTS(inputs),
|
||||||
FILTER_OUTPUTS(ff_video_default_filterpad),
|
FILTER_OUTPUTS(ff_video_default_filterpad),
|
||||||
FILTER_QUERY_FUNC(query_formats),
|
FILTER_QUERY_FUNC2(query_formats),
|
||||||
.flags = AVFILTER_FLAG_SUPPORT_TIMELINE_GENERIC,
|
.flags = AVFILTER_FLAG_SUPPORT_TIMELINE_GENERIC,
|
||||||
.process_command = ff_filter_process_command,
|
.process_command = ff_filter_process_command,
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user