Current graphics hardware can be used to generate shadows using either the
shadow volume or shadow map techniques. However, the shadow volume techniqu
e requires access to a representation of the scene as a polygonal model, an
d handling the near plane clip correctly and efficiently is difficult; conv
ersely, accurate shadow maps require high-precision texture map data repres
entations, but these are not widely supported.
We present a hybrid of the shadow map and shadow volume approaches which do
es not have these difficulties and leverages high-performance polygon rende
ring. The scene is rendered from the point of view of the light source and
a sampled depth map is recovered. Edge detection and a template-based recon
struction technique are used to generate a global shadow volume boundary su
rface, after which the pixels in shadow can be marked using only a one-bit
stencil buffer and a single-pass rendering of the shadow volume boundary po
lygons. The simple form of our template-based reconstruction scheme simplif
ies capping the shadow volume after the near plane clip.