mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-29 02:42:21 +00:00
avfilter/vf_find_rect: Use formats list instead of query function
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
6a8858ef78
commit
a8fd45a373
@ -59,17 +59,6 @@ static const AVOption find_rect_options[] = {
|
||||
|
||||
AVFILTER_DEFINE_CLASS(find_rect);
|
||||
|
||||
static int query_formats(AVFilterContext *ctx)
|
||||
{
|
||||
static const enum AVPixelFormat pix_fmts[] = {
|
||||
AV_PIX_FMT_YUV420P,
|
||||
AV_PIX_FMT_YUVJ420P,
|
||||
AV_PIX_FMT_NONE
|
||||
};
|
||||
|
||||
return ff_set_common_formats_from_list(ctx, pix_fmts);
|
||||
}
|
||||
|
||||
static AVFrame *downscale(AVFrame *in)
|
||||
{
|
||||
int x, y;
|
||||
@ -307,6 +296,6 @@ const AVFilter ff_vf_find_rect = {
|
||||
.uninit = uninit,
|
||||
FILTER_INPUTS(foc_inputs),
|
||||
FILTER_OUTPUTS(foc_outputs),
|
||||
FILTER_QUERY_FUNC(query_formats),
|
||||
FILTER_PIXFMTS(AV_PIX_FMT_YUV420P, AV_PIX_FMT_YUVJ420P),
|
||||
.priv_class = &find_rect_class,
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user