1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

avfilter/vf_chromashift: Fix mixed declaration and code

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
Mark Harris 2018-11-24 19:17:40 -08:00 committed by Michael Niedermayer
parent 01dc152a92
commit 8108064043

View File

@ -76,13 +76,14 @@ static int query_formats(AVFilterContext *ctx)
AV_PIX_FMT_NONE
};
const enum AVPixelFormat *pix_fmts;
AVFilterFormats *fmts_list;
if (!strcmp(ctx->filter->name, "rgbashift"))
pix_fmts = rgb_pix_fmts;
else
pix_fmts = yuv_pix_fmts;
AVFilterFormats *fmts_list = ff_make_format_list(pix_fmts);
fmts_list = ff_make_format_list(pix_fmts);
if (!fmts_list)
return AVERROR(ENOMEM);
return ff_set_common_formats(ctx, fmts_list);