Last change
on this file since 12091 was
12091,
checked in by wiesep, 5 years ago
|
Updated programs and adjusted Material to work with GLSL>150
|
File size:
391 bytes
|
Line | |
---|
1 | #version 100 |
---|
2 | |
---|
3 | precision mediump int; |
---|
4 | precision mediump float; |
---|
5 | |
---|
6 | uniform mat4 worldViewProj; |
---|
7 | uniform vec3 eyePosition; |
---|
8 | attribute vec4 position; |
---|
9 | attribute vec4 normal; |
---|
10 | varying vec2 NDotV; |
---|
11 | |
---|
12 | void main() |
---|
13 | { |
---|
14 | vec4 eyeDir = vec4(eyePosition - position.xyz, 0.0); |
---|
15 | eyeDir = normalize(eyeDir); |
---|
16 | gl_Position = worldViewProj * position; |
---|
17 | NDotV = vec2(clamp( dot( normal, eyeDir ), 0.0, 1.0 )); |
---|
18 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.