diff mbox series

[FFmpeg-devel,056/218] avfilter/vf_atadenoise: Use formats list instead of query function

Message ID PR3PR03MB66654DC350BB06DD5539BEDB8FAA9@PR3PR03MB6665.eurprd03.prod.outlook.com
State Accepted
Commit 6d473dfa9594f761c3856c1a629eea47420d081e
Headers show
Series [FFmpeg-devel,001/218] avfilter/f_reverse: Don't use redundant query_formats function | expand

Checks

Context Check Description
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished
andriy/make_ppc success Make finished
andriy/make_fate_ppc success Make fate finished

Commit Message

Andreas Rheinhardt Sept. 30, 2021, 1:39 p.m. UTC
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavfilter/vf_atadenoise.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)
diff mbox series

Patch

diff --git a/libavfilter/vf_atadenoise.c b/libavfilter/vf_atadenoise.c
index 40f983cd9e..3a47c32cec 100644
--- a/libavfilter/vf_atadenoise.c
+++ b/libavfilter/vf_atadenoise.c
@@ -89,8 +89,6 @@  static const AVOption atadenoise_options[] = {
 
 AVFILTER_DEFINE_CLASS(atadenoise);
 
-static int query_formats(AVFilterContext *ctx)
-{
     static const enum AVPixelFormat pixel_fmts[] = {
         AV_PIX_FMT_GRAY8,
         AV_PIX_FMT_GRAY9,
@@ -120,8 +118,6 @@  static int query_formats(AVFilterContext *ctx)
         AV_PIX_FMT_GBRAP,     AV_PIX_FMT_GBRAP10,    AV_PIX_FMT_GBRAP12,    AV_PIX_FMT_GBRAP16,
         AV_PIX_FMT_NONE
     };
-    return ff_set_common_formats_from_list(ctx, pixel_fmts);
-}
 
 static av_cold int init(AVFilterContext *ctx)
 {
@@ -576,7 +572,7 @@  const AVFilter ff_vf_atadenoise = {
     .uninit        = uninit,
     FILTER_INPUTS(inputs),
     FILTER_OUTPUTS(outputs),
-    FILTER_QUERY_FUNC(query_formats),
+    FILTER_PIXFMTS_ARRAY(pixel_fmts),
     .flags         = AVFILTER_FLAG_SUPPORT_TIMELINE_INTERNAL | AVFILTER_FLAG_SLICE_THREADS,
     .process_command = process_command,
 };