A functional raytracer in C++