aboutsummaryrefslogtreecommitdiffstats
path: root/libavfilter
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-09-27 21:56:23 +0200
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-10-05 18:58:27 +0200
commita8fd45a3735541c81a49b38450435d611c77740a (patch)
treef42a0d085348c6167dcfe79e49c8acfd9ac6ac3c /libavfilter
parent6a8858ef78c3f73633793238b93aa3b645e18adb (diff)
downloadffmpeg-a8fd45a3735541c81a49b38450435d611c77740a.tar.gz
avfilter/vf_find_rect: Use formats list instead of query function
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavfilter')
-rw-r--r--libavfilter/vf_find_rect.c13
1 files changed, 1 insertions, 12 deletions
diff --git a/libavfilter/vf_find_rect.c b/libavfilter/vf_find_rect.c
index 32d9a8a67a..6ac714ce45 100644
--- a/libavfilter/vf_find_rect.c
+++ b/libavfilter/vf_find_rect.c
@@ -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,
};