Today I picked up a ray tracing program from a thread Post your sample source code here and get featured on our blogs! (Part II) in Small Basic forum.
Thank you ThirdMagus for sharing this program!
It’s a cute lil’ raytracer in Small Basic! It uses orthographic projection (not perspective), up to 10x reflection, any number of lights and spheres (but no other shapes) and diffuse (Lambertian) lighting (no specular highlights). For those unfamiliar with raytracing: it’s not the fastest technique around. And Small Basic isn’t known for it’s amazing speed either so it takes several minutes to completely render the scene.
The code is heavily based on (or rather a port of) the code found on this raytracing tutorial: http://www.codermind.com/articles/Raytracer-in-C++-Part-I-First-rays.html
NEW! The lil’ raytracer special Dudeson Awesomer edition! Includes random scene generation and scene preview. Get yours today!
Following picture is another screen shot of this program.