Download presentation
Presentation is loading. Please wait.
Published bySarah Ray Modified over 9 years ago
1
1 Dr. Scott Schaefer Ray Tracing
2
2/42 Ray Tracing Provides rendering method with Refraction/Transparent surfaces Reflective surfaces Shadows
3
3/42 Ray Tracing Provides rendering method with Refraction/Transparent surfaces Reflective surfaces Shadows Image taken from http://radsite.lbl.gov/radiance/book/img/plate10.jpg
4
4/42 Ray Tracing Provides rendering method with Refraction/Transparent surfaces Reflective surfaces Shadows Image taken from http://www.tjhsst.edu/~dhyatt/superap/samplex.jpg
5
5/42 Ray Tracing Provides rendering method with Refraction/Transparent surfaces Reflective surfaces Shadows
6
6/42 Essential Information for Ray Tracing Eye point Screen position/orientation Objects Material properties Reflection/Refraction coefficients Index of refraction Light sources
7
7/42 Recursive Ray Tracing For each pixel Intersect ray from eye through pixel with all objects in scene Find closest (positive) intersection to eye Compute lighting at intersection point Recur for reflected and refracted rays (if necessary)
8
8/42 eye screen
9
9/42 eye screen
10
10/42 eye screen
11
11/42 eye screen normal
12
12/42 Ray Casting Removes hidden surfaces Per-pixel lighting computations
13
13/42 Shadows Cast a virtual ray to each light source If ray hits an opaque object before the light, then omit contribution of that light If ray hits a semi-transparent object, scale the contribution of that light and continue to look for intersections Note: objects may be self-shadowing!!!
14
14/42 shadow ray normal eye screen
15
15/42 Shadows
16
16/42 Shadows
17
17/42 normal eye screen reflected ray
18
18/42 normal eye screen shadow ray reflected ray normal
19
19/42 normal reflected ray eye screen normal reflected ray
20
20/42 Reflection Mirror-like/Shiny objects Surface
21
21/42 eye screen normal refracted ray
22
22/42 Refraction Bending of light caused by different speeds of light in different medium Each (semi-)transparent object has an index of refraction c i Use Snell’s law to find refracted vector Image taken from http://hyperphysics.phy-astr.gsu.edu/hbase/geoopt/refr2.html
23
23/42 Snell’s Law Surface
24
24/42 Snell’s Law Surface
25
25/42 Snell’s Law Surface
26
26/42 Snell’s Law Surface
27
27/42 Snell’s Law Surface
28
28/42 Snell’s Law Surface
29
29/42 Snell’s Law Surface
30
30/42 Snell’s Law Surface
31
31/42 Snell’s Law Surface
32
32/42 Snell’s Law Surface
33
33/42 Total Internal Reflection Surface
34
34/42 Recursive Ray Tracing Truncate at finite depth!
35
35/42 Recursive Ray Tracing Recur for reflective/transparent objects
36
36/42 Recursive Ray Tracing Recur for reflective/transparent objects
37
37/42 Optimizations Lots of rays to cast! Ray-Surface intersections are expensive Associate with each object Bounding box in 3-space If ray doesn’t intersect box, then ray doesn’t intersect object
38
38/42 Parallel Processing Ray tracing is a trivially parallel algorithm! Cast rays in parallel Cast reflection, refraction, shadow rays in parallel Calculate ray/surface intersections independently in parallel
39
39/42 Ray Tracing: Special Effects copyright Newline Cinema
40
40/42 Ray Tracing: Video Games
41
41/42 Ray Tracing: Massive Models
42
42/42 Extensions of Ray Tracing Only considers totally specular interactions rays either reflect perfectly or refract perfectly Ray traced scenes don't show “color bleed”
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.