/*********************************************************** CSC418, SPRING 2005 scene_object.cpp author: Jack Wang implements scene_object.h ***********************************************************/ #include "scene_object.h" bool UnitSquare::intersect( Ray3D& ray, Matrix4x4 worldToModel, Matrix4x4 modelToWorld ) { // TODO: implement intersection code for UnitSquare, which is // defined on the xy-plane, with vertices (0.5, 0.5, 0), // (-0.5, 0.5, 0), (-0.5, -0.5, 0), (0.5, -0.5, 0), and normal // (0, 0, 1). // // Your goal here is to fill ray.intersection with correct values // should an intersection occur. // // HINT: Remember the ray is already in object space at this point // so the intersection test should be simple. return false; }