/* * TriangleIntersectionList.hpp * * Created on: Mar 1, 2010 * Author: heber */ #ifndef TRIANGLEINTERSECTIONLIST_HPP_ #define TRIANGLEINTERSECTIONLIST_HPP_ using namespace std; /*********************************************** includes ***********************************/ // include config.h #ifdef HAVE_CONFIG_H #include #endif #include /****************************************** forward declarations *****************************/ class BoundaryTriangleSet; class LinkedCell_deprecated; class Tesselation; class Vector; /********************************************** definitions *********************************/ #define TriangleVectorMap map < class BoundaryTriangleSet *, Vector *> #define DistanceTriangleMap map < double, class BoundaryTriangleSet *> // ======================================================== class TriangleIntersectionList ======================================= /** Stores all intersection vectors to a list of triangles. */ class TriangleIntersectionList { public: TriangleIntersectionList(const Vector &x, const Tesselation *surface, const LinkedCell_deprecated* LC); ~TriangleIntersectionList(); double GetSmallestDistance() const; Vector GetClosestIntersection() const; BoundaryTriangleSet * GetClosestTriangle() const; bool IsInside() const; private: void GatherIntersectionsWithTriangles(); TriangleVectorMap::const_iterator GetIteratortoSmallestDistance() const; void FillDistanceList() const; const Vector &Point; const Tesselation *Tess; const LinkedCell_deprecated *Vicinity; TriangleVectorMap IntersectionList; mutable DistanceTriangleMap DistanceList; }; #endif /* TRIANGLEINTERSECTIONLIST_HPP_ */