[Bf-blender-cvs] [8781886cf7f] temp-vulkan-shader: Fix compilation of line dashed shader.
Jeroen Bakker
noreply at git.blender.org
Fri Dec 2 10:30:12 CET 2022
Commit: 8781886cf7f465b1081a7f45af95a2fd642f67e4
Author: Jeroen Bakker
Date: Fri Dec 2 10:17:20 2022 +0100
Branches: temp-vulkan-shader
https://developer.blender.org/rB8781886cf7f465b1081a7f45af95a2fd642f67e4
Fix compilation of line dashed shader.
===================================================================
M source/blender/gpu/shaders/gpu_shader_3D_line_dashed_uniform_color_vert.glsl
===================================================================
diff --git a/source/blender/gpu/shaders/gpu_shader_3D_line_dashed_uniform_color_vert.glsl b/source/blender/gpu/shaders/gpu_shader_3D_line_dashed_uniform_color_vert.glsl
index 68835cb1d0f..4b15bb3851d 100644
--- a/source/blender/gpu/shaders/gpu_shader_3D_line_dashed_uniform_color_vert.glsl
+++ b/source/blender/gpu/shaders/gpu_shader_3D_line_dashed_uniform_color_vert.glsl
@@ -13,6 +13,8 @@ void main()
gl_Position = ModelViewProjectionMatrix * pos_4d;
stipple_start = stipple_pos = viewport_size * 0.5 * (gl_Position.xy / gl_Position.w);
#ifdef USE_WORLD_CLIP_PLANES
- world_clip_planes_calc_clip_distance((ModelMatrix * pos_4d).xyz);
+ /* Spir-V GLSL pre-processors chokes when passed directly. */
+ vec3 wpos = (ModelMatrix * pos_4d).xyz;
+ world_clip_planes_calc_clip_distance(wpos);
#endif
}
More information about the Bf-blender-cvs
mailing list