Ray Tracing
Rich History
- Ibn al-Haytham (c. 965-1039)
first to explain that we see objects because the sun's rays of light
- Albrecht Dürer, and his Renaissance contemporaries
used rays to improve their paintings in the early 1500's
- Pinhole camera
simple camera without a lens and with a single small aperture, a pinhole, and a light-proof box
first observed in China in the 5th Century BC, first image recorded by Sir David Brewster in 1850
- Used to make all modern 3D computer generated movies (sometimes in combination with other techniques)
Simple Algorithm
- For each pixel on the image plane,
- calculate a ray from the camera to that spot
- follow that ray into the scene to see if it hits objects
- if it does hit an object
- calculate a ray from that point to all light sources
- if it hits an object
- return just the object's color
- else
- return combination of object's and light's color
- else return the color of the background
- Can be made recursive for interesting effects (reflection, refraction, caustics, etc.)
- Object intersection is the key to the complexity of the images
- VERY slow, but lots of effeciency shortcuts and easily parallelizable
- Based on physical principles, but not a perfect solution to the rendering problem
Notes
References