mirror of
https://github.com/godotengine/godot.git
synced 2025-10-20 00:13:30 +00:00
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.
This commit is contained in:
parent
8904731b8b
commit
46ef52162e
15 changed files with 68 additions and 68 deletions
|
@ -230,7 +230,7 @@ Error ImageLoaderTinyEXR::load_image(Ref<Image> p_image, Ref<FileAccess> 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<Image> p_image, Ref<FileAccess> f, bool
|
|||
}
|
||||
|
||||
if (p_force_linear) {
|
||||
color = color.to_linear();
|
||||
color = color.srgb_to_linear();
|
||||
}
|
||||
|
||||
*row_w++ = color.r;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue