diff options
author | Eric Anholt <eric@anholt.net> | 2009-08-07 14:44:55 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2009-08-07 14:44:55 -0700 |
commit | fd654e927eaba350542818ba1230d75de4136a98 (patch) | |
tree | d2e1523ca593cd9cf7ccdaf5732abe5f82cdbbfa | |
parent | 0abadf8012c486ef33fd4d62965ac6a575420119 (diff) |
Move texcoord.x *= 4 out of VS into constants.
-rw-r--r-- | glass.c | 2 | ||||
-rw-r--r-- | glass.vert | 2 |
2 files changed, 2 insertions, 2 deletions
@@ -549,7 +549,7 @@ revolve(const float *verts, unsigned int num_verts, tangent[vert_index * 3 + 1] = tangent4[1]; tangent[vert_index * 3 + 2] = tangent4[2]; - tex_coord[vert_index * 2 + 0] = (float)i / steps; + tex_coord[vert_index * 2 + 0] = (float)i / steps * 4; tex_coord[vert_index * 2 + 1] = texcoord_y[j]; } } @@ -21,7 +21,7 @@ void main() vec3 vertex_eye = vec3(mv * gl_Vertex); shadow_coords = light_mvp * gl_Vertex; - texcoord = vec2(gl_MultiTexCoord0.x * 4, gl_MultiTexCoord0.y); + texcoord = gl_MultiTexCoord0.xy; light_surf = normalize((light_eye - vertex_eye) * tbn); eye_surf = normalize((-vertex_eye) * tbn); tangent_surf = gl_MultiTexCoord1.xyz * tbn; |