last time
DESCRIPTION
Last Time. Ray-tracing implementation Recall the light paths that ray-tracing captures Technically, we are talking about “eye ray tracing,” which traces rays originating at the eye - PowerPoint PPT PresentationTRANSCRIPT
![Page 1: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/1.jpg)
05/07/02 (c) 2002 University of Wisconsin
Last Time
• Ray-tracing implementation• Recall the light paths that ray-tracing captures
– Technically, we are talking about “eye ray tracing,” which traces rays originating at the eye
– Some people use the terms forward or backward ray-tracing, but there is no agreement in which direction is forward!
![Page 2: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/2.jpg)
05/07/02 (c) 2002 University of Wisconsin
Ray-traced Cornell box, due to Henrik Jensen,http://www.gk.dtu.dk/~hwj
Which paths are present?Which paths are missing?
![Page 3: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/3.jpg)
05/07/02 (c) 2002 University of Wisconsin
![Page 4: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/4.jpg)
05/07/02 (c) 2002 University of Wisconsin
Today
• Rendering algorithms that capture other light paths– Distribution ray-tracing– Radiosity– Bi-directional ray tracing
![Page 5: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/5.jpg)
05/07/02 (c) 2002 University of Wisconsin
Ray-Tracing and Sampling
• Basic ray-tracing casts one ray through each pixel, sends one ray for each reflection, one ray for each point light, etc
• This represents a single sample for each point, and for an animation, a single sample for each frame
• Many important effects require more samples:– Motion blur: A photograph of a moving object smears the object
across the film (longer exposure, more motion blur)– Depth of Field: Objects not located at the focal distance appear
blurred when viewed through a real lens system– Rough reflections: Reflections in a rough surface appear blurred
![Page 6: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/6.jpg)
05/07/02 (c) 2002 University of Wisconsin
Distribution Raytracing
• Distribution raytracing casts more than one ray for each sample– Originally called distributed raytracing, but the name’s confusing
• How would you sample to get motion blur?• How would you sample to get rough reflections?• How would you sample to get depth of field?
![Page 7: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/7.jpg)
05/07/02 (c) 2002 University of Wisconsin
Distribution RaytracingDepth of Field
From Alan Watt, “3D Computer Graphics”
![Page 8: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/8.jpg)
05/07/02 (c) 2002 University of Wisconsin
Missing Paths• Basic recursive raytracing cannot do:
– LS*D+E: Light bouncing off a shiny surface like a mirror and illuminating a diffuse surface
– LD+E: Light bouncing off one diffuse surface to illuminate others• Basic problem: The raytracer doesn’t know where to send rays out of
the diffuse surface to capture the incoming light• Also a problem for rough specular reflection
– Fuzzy reflections in rough shiny objects
![Page 9: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/9.jpg)
05/07/02 (c) 2002 University of Wisconsin
Bi-directional Raytracing• Cast rays from the light sources out into the scene
– When a ray hits a diffuse surface, accumulate some light there– Surfaces record the amount of light that hits them
• Store the light in texture maps• Store the light in quadtrees• Store the light in photon maps
• Cast rays from the eye out into the scene– When a ray hits a diffuse surface, look up the amount of light that hit it in
the light-ray phase• What paths does it capture?• What sort of visual effects do you see?
![Page 10: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/10.jpg)
05/07/02 (c) 2002 University of Wisconsin
Caustics
From Alan Watt, “3D Computer Graphics”
Standard raytracer:Diffuse table and blue ball, mirrors left, right and back, transparent red ball
Bi-directional raytracer
More rays in the light pass
Note the LS*DS*E paths
![Page 11: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/11.jpg)
05/07/02 (c) 2002 University of Wisconsin
Refraction caustic
Henrik wann Jensen, http://www.gk.dtu.dk/~hwj
![Page 12: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/12.jpg)
05/07/02 (c) 2002 University of Wisconsin
Refraction caustics
Henrik wann Jensen, http://www.gk.dtu.dk/~hwj
![Page 13: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/13.jpg)
05/07/02 (c) 2002 University of Wisconsin
Still Missing…
• LD*E paths – Diffuse-diffuse transport– Formulated and solved with radiosity methods
• L(S|D)*E paths– Solved with Monte-Carlo renderers – very very inefficient– Also solvable with multi-pass methods, but also very very
inefficient, and subject to aliasing– An unsolved (unsolvable?) problem
![Page 14: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/14.jpg)
05/07/02 (c) 2002 University of Wisconsin
Real World LD*E Paths
From Alan Watt, “3D Computer Graphics”
![Page 15: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/15.jpg)
05/07/02 (c) 2002 University of Wisconsin
Radiosity Assumptions• All surfaces are perfectly diffuse
– Means that is doesn’t matter which way light hits or leaves a surface• Illumination is constant over a patch
– Can break the world up into a discrete number of pieces– Problems at sharp illumination boundaries - shadows– Ways around these problems, but less efficient and less able to
manage scene complexity• Assumptions allow us to solve for LD*E paths
![Page 16: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/16.jpg)
05/07/02 (c) 2002 University of Wisconsin
Radiosity Equation
• Derived from the global illumination equation using radiosity assumptions
• Bi is the radiosity (brightness) of patch i i is the diffuse reflection coefficient• Fij is the form factor, which quantifies how much light patch j
contributes to patch i• The brightness of each patch depends on how much light it gets from
all the others, and its diffuse reflection
j
N
jijiii BFEB
1
![Page 17: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/17.jpg)
05/07/02 (c) 2002 University of Wisconsin
Solving the Radiosity Eqn• Radiosity algorithms use one of several methods to solve the radiosity
equation– Basically a very large linear system, so techniques can all be mapped onto
linear system solvers• A large part of the computation is in finding form factors
– Describe how much light gets from each patch to every other patch– Geometric in nature - do not depend on the illumination, just the layout of
the scene• Another key factor is finding good meshing strategies - ways of laying
out the patches
![Page 18: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/18.jpg)
05/07/02 (c) 2002 University of Wisconsin
Radiosity Example• Color bleeding is extreme in
this example• Textures are applied after
solving for illumination• Some meshing artifacts are
visible - note the banding around the pictures on the wall
From Alan Watt, “3D Computer Graphics”
![Page 19: Last Time](https://reader035.vdocument.in/reader035/viewer/2022081604/568167d3550346895ddd264a/html5/thumbnails/19.jpg)
05/07/02 (c) 2002 University of Wisconsin
Radiosity Meshing• Each patch is colored with its
illumination• Note the discrete nature of the
solution• The previous image was
obtained by pushing color to vertices and then Gourand shading
From Alan Watt, “3D Computer Graphics”