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:
parent
01dc152a92
commit
8108064043
@ -76,13 +76,14 @@ static int query_formats(AVFilterContext *ctx)
|
|||||||
AV_PIX_FMT_NONE
|
AV_PIX_FMT_NONE
|
||||||
};
|
};
|
||||||
const enum AVPixelFormat *pix_fmts;
|
const enum AVPixelFormat *pix_fmts;
|
||||||
|
AVFilterFormats *fmts_list;
|
||||||
|
|
||||||
if (!strcmp(ctx->filter->name, "rgbashift"))
|
if (!strcmp(ctx->filter->name, "rgbashift"))
|
||||||
pix_fmts = rgb_pix_fmts;
|
pix_fmts = rgb_pix_fmts;
|
||||||
else
|
else
|
||||||
pix_fmts = yuv_pix_fmts;
|
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)
|
if (!fmts_list)
|
||||||
return AVERROR(ENOMEM);
|
return AVERROR(ENOMEM);
|
||||||
return ff_set_common_formats(ctx, fmts_list);
|
return ff_set_common_formats(ctx, fmts_list);
|
||||||
|
Loading…
Reference in New Issue
Block a user