An implementation of convex container object for point The class implements methods to generate a convex hull for a point cloud, perform point location, and output to STL format. More...
Definition at line 113 of file convexContainer.H.
Public Member Functions | |
| convexContainer () | |
| default constructor More... | |
| convexContainer (std::vector< std::vector< double > > &verts) | |
| construct from a vector point coordinates More... | |
| convexContainer (std::vector< quickhull::Vector3< double > > &verts) | |
| virtual | ~convexContainer () |
| virtual void | setVertex (std::vector< std::vector< double > > &verts) |
| re-/setting vertice coordinates More... | |
| virtual void | computeConvexHull () |
| calculating the convex hull More... | |
| bool | isInConvexPoly (NEM::MTH::Vector const &p) |
| check for point containment More... | |
| bool | isInConvexPoly (const std::vector< double > &p) |
| void | toSTL (std::string file_name) const |
| generate STL triangulation from the convex hull More... | |
Private Attributes | |
| bool | _isReady |
| std::vector< quickhull::Vector3< double > > | vrts |
| quickhull::QuickHull< double > * | qHull |
| std::vector< Face > | fv |
| NEM::GEO::convexContainer::convexContainer | ( | ) |
Definition at line 38 of file convexContainer.C.
| NEM::GEO::convexContainer::convexContainer | ( | std::vector< std::vector< double > > & | verts | ) |
| verts | vector of vector of doubles of point coordinats |
Definition at line 43 of file convexContainer.C.
References setVertex().
| NEM::GEO::convexContainer::convexContainer | ( | std::vector< quickhull::Vector3< double > > & | verts | ) |
Definition at line 49 of file convexContainer.C.
References vrts.
|
inlinevirtual |
Definition at line 127 of file convexContainer.H.
|
virtual |
Definition at line 63 of file convexContainer.C.
References _isReady, fv, qHull, NEM::GEO::Face::v, vrts, NEM::MTH::Vector::x, NEM::MTH::Vector::y, and NEM::MTH::Vector::z.
Referenced by isInConvexPoly().
| bool NEM::GEO::convexContainer::isInConvexPoly | ( | NEM::MTH::Vector const & | p | ) |
| p | vector of coordinates of the point |
Definition at line 96 of file convexContainer.C.
References _isReady, computeConvexHull(), NEM::MTH::Vector::dot(), fv, and NEM::MTH::Vector::norm().
Referenced by isInConvexPoly().
| bool NEM::GEO::convexContainer::isInConvexPoly | ( | const std::vector< double > & | p | ) |
Definition at line 114 of file convexContainer.C.
References isInConvexPoly(), NEM::MTH::Vector::x, NEM::MTH::Vector::y, and NEM::MTH::Vector::z.
|
virtual |
| verts | vector of vector of doubles of point coordinats |
Definition at line 56 of file convexContainer.C.
References vrts.
Referenced by convexContainer().
| void NEM::GEO::convexContainer::toSTL | ( | std::string | file_name | ) | const |
| file_name | full path to the output STL file |
Definition at line 124 of file convexContainer.C.
References fv, NEM::MTH::Vector::x, NEM::MTH::Vector::y, and NEM::MTH::Vector::z.
|
private |
Definition at line 153 of file convexContainer.H.
Referenced by computeConvexHull(), and isInConvexPoly().
|
private |
Definition at line 156 of file convexContainer.H.
Referenced by computeConvexHull(), isInConvexPoly(), and toSTL().
|
private |
Definition at line 155 of file convexContainer.H.
Referenced by computeConvexHull().
|
private |
Definition at line 154 of file convexContainer.H.
Referenced by computeConvexHull(), convexContainer(), and setVertex().