summaryrefslogtreecommitdiff
path: root/indra/newview/app_settings/shaders/class1/environment/terrainF.glsl
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/app_settings/shaders/class1/environment/terrainF.glsl')
-rw-r--r--indra/newview/app_settings/shaders/class1/environment/terrainF.glsl13
1 files changed, 9 insertions, 4 deletions
diff --git a/indra/newview/app_settings/shaders/class1/environment/terrainF.glsl b/indra/newview/app_settings/shaders/class1/environment/terrainF.glsl
index c61d5a2a08..5d72390d2d 100644
--- a/indra/newview/app_settings/shaders/class1/environment/terrainF.glsl
+++ b/indra/newview/app_settings/shaders/class1/environment/terrainF.glsl
@@ -29,13 +29,18 @@ uniform sampler2D detail0;
uniform sampler2D detail1;
uniform sampler2D alphaRamp;
+VARYING vec2 vary_texcoord0;
+VARYING vec2 vary_texcoord1;
+VARYING vec2 vary_texcoord2;
+VARYING vec2 vary_texcoord3;
+
void main()
{
- float a = texture2D(alphaRamp, gl_TexCoord[1].xy).a;
- vec3 color = mix(texture2D(detail1, gl_TexCoord[2].xy).rgb,
- texture2D(detail0, gl_TexCoord[0].xy).rgb,
+ float a = texture2D(alphaRamp, vary_texcoord1.xy).a;
+ vec3 color = mix(texture2D(detail1, vary_texcoord2.xy).rgb,
+ texture2D(detail0, vary_texcoord0.xy).rgb,
a);
gl_FragColor.rgb = color;
- gl_FragColor.a = texture2D(alphaRamp, gl_TexCoord[3].xy).a;
+ gl_FragColor.a = texture2D(alphaRamp, vary_texcoord3.xy).a;
}