Skip to content

Commit ed02b8a

Browse files
authored
Merge pull request #55164 from Calinou/sky-fix-srgb-conversion
2 parents 4ea87f3 + 6c0b55a commit ed02b8a

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

scene/resources/sky_material.cpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ RID ProceduralSkyMaterial::shader;
3737

3838
void ProceduralSkyMaterial::set_sky_top_color(const Color &p_sky_top) {
3939
sky_top_color = p_sky_top;
40-
RS::get_singleton()->material_set_param(_get_material(), "sky_top_color", sky_top_color.to_linear());
40+
RS::get_singleton()->material_set_param(_get_material(), "sky_top_color", sky_top_color);
4141
}
4242

4343
Color ProceduralSkyMaterial::get_sky_top_color() const {
@@ -46,7 +46,7 @@ Color ProceduralSkyMaterial::get_sky_top_color() const {
4646

4747
void ProceduralSkyMaterial::set_sky_horizon_color(const Color &p_sky_horizon) {
4848
sky_horizon_color = p_sky_horizon;
49-
RS::get_singleton()->material_set_param(_get_material(), "sky_horizon_color", sky_horizon_color.to_linear());
49+
RS::get_singleton()->material_set_param(_get_material(), "sky_horizon_color", sky_horizon_color);
5050
}
5151

5252
Color ProceduralSkyMaterial::get_sky_horizon_color() const {
@@ -73,7 +73,7 @@ float ProceduralSkyMaterial::get_sky_energy() const {
7373

7474
void ProceduralSkyMaterial::set_ground_bottom_color(const Color &p_ground_bottom) {
7575
ground_bottom_color = p_ground_bottom;
76-
RS::get_singleton()->material_set_param(_get_material(), "ground_bottom_color", ground_bottom_color.to_linear());
76+
RS::get_singleton()->material_set_param(_get_material(), "ground_bottom_color", ground_bottom_color);
7777
}
7878

7979
Color ProceduralSkyMaterial::get_ground_bottom_color() const {
@@ -82,7 +82,7 @@ Color ProceduralSkyMaterial::get_ground_bottom_color() const {
8282

8383
void ProceduralSkyMaterial::set_ground_horizon_color(const Color &p_ground_horizon) {
8484
ground_horizon_color = p_ground_horizon;
85-
RS::get_singleton()->material_set_param(_get_material(), "ground_horizon_color", ground_horizon_color.to_linear());
85+
RS::get_singleton()->material_set_param(_get_material(), "ground_horizon_color", ground_horizon_color);
8686
}
8787

8888
Color ProceduralSkyMaterial::get_ground_horizon_color() const {

0 commit comments

Comments
 (0)