summaryrefslogtreecommitdiff
path: root/libavfilter
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-09-27 23:29:21 +0200
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-10-05 18:58:29 +0200
commit7709c3eb0ced684e28da730e58aaf1de8fee55c5 (patch)
tree941ac50f619c6fb4ccc16c9e0a0af136c05524c9 /libavfilter
parentc0d6a182945948fb08f26b4265ab6d5e64944988 (diff)
avfilter/vf_chromanr: 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_chromanr.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/libavfilter/vf_chromanr.c b/libavfilter/vf_chromanr.c
index 0f16f68b3f..1554bd0c4f 100644
--- a/libavfilter/vf_chromanr.c
+++ b/libavfilter/vf_chromanr.c
@@ -56,8 +56,6 @@ typedef struct ChromaNRContext {
int (*filter_slice)(AVFilterContext *ctx, void *arg, int jobnr, int nb_jobs);
} ChromaNRContext;
-static int query_formats(AVFilterContext *ctx)
-{
static const enum AVPixelFormat pix_fmts[] = {
AV_PIX_FMT_YUV420P, AV_PIX_FMT_YUV422P, AV_PIX_FMT_YUV440P, AV_PIX_FMT_YUV411P, AV_PIX_FMT_YUV444P,
AV_PIX_FMT_YUVA420P, AV_PIX_FMT_YUVA422P, AV_PIX_FMT_YUVA444P,
@@ -74,9 +72,6 @@ static int query_formats(AVFilterContext *ctx)
AV_PIX_FMT_NONE
};
- return ff_set_common_formats_from_list(ctx, pix_fmts);
-}
-
#define SQR(x) ((x)*(x))
#define FILTER_FUNC(distance, name, ctype, type, fun) \
@@ -282,7 +277,7 @@ const AVFilter ff_vf_chromanr = {
.priv_class = &chromanr_class,
FILTER_OUTPUTS(outputs),
FILTER_INPUTS(inputs),
- FILTER_QUERY_FUNC(query_formats),
+ FILTER_PIXFMTS_ARRAY(pix_fmts),
.flags = AVFILTER_FLAG_SUPPORT_TIMELINE_GENERIC | AVFILTER_FLAG_SLICE_THREADS,
.process_command = ff_filter_process_command,
};