Get the latest tech news
Ray Tracing in One Weekend
**Ray Tracing in One Weekend** [Peter Shirley][], [Trevor David Black][], [Steve Hollasch][] Version 4.0.1, 2024-08-31 Copyright 2018-2024 Peter Shirley. All rights reserved.
outward_normal : -outward_normal; } }; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ [Listing [hit-with-material]:[hittable.h] Hit record with added material pointer] `hit_record` is just a way to stuff a bunch of arguments into a class so we can send them as a group. Also note that in order for the fuzz sphere to make sense, it needs to be consistently scaled compared to the reflection vector, which can vary in length arbitrarily. Well, it turns out that given a sphere of material with an index of refraction greater than air, there's no incident angle that will yield total internal reflection -- neither at the ray-sphere entrance point nor at the ray exit.
Or read this on Hacker News