line_vert.glsl 320 B

1234567891011121314151617
  1. precision highp float;
  2. attribute vec3 position;
  3. attribute vec3 color;
  4. uniform mat4 modelViewMatrix;
  5. uniform mat4 projectionMatrix;
  6. varying vec3 vertexColor;
  7. void main(void) {
  8. vec4 pos = modelViewMatrix * vec4(position,1.0);
  9. vertexColor = vec3(color.x, color.y, color.y);
  10. gl_Position = projectionMatrix * pos;
  11. }