Ray Tracing: Whence and Whither? Dave Edwards April 24, 2008
Introduction Rendering Input: description of a scene (geometry, materials) Ouput: image or images (i.e., movie) Two main components Computing visibility (what objects can I see from a given location?) Shading (what color are those objects?) Two main approaches Rasterization Ray tracing
Rasterization Overview
Rasterization Overview
Rasterization Overview
Rasterization Overview
Rasterization Overview
Rasterization Overview
Rasterization Overview Almost all graphics hardware is raster-based Works almost exclusively with triangles Computes shading first, then visibility Parallel over triangles, except for visibility test Global illumination effects require additional rendering passes
Ray Tracing Overview
Ray Tracing Overview
Ray Tracing Overview
Ray Tracing Overview
Ray Tracing Overview
Ray Tracing Overview Introduced by Turner Whitted in 1980 Computes visibility first, then shading Implemented exclusively in software until recently More flexible than hardware (e.g., we can ray trace objects other than triangles) Parallel over rays Tends to scale very well with additional processors Simple to render global effects using recursive ray tracing
Interactive Ray Tracing Until the late 1990s, rasterization was used for interactive rendering, and ray-based methods were used for batch rendering Early prototypes of interactive ray tracers Muuss 1995 Parker et al. 1997 (RTRT) Since: OpenRT, Manta, others There are even some prototype hardware ray tracers (e.g., Saarcor, RPU) Interactivity is allowed by advances in software and hardware
Quotes I m not really bullish on [ray tracing] taking over for primary rendering tasks... Head to head rasterization is just a vastly more efficient use of whatever transistors you have available. - John Carmack, Game Programmer, id Software
Quotes I don t see classical ray tracing in its current form becoming the dominant [rendering] solution.... We may find it being present in a more significant portion in overall real-time 3D graphics solutions though in 3 5 years from now. - Cevat Yerli, CEO, Crytek
Quotes... I do believe that hybrid rendering is the future. Ray tracing is excellent at producing some effects, but slow at others. So, if you try to use ray tracing for everything, there is a very good chance that it won t be very fast. - David Kirk, Chief Scientist, NVIDIA
Quotes Ray Tracing has the potential to become the widely used rendering technology on desktop computers... [A] hybrid rendering approach for rendering the 3D world might not be the best idea. - Daniel Pohl, Researcher, Intel
Recent Developments Since 2006, IEEE has held an annual Symposium on Interactive Ray Tracing Ray tracing researchers being hired by many companies Intel s Larrabee architecture At least 10 cores per chip 16-wide floating point processor
Ray Tracing Details: Rays Ray is specified by an origin and direction Or equivalently, origin and another point on the ray One-dimensional parameter t changes along ray Parametric equation: R(t) = o + td, where t [0, )
Generating Primary Rays Compute visibility by tracing a ray through each pixel
Ray-Object Intersection There are algorithms for determining the t value where a ray hits an object Triangles (linear equation) Spheres (quadratic equation) Tori (quartic equation) Implicit surfaces (root finding) Volumetric data (root finding)
Intersections with Multiple Objects The true intersection is the one with the lowest positive t value
Shading by Recursive Ray Tracing To determine if a point in the scene is shadowed: Trace a ray from the point to the light source Compute the t value where the ray hits the light The point is in shadow if the ray intersects any object in the scene before hitting the light
Shading by Recursive Ray Tracing This is just the visibility problem again!
Is One Ray Per Pixel Enough?
Is One Ray Per Pixel Enough?
Is One Ray Per Pixel Enough?
Is One Ray Per Pixel Enough?
Distributed Ray Tracing (DRT) Cook et al. 1984 If we re tracing multiple rays per pixel, why not use them for something interesting (e.g., motion blur)?
DRT Example
The Importance of Perception
Difference Images We can compute the difference of the values of corresponding pixels in two images
The Visual Differences Predictor VDP algorithm [Daly 1993] estimates the probability of detecting a difference for each pixel
Big-picture Perceptual Questions The important (and complex) perceptual question is: How good is good enough? The ultimate judge of a rendering system are human viewers
Open Questions Is ray tracing hardware necessary to make ray tracing a competitive method? If so, is it sufficient to make ray tracing a competitive method? Can hybrid (raster-based + ray-based) methods work effectively? How do we keep ray tracing efficient for dynamic scenes?
Final Thoughts Ray-based rendering is a controversial and interesting topic If the only tool you have is a hammer, you tend to see every problem as a nail. - Abraham Maslow We need people with a good understanding of hardware, rasterization, and ray tracing More information: http://www.cs.utah.edu/ edwards/gcc/ Email: edwards@cs.utah.edu
Thank You! Questions?