nuclear@30: attribute vec4 attr_vertex, attr_color; nuclear@30: attribute vec2 attr_texcoord; nuclear@29: attribute vec4 attr_tangent; nuclear@29: attribute vec3 attr_normal; nuclear@29: nuclear@29: uniform mat4 matrix_modelview, matrix_projection, matrix_texture; nuclear@30: uniform mat3 matrix_normal; nuclear@29: uniform float t; nuclear@29: uniform vec4 light_pos; nuclear@29: nuclear@29: varying vec3 vpos, normal, tangent; nuclear@29: varying vec4 tc; nuclear@29: varying vec3 lpos; nuclear@29: nuclear@29: void main() nuclear@29: { nuclear@29: mat4 mvp = matrix_projection * matrix_modelview; nuclear@29: gl_Position = mvp * attr_vertex; nuclear@29: nuclear@29: vpos = (matrix_modelview * attr_vertex).xyz; nuclear@29: nuclear@30: normal = matrix_normal * attr_normal; nuclear@30: tangent = matrix_normal * attr_tangent.xyz; nuclear@29: nuclear@29: lpos = (matrix_modelview * light_pos).xyz; nuclear@29: nuclear@30: tc = matrix_texture * vec4(attr_texcoord, 0.0, 1.0); nuclear@29: }