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