summaryrefslogtreecommitdiffstats
path: root/servers
diff options
context:
space:
mode:
authorPedro J. Estébanez <pedrojrulez@gmail.com>2024-07-22 18:16:55 +0200
committerPedro J. Estébanez <pedrojrulez@gmail.com>2024-07-23 09:04:54 +0200
commit0064532c1e4952aec522736dfb64217b8cdd6d9b (patch)
tree8e92719fb010509a400296e01fca3b9463b412d9 /servers
parentf135f729b91e61e6844159a535a7474335ec8d52 (diff)
downloadredot-engine-0064532c1e4952aec522736dfb64217b8cdd6d9b.tar.gz
Fix position from vertex shader partially uninitialized
Diffstat (limited to 'servers')
-rw-r--r--servers/rendering/renderer_rd/shaders/forward_clustered/scene_forward_clustered.glsl2
-rw-r--r--servers/rendering/renderer_rd/shaders/forward_mobile/scene_forward_mobile.glsl2
2 files changed, 2 insertions, 2 deletions
diff --git a/servers/rendering/renderer_rd/shaders/forward_clustered/scene_forward_clustered.glsl b/servers/rendering/renderer_rd/shaders/forward_clustered/scene_forward_clustered.glsl
index 20b080da4d..4a630b0b0a 100644
--- a/servers/rendering/renderer_rd/shaders/forward_clustered/scene_forward_clustered.glsl
+++ b/servers/rendering/renderer_rd/shaders/forward_clustered/scene_forward_clustered.glsl
@@ -352,7 +352,7 @@ void vertex_shader(vec3 vertex_input,
}
#ifdef OVERRIDE_POSITION
- vec4 position;
+ vec4 position = vec4(1.0);
#endif
#ifdef USE_MULTIVIEW
diff --git a/servers/rendering/renderer_rd/shaders/forward_mobile/scene_forward_mobile.glsl b/servers/rendering/renderer_rd/shaders/forward_mobile/scene_forward_mobile.glsl
index a64b2e10ea..530a7a37db 100644
--- a/servers/rendering/renderer_rd/shaders/forward_mobile/scene_forward_mobile.glsl
+++ b/servers/rendering/renderer_rd/shaders/forward_mobile/scene_forward_mobile.glsl
@@ -352,7 +352,7 @@ void main() {
}
#ifdef OVERRIDE_POSITION
- vec4 position;
+ vec4 position = vec4(1.0);
#endif
#ifdef USE_MULTIVIEW