diff options
| author | Joshua Rahm <joshua.rahm@colorado.edu> | 2014-04-18 01:17:46 -0600 |
|---|---|---|
| committer | Joshua Rahm <joshua.rahm@colorado.edu> | 2014-04-18 01:17:46 -0600 |
| commit | 915cda147b565880fecefe5f82ca242bad6114fc (patch) | |
| tree | d6afedd6d33bdca1601faaaebd731b89aab75431 /shaders/water.vert | |
| parent | 73daf65aaa31b5fb59f4a91d9185387f63c7b09f (diff) | |
| download | terralloc-915cda147b565880fecefe5f82ca242bad6114fc.tar.gz terralloc-915cda147b565880fecefe5f82ca242bad6114fc.tar.bz2 terralloc-915cda147b565880fecefe5f82ca242bad6114fc.zip | |
starting tesselation shader
Diffstat (limited to 'shaders/water.vert')
| -rw-r--r-- | shaders/water.vert | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/shaders/water.vert b/shaders/water.vert index 1db6dc5..765c1df 100644 --- a/shaders/water.vert +++ b/shaders/water.vert @@ -11,6 +11,13 @@ layout(location = 4) uniform mat4 pjMatrix ; layout(location = 5) uniform mat4 mvMatrix ; layout(location = 7) uniform mat3 normalMatrix ; +out vec3 lightPos ; +out vec3 normal ; +out vec4 position ; +out vec2 texpos ; + void main() { - gl_Position = pjMatrix * mvMatrix * vec4( in_position, 1.0 ); + gl_Position = pjMatrix * (position = mvMatrix * vec4( in_position, 1.0 )); + normal = normalMatrix * vec3(0,1,0) ; + texpos = in_position.xz / 20.0; } |