[fluxus] shadows

dave dave at pawfal.org
Mon May 28 02:07:46 PDT 2007


It's been lurking around in the code for a while, but I finally got
shadows working:
http://www.pawfal.org/fluxus/images/shadows.jpg

They use the stencil buffer technique[1], and work for poly primitives
only at the moment. The shadow volume is computed every frame, so
deformations, light movement etc is properly accounted for. There are
some visual problems with self shadowing and I'm noticing some glitches
with low glancing angles, but I think it's to be expected for this
method.

Three new commands:

* (shadow-light n) set the light to generate shadows for (0 to turn off
shadow rendering)
* (shadow-length 10) set the length of the shadow volume - depends on
the scene scale & longer = slower
* (shadow-debug 1) turns on debug rendering of the shadow volume and
silhouette edges

[1] http://en.wikipedia.org/wiki/Shadow_volume

cheers,

dave




More information about the Fluxus mailing list