From c3348d5dcc9bf458d208a398554fb796358e97ef Mon Sep 17 00:00:00 2001 From: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> Date: Mon, 31 Mar 2025 20:27:55 +0200 Subject: [PATCH 09/12] avfilter/palette: Remove unused ff_srgb_u8_to_linear_int() Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> --- libavfilter/palette.c | 5 ----- libavfilter/palette.h | 6 ------ 2 files changed, 11 deletions(-) diff --git a/libavfilter/palette.c b/libavfilter/palette.c index bba136408c..e5ea0cab67 100644 --- a/libavfilter/palette.c +++ b/libavfilter/palette.c @@ -110,11 +110,6 @@ static const uint8_t linear2srgb[P + 1] = { 0xfc, 0xfc, 0xfc, 0xfc, 0xfd, 0xfd, 0xfd, 0xfd, 0xfd, 0xfe, 0xfe, 0xfe, 0xfe, 0xff, 0xff, 0xff, }; -int32_t ff_srgb_u8_to_linear_int(uint8_t x) -{ - return (int32_t)srgb2linear[x]; -} - uint8_t ff_linear_int_to_srgb_u8(int32_t x) { if (x <= 0) { diff --git a/libavfilter/palette.h b/libavfilter/palette.h index d3acc854ba..056ea36b93 100644 --- a/libavfilter/palette.h +++ b/libavfilter/palette.h @@ -31,12 +31,6 @@ struct Lab { int32_t L, a, b; }; -/** - * Map sRGB 8-bit color component to a 16-bit linear value (gamma - * expand from electrical to optical value). - */ -int32_t ff_srgb_u8_to_linear_int(uint8_t x); - /** * Map a 16-bit linear value to a sRGB 8-bit color component (gamma * compressed from optical to electrical value). -- 2.45.2