http://sidneys77crlfslcr7zmj3msmxchgnxhrxlp3p3kbaswo7twchjnicid.onion/programming/2022/03/23/raytracing.html
If there are no
intersecting Shape s, then we use the dot product as we did last time. To start, instead of normalizing our lighting ray immediately, we’ll want to save its length - this lets us know how far
away the light is from the current hit point.