summaryrefslogtreecommitdiff
path: root/servers/rendering/renderer_rd/shaders/scene_forward.glsl
diff options
context:
space:
mode:
authorHendrik Brucker <hendrik.brucker@mail.de>2021-01-04 14:08:01 +0100
committerHendrik Brucker <hendrik.brucker@mail.de>2021-01-04 14:08:01 +0100
commitec6fc059b7c579aeddd3eb88a5dbbf2552b20be1 (patch)
treeb5269072652b7fdb088b24c0d8f41c7d51bc1201 /servers/rendering/renderer_rd/shaders/scene_forward.glsl
parentc5ff2cb3d9bca0478e3abce7540e3b831fa5ef37 (diff)
fix inconsistent normal map shader variable naming
Diffstat (limited to 'servers/rendering/renderer_rd/shaders/scene_forward.glsl')
-rw-r--r--servers/rendering/renderer_rd/shaders/scene_forward.glsl4
1 files changed, 2 insertions, 2 deletions
diff --git a/servers/rendering/renderer_rd/shaders/scene_forward.glsl b/servers/rendering/renderer_rd/shaders/scene_forward.glsl
index 05f7637478..1c12a8a4c7 100644
--- a/servers/rendering/renderer_rd/shaders/scene_forward.glsl
+++ b/servers/rendering/renderer_rd/shaders/scene_forward.glsl
@@ -1855,7 +1855,7 @@ void main() {
vec3 normal_map = vec3(0.5);
#endif
- float normal_depth = 1.0;
+ float normal_map_depth = 1.0;
vec2 screen_uv = gl_FragCoord.xy * scene_data.screen_pixel_size + scene_data.screen_pixel_size * 0.5; //account for center
@@ -1931,7 +1931,7 @@ FRAGMENT_SHADER_CODE
normal_map.xy = normal_map.xy * 2.0 - 1.0;
normal_map.z = sqrt(max(0.0, 1.0 - dot(normal_map.xy, normal_map.xy))); //always ignore Z, as it can be RG packed, Z may be pos/neg, etc.
- normal = normalize(mix(normal, tangent * normal_map.x + binormal * normal_map.y + normal * normal_map.z, normal_depth));
+ normal = normalize(mix(normal, tangent * normal_map.x + binormal * normal_map.y + normal * normal_map.z, normal_map_depth));
#endif