examples/data/ex_prim_shader_vertex.glsl
raw| 1 | attribute vec4 al_pos; |
| 2 | attribute vec3 al_user_attr_0; |
| 3 | |
| 4 | uniform mat4 al_projview_matrix; |
| 5 | |
| 6 | /* pixel_position and normal are used to compute the reflections in the pixel shader */ |
| 7 | varying vec3 pixel_position; |
| 8 | varying vec3 normal; |
| 9 | |
| 10 | void main() |
| 11 | { |
| 12 | pixel_position = al_pos.xyz; |
| 13 | normal = al_user_attr_0; |
| 14 | gl_Position = al_projview_matrix * al_pos; |
| 15 | } |