diff options
Diffstat (limited to 'data/light-pp.vert')
-rw-r--r-- | data/light-pp.vert | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/data/light-pp.vert b/data/light-pp.vert new file mode 100644 index 0000000..02ff444 --- /dev/null +++ b/data/light-pp.vert @@ -0,0 +1,34 @@ +/* + * light-pp.vert + * + * Lighting per pixel + * + * (c) 2007 Thomas White <taw27@cam.ac.uk> + * + * dtr - Diffraction Tomography Reconstruction + * + */ + +varying vec4 col_ambi; +varying vec4 col_diff; +varying vec4 col_spec; +varying float shininess; + +varying vec3 normal; +varying vec3 halfvc; + +void main() { + + normal = normalize(gl_NormalMatrix * gl_Normal); + halfvc = vec3(gl_LightSource[0].halfVector); + + col_ambi = gl_FrontMaterial.ambient; + col_diff = gl_FrontMaterial.diffuse; + col_spec = gl_FrontMaterial.specular; + + shininess = gl_FrontMaterial.shininess; + + gl_Position = ftransform(); + +} + |