Polyhedron.cpp   Polyhedron.cpp 
skipping to change at line 91 skipping to change at line 91
//Check normal direction //Check normal direction
Plane polyPlane(p.vertices[0], p.vertices[1], p.vertices[2], SPolygo n::CCW); Plane polyPlane(p.vertices[0], p.vertices[1], p.vertices[2], SPolygo n::CCW);
//Might need to reverse the vertex order //Might need to reverse the vertex order
if(polyPlane.normal.dot(normal) < 0.0f) p.reverseOrder(); if(polyPlane.normal.dot(normal) < 0.0f) p.reverseOrder();
polygons.append(p); polygons.append(p);
} }
void Polyhedron::intersect(const AABB &bb) void Polyhedron::intersect(const AABBox &bb)
{ {
for(unsigned int i=0; i<AABB::PLANECOUNT; i++) for(unsigned int i=0; i<AABBox::FACECOUNT; i++)
{ {
intersect(Plane(bb.getEquation(static_cast<AABB::Plane>(i))) ); intersect(Plane(bb.getPlane(static_cast<AABBox::Face>(i))));
} }
} }
void Polyhedron::intersect(const Plane &p) void Polyhedron::intersect(const Plane &p)
{ {
//Save intersection points //Save intersection points
QVector<Vec3f> intersectionPoints; QVector<Vec3f> intersectionPoints;
//Iterate over this polyhedron's polygons //Iterate over this polyhedron's polygons
for(QVector<SPolygon>::iterator it = polygons.begin(); it != polygon s.end();) for(QVector<SPolygon>::iterator it = polygons.begin(); it != polygon s.end();)
skipping to change at line 204 skipping to change at line 204
return true; return true;
} }
} }
else else
{ {
return q >= 0.0f; return q >= 0.0f;
} }
} }
} }
void Polyhedron::extrude(const Vec3f &dir, const AABB &bb) void Polyhedron::extrude(const Vec3f &dir, const AABBox &bb)
{ {
makeUniqueVerts(); makeUniqueVerts();
const Vec3f &min = bb.min; const Vec3f &min = bb.min;
const Vec3f &max = bb.max; const Vec3f &max = bb.max;
unsigned int size = static_cast<unsigned int>(uniqueVerts.size()); unsigned int size = static_cast<unsigned int>(uniqueVerts.size());
for(unsigned int i=0; i<size; i++) for(unsigned int i=0; i<size; i++)
{ {
 End of changes. 4 change blocks. 
4 lines changed or deleted 4 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/