2011-09-05 15:02:06 +00:00
|
|
|
// -*-C++-*-
|
2012-07-02 20:12:24 +00:00
|
|
|
// -*-C++-*-
|
|
|
|
// Texture switching based on face slope and snow level
|
|
|
|
// based on earlier work by Frederic Bouvier, Tim Moore, and Yves Sablonier.
|
|
|
|
// © Emilian Huminiuc 2011
|
2011-09-05 15:02:06 +00:00
|
|
|
|
|
|
|
|
2011-10-29 09:57:04 +00:00
|
|
|
#version 120
|
2011-09-05 15:02:06 +00:00
|
|
|
|
2012-07-02 20:12:24 +00:00
|
|
|
varying vec4 RawPos;
|
|
|
|
varying vec3 normal;
|
|
|
|
varying vec3 Vnormal;
|
2011-12-01 20:58:14 +00:00
|
|
|
|
2011-09-05 15:02:06 +00:00
|
|
|
void main()
|
2011-12-01 20:58:14 +00:00
|
|
|
{
|
2011-09-05 15:02:06 +00:00
|
|
|
RawPos = gl_Vertex;
|
|
|
|
gl_Position = ftransform();
|
|
|
|
gl_TexCoord[0] = gl_TextureMatrix[0] * gl_MultiTexCoord0;
|
|
|
|
normal = normalize(gl_Normal);
|
2012-07-02 20:12:24 +00:00
|
|
|
Vnormal = normalize(gl_NormalMatrix * gl_Normal);
|
2011-09-05 15:02:06 +00:00
|
|
|
}
|