diff --git a/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertex.H b/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/indexedVertex.H index a9b997f6cb8e3ee8fb088205618af554a566708b..246020fd172bbeb127089dc9bcc085c0aa7908e2 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 86479321a9385278b471f85b8a2a43e4d6108162..c02ec4df2009489efa9fe91221a666b9f9ae0050 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<Gt, Vb>::indexedVertex() index_(vtInternal), type_(vtInternal), alignment_(), - targetCellSize_(0.0) + targetCellSize_(0.0), + vertexFixed_(false) {} @@ -48,7 +49,8 @@ inline CGAL::indexedVertex<Gt, Vb>::indexedVertex(const Point& p) index_(vtInternal), type_(vtInternal), alignment_(), - targetCellSize_(0.0) + targetCellSize_(0.0), + vertexFixed_(false) {} @@ -64,7 +66,8 @@ inline CGAL::indexedVertex<Gt, Vb>::indexedVertex index_(index), type_(type), alignment_(), - targetCellSize_(0.0) + targetCellSize_(0.0), + vertexFixed_(false) {} @@ -75,7 +78,8 @@ inline CGAL::indexedVertex<Gt, Vb>::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<Gt, Vb>::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<Gt, Vb>::anyInternalOrBoundaryPoint() const } +template<class Gt, class Vb> +inline bool CGAL::indexedVertex<Gt, Vb>::isVertexFixed() const +{ + return vertexFixed_; +} + + +template<class Gt, class Vb> +inline void CGAL::indexedVertex<Gt, Vb>::setVertexFixed() const +{ + vertexFixed_ = true; +} + + // * * * * * * * * * * * * * * * Friend Functions * * * * * * * * * * * * * //