SingleSphere

SingleSphere - / SingleSphere::~SingleSphere(void) {} S //

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
#include "SingleSphere.h" #include "World.h" #include "ShadeRec.h" # // -------------------------------------------------------------------- default constructor c SingleSphere::SingleSphere(void) : Tracer() {} { // -------------------------------------------------------------------- constructor / SingleSphere::SingleSphere(World* _worldPtr) : Tracer(_worldPtr) {} { // -------------------------------------------------------------------- destructor
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: / SingleSphere::~SingleSphere(void) {} S // -------------------------------------------------------------------- trace_ray / RGBColor R SingleSphere::trace_ray(const Ray& ray) const { ShadeRec sr(*world_ptr); // not used double t; // not used / if (world_ptr->sphere.hit(ray, t, sr)) i return (red); else return (black); }...
View Full Document

Ask a homework question - tutors are online