mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-28 20:53:54 +02:00
avfilter/vf_colorbalance: Use formats list instead of query function
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
6d5d8be55e
commit
c0d6a18294
@ -74,8 +74,6 @@ static const AVOption colorbalance_options[] = {
|
||||
|
||||
AVFILTER_DEFINE_CLASS(colorbalance);
|
||||
|
||||
static int query_formats(AVFilterContext *ctx)
|
||||
{
|
||||
static const enum AVPixelFormat pix_fmts[] = {
|
||||
AV_PIX_FMT_RGB24, AV_PIX_FMT_BGR24,
|
||||
AV_PIX_FMT_RGBA, AV_PIX_FMT_BGRA,
|
||||
@ -92,8 +90,6 @@ static int query_formats(AVFilterContext *ctx)
|
||||
AV_PIX_FMT_GBRP16, AV_PIX_FMT_GBRAP16,
|
||||
AV_PIX_FMT_NONE
|
||||
};
|
||||
return ff_set_common_formats_from_list(ctx, pix_fmts);
|
||||
}
|
||||
|
||||
static float get_component(float v, float l,
|
||||
float s, float m, float h)
|
||||
@ -442,7 +438,7 @@ const AVFilter ff_vf_colorbalance = {
|
||||
.priv_class = &colorbalance_class,
|
||||
FILTER_INPUTS(colorbalance_inputs),
|
||||
FILTER_OUTPUTS(colorbalance_outputs),
|
||||
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,
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user