Ray Casting
This sketch simulates the process of ray casting to visualize how rays interact with obstacles in a 2D environment. As rays extend from a source point, they detect and highlight intersections with walls or objects, demonstrating concepts of light, shadows, and visibility in a dynamic, interactive way.
Move the mouse and see the interaction with the pentagon in the center of th canvas.
References
- Loïc Rico - Ray Casting (Processing)
- The Coding Train - Ray Casting
- Nicky Case - Nothing To Hide
- Sebastian Lague - Ray Tracing