diff --git a/drivers/gles3/rasterizer_scene_gles3.cpp b/drivers/gles3/rasterizer_scene_gles3.cpp index f82614998ec5..5a5579b34cdb 100644 --- a/drivers/gles3/rasterizer_scene_gles3.cpp +++ b/drivers/gles3/rasterizer_scene_gles3.cpp @@ -2533,6 +2533,10 @@ void RasterizerSceneGLES3::render_scene(const Ref &p_render_ scene_state.prev_multiview_data = scene_state.multiview_data; } + if (is_reflection_probe) { + apply_color_adjustments_in_post = false; + } + GLuint fbo = 0; if (is_reflection_probe && GLES3::LightStorage::get_singleton()->reflection_probe_has_atlas_index(render_data.reflection_probe)) { fbo = GLES3::LightStorage::get_singleton()->reflection_probe_instance_get_framebuffer(render_data.reflection_probe, render_data.reflection_probe_pass); diff --git a/drivers/gles3/shaders/scene.glsl b/drivers/gles3/shaders/scene.glsl index 54c3e905870c..4372a33061c4 100644 --- a/drivers/gles3/shaders/scene.glsl +++ b/drivers/gles3/shaders/scene.glsl @@ -2517,11 +2517,16 @@ void main() { frag_color.rgb = mix(frag_color.rgb, fog.rgb, fog.a); #endif // !FOG_DISABLED +#ifdef DISABLE_REFLECTION_PROBE // Tonemap before writing as we are writing to an sRGB framebuffer frag_color.rgb *= exposure; + #ifdef APPLY_TONEMAPPING frag_color.rgb = apply_tonemapping(frag_color.rgb, white); -#endif +#endif // APPLY_TONEMAPPING + +#endif // DISABLE_REFLECTION_PROBE + frag_color.rgb = linear_to_srgb(frag_color.rgb); #else // !BASE_PASS @@ -2785,11 +2790,16 @@ void main() { additive_light_color *= (1.0 - fog.a); #endif // !FOG_DISABLED +#ifdef DISABLE_REFLECTION_PROBE // Tonemap before writing as we are writing to an sRGB framebuffer additive_light_color *= exposure; + #ifdef APPLY_TONEMAPPING additive_light_color = apply_tonemapping(additive_light_color, white); -#endif +#endif // APPLY_TONEMAPPING + +#endif // DISABLE_REFLECTION_PROBE + additive_light_color = linear_to_srgb(additive_light_color); frag_color.rgb += additive_light_color;