Re:Writing a Raytracer in Rust – Part 1
by alpaca128 on Thursday March 30, 2017 @05:28PM
(#13999037)
Path tracing is just like ray tracing with randomized deviations of the rays and reflections, and this is repeated many times to reduce the noise.
This can also be done with shadow rays to some extent, for soft shadows.
(But it seems like every person you ask knows a different meaning for terms like raycasting, path tracing and physical based rendering)
I'm not sure this is true. The shadow ray pass is used to determine how much light is returned to the pixel. So something like:
* shoot a ray from the pixel
* when the ray hits an object check how much light that point receives
* bounce the ray according to the hit material properties
* repeat the bounces X times and gather how much light the pixel will receive.
Because most bounes are in a random direction it's best to sample a pixel multiple times. And ofcourse more bounces give a more realistic global illumination result.
It's going to depend on the material of your object. If it's perfectly reflective, you'll want to trace different rays than if it's perfectly diffuse, and if it's a rough surface (and how rough).
Path tracing doesn't trace towards light sources for shadow rays and instead just sends several rays in different directions and accumelates the resulting colors of those rays.