From 1efa578ffb3870a1ed43259360e4da952894835d Mon Sep 17 00:00:00 2001 From: Johannes Hackel Date: Thu, 16 May 2024 16:33:32 +0200 Subject: [PATCH] Fix transmission by setting the correct value for transmissive_lighting_input.F_ab (#13379) # Objective - The clearcoat PR #13031 had a small typo which broke transmission - Fixes #13284 ## Solution - Set transmissive_lighting_input.F_ab to the correct value ![transmission_fix](https://github.com/bevyengine/bevy/assets/688816/92158117-de3a-4fa5-8af8-dcbd1d5eee04) --- crates/bevy_pbr/src/render/pbr_functions.wgsl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/bevy_pbr/src/render/pbr_functions.wgsl b/crates/bevy_pbr/src/render/pbr_functions.wgsl index d16317e6af..4bcbaabfac 100644 --- a/crates/bevy_pbr/src/render/pbr_functions.wgsl +++ b/crates/bevy_pbr/src/render/pbr_functions.wgsl @@ -306,7 +306,7 @@ fn apply_pbr_lighting( transmissive_lighting_input.V = -in.V; transmissive_lighting_input.diffuse_color = diffuse_transmissive_color; transmissive_lighting_input.F0_ = vec3(0.0); - transmissive_lighting_input.F_ab = vec2(0.0); + transmissive_lighting_input.F_ab = vec2(0.1); #ifdef STANDARD_MATERIAL_CLEARCOAT transmissive_lighting_input.layers[LAYER_CLEARCOAT].NdotV = 0.0; transmissive_lighting_input.layers[LAYER_CLEARCOAT].N = vec3(0.0);