fart/shapes/Intersect.cc
Josh Holtrop bcbec65a8f converted shapes/Intersect::intersect() to using BoolIntersectionList
git-svn-id: svn://anubis/fart/trunk@152 7f9b0f55-74a9-4bce-be96-3c2cd072584d
2009-02-24 03:04:26 +00:00

29 lines
626 B
C++

#include "Intersect.h"
Intersect::Intersect(refptr<Shape> shape1, refptr<Shape> shape2)
{
m_shape1 = shape1;
m_shape2 = shape2;
}
Shape::IntersectionList Intersect::intersect(refptr<Shape> _this, const Ray & ray)
{
IntersectionList res1 = m_shape1->intersect(m_shape1, ray);
IntersectionList res2 = m_shape2->intersect(m_shape2, ray);
BoolIntersectionList merged(res1, res2, ray.getOrigin());
IntersectionList res;
bool in1 = false, in2 = false;
/* TODO: finish */
return res;
}
Vector Intersect::getNormalAt(const Vector & pt)
{
/* TODO: finish */
return Vector(0, 0, 0);
}