roc_samples/data/shaders/test.vert
cecilkorik 12cb7128f7 split everything in roc_samples out of the main roc project
refactored as needed to make roc work as a shared library, without any stupid import hacks
2017-05-08 23:49:09 -07:00

13 lines
No EOL
322 B
GLSL

varying vec3 normal;
varying vec3 lightdir;
void main()
{
gl_TexCoord[0] = gl_TextureMatrix[0] * gl_MultiTexCoord0;
normal = gl_NormalMatrix * gl_Normal;
vec4 newpos = ftransform();
gl_Position = newpos;
lightdir = normalize(vec3(gl_LightSource[0].position) - vec3(gl_ModelViewMatrix * gl_Vertex));
}