Dynamic Shadows and Lighting for Walkthrus of Large Models
Problem Description
Dynamic shadows and lighting are important visual cues that aid in the
understanding of spatial relationships between objects. Historically, dynamic
lighting in walkthru applications has been very simple, usually consisting
of a single directional light source that does not cast shadows. We would
like add dynamic shadows and lighting to walkthrus of large models while
maintaining interactive frame rates.
Previous Work
Many techniques have been proposed for generating shadows. Woo et al. [5]
is an older paper that provides a survey of shadow algorithms. Recent advances
in graphics hardware has made it possible to calculate shadows at interactive
framerates for scenes of moderate complexity. Two approaches that have
been used with graphics hardware are shadow volumes [3] and shadow
maps [4]. A shadow volume is the region of space consisting of all
points which are occluded to a light source. By counting the intersections
with shadow volumes along the line-of-sight towards a point in the scene
it can be determined whether the point lies in shadow or not. Shadow maps
are depth maps created from the position of the light source. To determine
whether a point is in shadow, it is projected into the light space in which
the shadow map was generated. The depth of the point is compared to the
depth stored in the shadow map. If it the point is farther away, it lies
in shadow. Improvements to shadow maps have been proposed that increase
the resolution adaptively [5] and calculate the shadow map in post-perspective
space to improve sample distribution [6].
At its heart, shadow determination is a visibility problem. There has
been a lot of research in visibility algorithms. Cohen-Or et al. [1] is
a recent survey of visibility techniques.
Approach
Recent advances in graphics hardware have increased the rendering speed
and programmibility of the graphics pipeline. I would like to explore methods
for leveraging the power of graphics hardware in order to calculate dynamic
shadows and lighting. My target model will be the 13 million triangle power
plant model. I would like to provide at least one dynamic light that moves
with the viewer, or can be moved independently of the viewer. A larger
number of static lights would also be desirable.
One interesting idea would take advantage of path coherence by using
depth billboards to accelerate the construction of shadow maps. The idea
is to cache the depth values calculated for regions of distant geometry
in textures that are updated incrementally according to an error metric
as the viewpoint changes. These textures can be warped to account for small
changes in viewpoint and composited quickly to generate a new shadow map.
This is similar in spirit to the technique used by Shade et al. [2] for
visible geometry.
References
[1] D. Cohen-Or, Y. Chrysanthou, and C. T. Silva.
A Survey of Visibility for Walkthrough Applications. Proceedings of
EUROGRAPHICS '00, Course Notes, 2000.
[2] J. Shade, D. Lischinski, D. Salesin, T. DeRose,
J. Snyder, Hierarchical Image Caching for Accelerated Walkthroughs of Complex
Environments. SIGGRAPH 1996, pp. 75-82.
[3] C. Everitt and M. J. Kilgard. Practical and Robust
Stenciled Shadow Volumes for Hardware-Accelerated Rendering. SIGGRAPH
2002 Course Notes, Course #31, 2002
[4] M. Segal. Fast Shadows and Lighting
Effects Using Texture Mapping. SIGGRAPH 92, 1992
[5] A. Woo, P. Poulin, and A. Fournier. A Survey of
Shadow Algorithms. IEEE Computer Graphics and Applications, 10(6):13-32,
1990.
[6] R. Fernando, S. Fernandez, K. Bala, and
D. Greenberg. Adaptive Shadow Maps. SIGGRAPH 2001, pp. 387-390,
2001.
[7] M. Stamminger and G. Drettakis. Perspective
Shadow Maps. SIGGRAPH 2002, pp 557-562, 2002