From 472c2258dbeca000a454ea1781f09df63477563e Mon Sep 17 00:00:00 2001 From: skal Date: Sat, 28 Feb 2026 02:39:04 +0100 Subject: replace wgsl type: vec4 -> vec4f .. --- common/shaders/render/lighting_utils.wgsl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'common/shaders/render/lighting_utils.wgsl') diff --git a/common/shaders/render/lighting_utils.wgsl b/common/shaders/render/lighting_utils.wgsl index d2fd2e2..f805860 100644 --- a/common/shaders/render/lighting_utils.wgsl +++ b/common/shaders/render/lighting_utils.wgsl @@ -1,5 +1,5 @@ -fn calculate_lighting(color: vec3, normal: vec3, pos: vec3, shadow: f32) -> vec3 { - let light_dir = normalize(vec3(1.0, 1.0, 1.0)); +fn calculate_lighting(color: vec3f, normal: vec3f, pos: vec3f, shadow: f32) -> vec3f { + let light_dir = normalize(vec3f(1.0, 1.0, 1.0)); let diffuse = max(dot(normal, light_dir), 0.0); let lighting = diffuse * (0.1 + 0.9 * shadow) + 0.1; // Ambient + Shadowed Diffuse return color * lighting; -- cgit v1.2.3