2014-01-20 19:18:26 -05:00
|
|
|
uniform mat4 ModelViewProjectionMatrix;
|
2014-01-09 12:32:51 -05:00
|
|
|
uniform mat4 ModelViewMatrix;
|
2014-01-08 19:17:28 -05:00
|
|
|
|
2014-02-28 11:29:05 -05:00
|
|
|
#if __VERSION__ >= 130
|
2014-01-20 19:18:26 -05:00
|
|
|
in vec3 Position;
|
|
|
|
in vec2 Texcoord;
|
|
|
|
in vec2 SecondTexcoord;
|
2014-01-08 19:17:28 -05:00
|
|
|
out vec2 uv;
|
2014-01-20 19:18:26 -05:00
|
|
|
out vec2 uv_bis;
|
2014-01-08 19:17:28 -05:00
|
|
|
out float camdist;
|
2014-02-28 11:29:05 -05:00
|
|
|
#else
|
|
|
|
attribute vec3 Position;
|
|
|
|
attribute vec2 Texcoord;
|
|
|
|
attribute vec2 SecondTexcoord;
|
|
|
|
varying vec2 uv;
|
|
|
|
varying vec2 uv_bis;
|
|
|
|
varying float camdist;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
2013-11-30 16:33:06 -05:00
|
|
|
|
|
|
|
void main() {
|
2014-01-20 19:18:26 -05:00
|
|
|
gl_Position = ModelViewProjectionMatrix * vec4(Position, 1.);
|
|
|
|
uv = Texcoord;
|
|
|
|
uv_bis = SecondTexcoord;
|
|
|
|
camdist = length(ModelViewMatrix * vec4(Position, 1.));
|
2013-11-30 16:33:06 -05:00
|
|
|
}
|