1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-08-04 22:03:09 +02:00

avfilter/vf_libplacebo: set colorspace properties on all inputs

There is no reason to only do this on the first input. It doesn't actually
matter for now given that we don't constrain the color space list, but it
may matter when that changes.

Signed-off-by: Niklas Haas <git@haasn.dev>
This commit is contained in:
Niklas Haas
2025-02-19 18:26:05 +01:00
parent d48745ba1c
commit c85879c601

View File

@ -1167,14 +1167,12 @@ static int libplacebo_query_format(const AVFilterContext *ctx,
RET(ff_add_format(&infmts, cfg_in[0]->formats->formats[n]));
}
RET(ff_formats_ref(infmts, &cfg_in[i]->formats));
RET(ff_formats_ref(ff_all_color_spaces(), &cfg_in[i]->color_spaces));
RET(ff_formats_ref(ff_all_color_ranges(), &cfg_in[i]->color_ranges));
}
RET(ff_formats_ref(outfmts, &cfg_out[0]->formats));
/* Set colorspace properties */
RET(ff_formats_ref(ff_all_color_spaces(), &cfg_in[0]->color_spaces));
RET(ff_formats_ref(ff_all_color_ranges(), &cfg_in[0]->color_ranges));
outfmts = s->colorspace > 0 ? ff_make_formats_list_singleton(s->colorspace)
: ff_all_color_spaces();
RET(ff_formats_ref(outfmts, &cfg_out[0]->color_spaces));