uniform vec4 HG_EyePos; uniform mat4 HG_ModelMatrix; uniform vec4 HG_DepthRange; varying vec3 normal; varying vec3 pos; varying vec3 gpos; void main() { gl_TexCoord[0] = gl_MultiTexCoord0; gl_Position = ftransform(); //gl_Vertex * vec4( 2., 2., 1., 1. ); vec4 n = vec4(gl_Normal, 0.); normal = (gl_ModelViewMatrix * n).xyz; pos = (gl_ModelViewMatrix * gl_Vertex).xyz; gpos = (HG_ModelMatrix * gl_Vertex).xyz; gl_FrontColor = gl_Color; }