swscale/lut3d: pass SwsFormat by pointer instead of value in ff_sws_lut3d_pick_pixfmt()

This commit is contained in:
Ramiro Polla committed 2026-06-19 14:32:44 +00:00
1 parent a9cd93c917
commit 12750ed512
3 files changed
+4 -4

No files matched your search

+2 -2
View File
@@ -756,8 +756,8 @@ static int adapt_colors(SwsGraph *graph, SwsFormat src, SwsFormat dst,
if (!lut)
return AVERROR(ENOMEM);
fmt_in = ff_sws_lut3d_pick_pixfmt(src, 0);
fmt_out = ff_sws_lut3d_pick_pixfmt(dst, 1);
fmt_in = ff_sws_lut3d_pick_pixfmt(&src, 0);
fmt_out = ff_sws_lut3d_pick_pixfmt(&dst, 1);
if (fmt_in != src.format) {
SwsFormat tmp = src;
tmp.format = fmt_in;
+1 -1
View File
@@ -49,7 +49,7 @@ bool ff_sws_lut3d_test_fmt(enum AVPixelFormat fmt, int output)
return fmt == AV_PIX_FMT_RGBA64;
}
enum AVPixelFormat ff_sws_lut3d_pick_pixfmt(SwsFormat fmt, int output)
enum AVPixelFormat ff_sws_lut3d_pick_pixfmt(const SwsFormat *fmt, int output)
{
return AV_PIX_FMT_RGBA64;
}
+1 -1
View File
@@ -70,7 +70,7 @@ bool ff_sws_lut3d_test_fmt(enum AVPixelFormat fmt, int output);
/**
* Pick the best compatible pixfmt for a given SwsFormat.
*/
enum AVPixelFormat ff_sws_lut3d_pick_pixfmt(SwsFormat fmt, int output);
enum AVPixelFormat ff_sws_lut3d_pick_pixfmt(const SwsFormat *fmt, int output);
/**
* Recalculate the (static) 3DLUT state with new settings. This will recompute