http://sidneys77crlfslcr7zmj3msmxchgnxhrxlp3p3kbaswo7twchjnicid.onion/programming/2022/03/23/raytracing.html
For example in our lerp function: // Apply a linear interpolation between two colors:
// from |-------------------------------| to
// ^ by -olc::Pixel lerp(olc::Pixel from, olc::Pixel to, float by) const { +color3 lerp(color3 from, color3 to, float by) const { if (by <= 0.0f) return from;
if (by >= 1.0f) return to; - return olc::Pixel(
- from.r * (1 - by) + to.r *...