roc/data/shaders/shadow_pass1.frag
2011-06-16 11:34:10 -06:00

13 lines
No EOL
343 B
GLSL

uniform sampler2D TextureMap;
varying float CameraDepth;
varying vec2 TexCoord;
void main()
{
// draw the typical textured output to visual framebuffer
gl_FragData[0] = texture2D(TextureMap, TexCoord);
// write "normaliized vertex depth" to the depthmap's alpha.
gl_FragData[1] = vec4(vec3(0.0), CameraDepth);
}