Upload
others
View
7
Download
0
Embed Size (px)
Citation preview
A Geometry-Based Soft Shadow Volume AlgorithmUsing Graphics Hardware
A Geometry-Based Soft Shadow Volume AlgorithmUsing Graphics Hardware
Ulf Assarsson Ulf Assarsson andand
Tomas AkenineTomas Akenine--MMööllerller
SIGGRAPH 2003SIGGRAPH 2003
We present:We We present:present:
A Soft Shadow Volume Algorithm:• Area light sources
• Simple volumetric light sources
• Textures and short video textures as lights
• Real-time performance with programmable graphics hardware
• Approximate soft shadows
– Trade speed vs accuracy
A Soft Shadow Volume Algorithm:• Area light sources
• Simple volumetric light sources
• Textures and short video textures as lights
• Real-time performance with programmable graphics hardware
• Approximate soft shadows
– Trade speed vs accuracy
Intro demoIntro demo A short recap…A A short recapshort recap……
Area/volumetric lights give soft shadows• Real lights have area or volume
• Thus, soft shadows more realistic
Area/volumetric lights give soft shadows• Real lights have area or volume
• Thus, soft shadows more realistic
SOFTHARD
OverviewOverview
Computation of visibility mask:Computation of visibility mask:•• 1st pass: Render hard shadow1st pass: Render hard shadow•• 2nd pass: compensate for overstated umbra2nd pass: compensate for overstated umbra
Hard vs. soft shadowsHard vs. soft shadows
point source
umbra
area source
umbrapenumbra
Two different light source types: Two different light source types:
A Real-Time Soft Shadow Volume AlgorithmA Real-Time Soft Shadow Volume Algorithm
WedgesWedgesWedges
• Each silhouette edge has a corresponding wedge–Provides a piece of penumbra
contribution–Rasterized by pixelshader
• Each silhouette edge has a corresponding wedge–Provides a piece of penumbra
contribution–Rasterized by pixelshader
Two-pass algorithmTwo-pass algorithmVisibility computationVisibility computation
• Really want to compute how muchwe can see of the light source
Visibility computationVisibility computationPrecomputed contribution in 4D texturesPrecomputed contribution in 4D textures
contributioncontribution areaarea
3232
3232
How the visibility computation works:How the visibility computation works: Rasterize a wedgeRasterize a wedge
A A wedge wedge for for each silhouette edgeeach silhouette edge…… A A wedge wedge for for each silhouette edgeeach silhouette edge……
A A wedge wedge for for each silhouette edgeeach silhouette edge…… A A wedge wedge for for each silhouette edgeeach silhouette edge……
A A wedge wedge for for each silhouette edgeeach silhouette edge…… Rasterizing Rasterizing the the wedgeswedges
Rasterizing Rasterizing the the wedgeswedges Rasterizing Rasterizing the the wedgeswedges
Rasterizing Rasterizing the the wedgeswedges Rasterizing Rasterizing the the wedgeswedges
Examples using textured lightsExamples using textured lights
TextureTexture of 16 area of 16 area lightslights Texture Texture of of two colorstwo colors
Fire DemoFire Fire DemoDemo
Fire DemoFire Fire DemoDemo ComparisonsComparisonsComparisons
Reference Reference image image Our algorithmOur algorithm
ComparisonsComparisonsComparisons
Reference Reference image image Our algorithmOur algorithm
ComparisonsComparisonsComparisons
Small Small light light
sourcesource
Large Large light light
sourcesource
ComparisonsComparisonsComparisons
512 512 point lights Our algorithmpoint lights Our algorithm
The Last DemoThe Last Demo