13
The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL Soft Shadows using Hardware Cameras Kyle Moore COMP 870

The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL Soft Shadows using Hardware Cameras Kyle Moore COMP 870

  • View
    214

  • Download
    1

Embed Size (px)

Citation preview

The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL

Soft Shadows using Hardware Cameras

Kyle MooreCOMP 870

2The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL

Previous Work

• Cone Tracing ♦ Amanatides, J. 1984. Ray tracing with

cones. In Proceedings of the 11th Annual Conference on Computer Graphics and interactive Techniques H. Christiansen, Ed. SIGGRAPH '84. ACM Press, New York, NY, 129-135.

♦ Uses cones shaped rays instead of lines to calculate light intersections with objects

♦ Lots of difficult computations

3The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL

Previous Work

• Forward Hardware-Based Techniques♦ Assarsson, U. and Akenine-Möller, T. 2003. A

geometry-based soft shadow volume algorithm using graphics hardware. ACM Trans. Graph. 22, 3 (Jul. 2003), 511-520.

♦ Uses silhouette edges to case penumbra volumes which are to create shadow maps

♦ This is an approximation and can be inaccurate

4The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL

Previous Work

• Backwards silhouette edge detection♦ Laine, S., Aila, T., Assarsson, U., Lehtinen, J.,

and Akenine-Möller, T. 2005. Soft shadow volumes for ray tracing. ACM Trans. Graph. 24, 3 (Jul. 2005), 1156-1165.

♦ Uses a hemicube acceleration structure to find silhouette edges to calculate the amount of light occlusion

♦ Doesn’t take advantage of hardware

5The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL

My idea

• My Inspiration♦ While working on my ray tracer♦ Unhappy with soft shadows♦ Wanted to shoot more rays, but high cost

• New approach♦ Let graphics hardware simulate shooting

many rays♦ Perhaps get performance increase as well

as quality enhancement

6The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL

My Approach

Area Light Source

Occluder

Surface

Hardware Camera

View Frustum

Camera’s ViewAverage Pixels to getOcclusion percentage

7The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL

My Approach

Area Light Source

Occluder

Surface

Camera’s View

8The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL

My Application

9The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL

Results - Quality

Old approach 4x4 grid My Approach 4x4 grid

10The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL

Results - Quality

Old approach 17x17 grid My Approach 17x17 grid

11The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL

Results - Performance

Old approach 17x17 grid152 seconds

My Approach 32x32 grid96 seconds

12The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL

Performance

Rays Camera naive

Camera w/ small optimizations

4x4 42 secs 151 secs

17x17 152 secs 158 secs

32x32 447 secs 160 secs 96 secs

64x64 181 secs

128x128 241 secs

13The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL

Room for improvement

• Each pixel draws a frame and the fetches the results

• Feedback loops are slow in hardware

• Does not take advantage of parallelization of using CPU and GPU at the same time