diff --git a/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertex.H b/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertex.H index a9b997f6cb..246020fd17 100644 --- a/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertex.H +++ b/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertex.H @@ -92,12 +92,15 @@ class indexedVertex // Lowest numbered is inside one (master). int type_; - // Required alignment of the dual cell of this vertex + //- Required alignment of the dual cell of this vertex Foam::tensor alignment_; - // Target size of the dual cell of this vertex + //- Target size of the dual cell of this vertex Foam::scalar targetCellSize_; + //- Specify whether the vertex is fixed or movable. + bool vertexFixed_; + public: @@ -108,6 +111,12 @@ public: vtFar = INT_MIN + 2 }; + enum vertexMotion + { + fixed = 0, + movable = 1 + }; + typedef typename Vb::Vertex_handle Vertex_handle; typedef typename Vb::Cell_handle Cell_handle; typedef typename Vb::Point Point; @@ -214,6 +223,11 @@ public: //- Either a real or referred internal or boundary point inline bool anyInternalOrBoundaryPoint() const; + //- Is the vertex fixed or movable + inline bool isVertexFixed() const; + + //- Fix the vertex so that it can't be moved + inline void setVertexFixed() const; // inline void operator=(const Delaunay::Finite_vertices_iterator vit) // { diff --git a/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertexI.H b/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertexI.H index 86479321a9..c02ec4df20 100644 --- a/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertexI.H +++ b/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertexI.H @@ -37,7 +37,8 @@ inline CGAL::indexedVertex::indexedVertex() index_(vtInternal), type_(vtInternal), alignment_(), - targetCellSize_(0.0) + targetCellSize_(0.0), + vertexFixed_(false) {} @@ -48,7 +49,8 @@ inline CGAL::indexedVertex::indexedVertex(const Point& p) index_(vtInternal), type_(vtInternal), alignment_(), - targetCellSize_(0.0) + targetCellSize_(0.0), + vertexFixed_(false) {} @@ -64,7 +66,8 @@ inline CGAL::indexedVertex::indexedVertex index_(index), type_(type), alignment_(), - targetCellSize_(0.0) + targetCellSize_(0.0), + vertexFixed_(false) {} @@ -75,7 +78,8 @@ inline CGAL::indexedVertex::indexedVertex(const Point& p, Cell_handle f) index_(vtInternal), type_(vtInternal), alignment_(), - targetCellSize_(0.0) + targetCellSize_(0.0), + vertexFixed_(false) {} @@ -86,7 +90,8 @@ inline CGAL::indexedVertex::indexedVertex(Cell_handle f) index_(vtInternal), type_(vtInternal), alignment_(), - targetCellSize_(0.0) + targetCellSize_(0.0), + vertexFixed_(false) {} @@ -318,4 +323,18 @@ inline bool CGAL::indexedVertex::anyInternalOrBoundaryPoint() const } +template +inline bool CGAL::indexedVertex::isVertexFixed() const +{ + return vertexFixed_; +} + + +template +inline void CGAL::indexedVertex::setVertexFixed() const +{ + vertexFixed_ = true; +} + + // * * * * * * * * * * * * * * * Friend Functions * * * * * * * * * * * * * //