diff --git a/applications/utilities/mesh/generation/foamyHexMesh/conformalVoronoiMesh/DelaunayMesh/DelaunayMeshI.H b/applications/utilities/mesh/generation/foamyHexMesh/conformalVoronoiMesh/DelaunayMesh/DelaunayMeshI.H index bad25b2b83..daecf18c58 100644 --- a/applications/utilities/mesh/generation/foamyHexMesh/conformalVoronoiMesh/DelaunayMesh/DelaunayMeshI.H +++ b/applications/utilities/mesh/generation/foamyHexMesh/conformalVoronoiMesh/DelaunayMesh/DelaunayMeshI.H @@ -25,17 +25,6 @@ License // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // - - -// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // - - -// * * * * * * * * * * * * * * * * Destructors * * * * * * * * * * * * * * * // - - -// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // - template inline const Foam::Time& Foam::DelaunayMesh::time() const { @@ -70,23 +59,6 @@ void Foam::DelaunayMesh::timeCheck } -template -inline Foam::label Foam::DelaunayMesh::getNewVertexIndex() const -{ - label id = vertexCount_++; - - if (id == labelMax) - { - WarningIn - ( - "Foam::DelaunayMesh::getNewVertexIndex() const" - ) << "Vertex counter has overflowed." << endl; - } - - return id; -} - - template inline Foam::label Foam::DelaunayMesh::getNewCellIndex() const { @@ -105,16 +77,26 @@ inline Foam::label Foam::DelaunayMesh::getNewCellIndex() const template -Foam::label Foam::DelaunayMesh::cellCount() const +inline Foam::label Foam::DelaunayMesh::getNewVertexIndex() const { - return cellCount_; + label id = vertexCount_++; + + if (id == labelMax) + { + WarningIn + ( + "Foam::DelaunayMesh::getNewVertexIndex() const" + ) << "Vertex counter has overflowed." << endl; + } + + return id; } template -void Foam::DelaunayMesh::resetCellCount() +Foam::label Foam::DelaunayMesh::cellCount() const { - cellCount_ = 0; + return cellCount_; } @@ -125,6 +107,13 @@ Foam::label Foam::DelaunayMesh::vertexCount() const } +template +void Foam::DelaunayMesh::resetCellCount() +{ + cellCount_ = 0; +} + + template void Foam::DelaunayMesh::resetVertexCount() { @@ -132,22 +121,4 @@ void Foam::DelaunayMesh::resetVertexCount() } -// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * // - - -// * * * * * * * * * * * * * * * Friend Functions * * * * * * * * * * * * * // - - -// * * * * * * * * * * * * * * * Friend Operators * * * * * * * * * * * * * // - - -// * * * * * * * * * * * * * * IOstream Operators * * * * * * * * * * * * * // - - -// * * * * * * * * * * * * * * * Ostream Operator * * * * * * * * * * * * * // - - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - - // ************************************************************************* // diff --git a/applications/utilities/mesh/generation/foamyHexMesh/conformalVoronoiMesh/conformalVoronoiMesh/conformalVoronoiMesh.C b/applications/utilities/mesh/generation/foamyHexMesh/conformalVoronoiMesh/conformalVoronoiMesh/conformalVoronoiMesh.C index 258c06a568..1dd6baffb7 100644 --- a/applications/utilities/mesh/generation/foamyHexMesh/conformalVoronoiMesh/conformalVoronoiMesh/conformalVoronoiMesh.C +++ b/applications/utilities/mesh/generation/foamyHexMesh/conformalVoronoiMesh/conformalVoronoiMesh/conformalVoronoiMesh.C @@ -1135,7 +1135,7 @@ void Foam::conformalVoronoiMesh::move() && pointToBeRetained[vB->index()] == true ) { - Foam::point pt(0.5*(dVA + dVB)); + const Foam::point pt(0.5*(dVA + dVB)); if (internalPointIsInside(pt)) { @@ -1271,7 +1271,7 @@ void Foam::conformalVoronoiMesh::move() ) ) { - const Foam::point& newPt = 0.5*(dVA + dVB); + const Foam::point newPt(0.5*(dVA + dVB)); if (positionOnThisProc(newPt)) { @@ -1315,7 +1315,7 @@ void Foam::conformalVoronoiMesh::move() && pointToBeRetained[vB->index()] == true ) { - Foam::point pt(0.5*(dVA + dVB)); + const Foam::point pt(0.5*(dVA + dVB)); if (internalPointIsInside(pt)) {