Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gpu_shader_3D_polyline_vert.glsl « shaders « gpu « blender « source - git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 28aa2a4ccc6562f1068e034f8e324c470a99b7e2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28

uniform mat4 ModelViewProjectionMatrix;
uniform mat4 ModelMatrix;
uniform vec4 ClipPlane;

in vec3 pos;

#if !defined(UNIFORM)
in vec4 color;

out vec4 finalColor_g;
#endif

#ifdef CLIP
out float clip_g;
#endif

void main()
{
  gl_Position = ModelViewProjectionMatrix * vec4(pos, 1.0);
#if !defined(UNIFORM)
  finalColor_g = color;
#endif

#ifdef CLIP
  clip_g = dot(ModelMatrix * vec4(pos, 1.0), ClipPlane);
#endif
}