"There's a saying that states: 'The road to hell is paved with good intentions'. There's hardly anything that better describes communism than that. All good hopes and dreams of justice and equality have ended in oppression and dictatorship."
- Peter Eriksson, Green Party of Sweden

Framework 4 (Last updated: October 25, 2019)
Framework 3 (Last updated: February 6, 2017)
Framework 2 (Last updated: October 8, 2006)
Framework (Last updated: October 8, 2006)
Libraries (Last updated: September 16, 2004)
Really old framework (Last updated: September 16, 2004)
StencilShadows
Wednesday, March 13, 2002 | Permalink

Executable
Source code
StencilShadows.zip (678 KB)

Required:
GL_ARB_multitexture
GL_EXT_texture_env_dot3
GL_ARB_texture_env_combine
GL_EXT_texture_edge_clamp
GL_EXT_texture3D
GL_ARB_texture_env_crossbar or GL_NV_texture_env_combine4
This demo shows dynamic per-pixel lighting with shadows and proper shadow overlapping. The shadows are created by using the stencil buffer and Carmacks reversed algoritm.