Fix #35337: sculpt performance regression, partial redraw was not working anymore
[blender.git] / source / blender / gpu / shaders / gpu_shader_vertex.glsl
1
2 varying vec3 varposition;
3 varying vec3 varnormal;
4
5 void main()
6 {
7         vec4 co = gl_ModelViewMatrix * gl_Vertex;
8
9         varposition = co.xyz;
10         varnormal = normalize(gl_NormalMatrix * gl_Normal);
11         gl_Position = gl_ProjectionMatrix * co;
12
13 #ifdef GPU_NVIDIA
14         // Setting gl_ClipVertex is necessary to get glClipPlane working on NVIDIA
15         // graphic cards, while on ATI it can cause a software fallback.
16         gl_ClipVertex = gl_ModelViewMatrix * gl_Vertex; 
17 #endif 
18