You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
539 B

  1. #version 100
  2. // Input vertex attributes
  3. attribute vec3 vertexPosition;
  4. attribute vec2 vertexTexCoord;
  5. attribute vec4 vertexColor;
  6. // Input uniform values
  7. uniform mat4 mvp;
  8. // Output vertex attributes (to fragment shader)
  9. varying vec2 fragTexCoord;
  10. varying vec4 fragColor;
  11. // NOTE: Add here your custom variables
  12. void main()
  13. {
  14. // Send vertex attributes to fragment shader
  15. fragTexCoord = vertexTexCoord;
  16. fragColor = vertexColor;
  17. // Calculate final vertex position
  18. gl_Position = mvp*vec4(vertexPosition, 1.0);
  19. }