   simple vertex shader question regarding height
  All the shader examples I see don't use any of the vertex x,y or z values directly. What I'm thinking of doing is simple:when drawing the terrain - for vertices above 1500metres (which is where my snow will lie) - to make the snow reflect the sun's light to give a specular color. So I'd want to do:if y value > 1500   do specular colorendis that possible ?cheers   
You can use the saturate function for example to calculate a factor for the specular.float specular_factor = saturate(position.z - snowlevel);so at snowlevel the specular_factor is zero and 1 unit higher it has the full strength. Cheers;  Well, you probably have to do something like this (assuming you use GLSL)://Vertex Shaderuniform vec4f color;varying vec4 my_color;void main(){   vec3 pos=gl_ModelViewMatrix*gl_Position;   my_color=color;   if(pos.y>1500){ my_color+=specular_color;//no matter how you calculate the specular_color, add it to your color here    }   ftransform();}//Fragment Shadervarying vec4 my_color;void main(){   gl_FragColor=my_color;}