Guest User

Untitled

a guest
May 23rd, 2018
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.37 KB | None | 0 0
  1. varying vec3 normal, lDir;
  2.  
  3. void main()
  4. {
  5. vec4 vertex = vec4(gl_Vertex);
  6.  
  7. normal = normalize(gl_NormalMatrix * gl_Normal);
  8. lDir = vec3(gl_LightSource[0].position.xyz - vertex);
  9.  
  10. vertex += vec4(normal * sin(vertex.x), 0);
  11. vertex += vec4(normal * sin(vertex.y), 0);
  12.  
  13. gl_TexCoord[0] = gl_MultiTexCoord0;
  14. gl_Position = gl_ModelViewProjectionMatrix * vertex;
  15. }
Add Comment
Please, Sign In to add comment