Chapter 5Ray-Sphere Intersections
Awesome news! You’re all done with the foundational work, and now you get to start on the meat of an actual ray tracer. From here on out, each chapter will culminate in something concrete, something visual, which will add to your growing store of eye candy.
For this chapter, that visual bit won’t be particularly impressive. It’ll just be a humble filled circle drawn to your canvas, like this:
Primitive? Undoubtedly! But you’ll draw it by exercising the most basic muscle in the body of a ray tracer: ray casting.
Ray casting is the process of creating a ray, or line, and finding the intersections of that ray with ...
Get The Ray Tracer Challenge now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.