glviewvol

view sdr/fast.v.glsl @ 15:2a67ea257ac0

makefile fixes for macosx
author John Tsiombikas <nuclear@member.fsf.org>
date Fri, 06 Feb 2015 23:47:28 +0200
parents fb6d93471352
children
line source
1 uniform float zscale;
3 void main()
4 {
5 mat4 mvmat = gl_ModelViewMatrix;
6 mvmat[0][0] = mvmat[1][1] = mvmat[2][2] = 1.0;
7 mvmat[0][1] = mvmat[0][2] = mvmat[1][2] = mvmat[1][0] = mvmat[2][0] = mvmat[2][1] = 0.0;
9 vec4 vertex = gl_Vertex;
10 gl_Position = gl_ProjectionMatrix * mvmat * vertex;
11 gl_TexCoord[0].xyz = gl_NormalMatrix * (vertex.xyz * vec3(1.0, 1.0, -1.0) * 1.732051) * vec3(1.0, 1.0, zscale) * 0.5 + 0.5;
12 }