From 46ef52162eee2bdddb44a15fc8bf37aeb1aa3f48 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Verschelde?= Date: Wed, 13 Apr 2022 10:37:22 +0200 Subject: Color: Rename `to_srgb`/`to_linear` to include base color space This helps reduce confusion around sRGB <> Linear conversions by making both input and output color spaces explicit. --- modules/tinyexr/image_loader_tinyexr.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'modules/tinyexr') diff --git a/modules/tinyexr/image_loader_tinyexr.cpp b/modules/tinyexr/image_loader_tinyexr.cpp index 1ff2600839..864df765ee 100644 --- a/modules/tinyexr/image_loader_tinyexr.cpp +++ b/modules/tinyexr/image_loader_tinyexr.cpp @@ -230,7 +230,7 @@ Error ImageLoaderTinyEXR::load_image(Ref p_image, Ref f, bool } if (p_force_linear) { - color = color.to_linear(); + color = color.srgb_to_linear(); } *row_w++ = Math::make_half_float(color.r); @@ -261,7 +261,7 @@ Error ImageLoaderTinyEXR::load_image(Ref p_image, Ref f, bool } if (p_force_linear) { - color = color.to_linear(); + color = color.srgb_to_linear(); } *row_w++ = color.r; -- cgit v1.2.3