From 693c537190b0cd458d28c3ee43d17b0773de7f87 Mon Sep 17 00:00:00 2001
From: laurence <laurence>
Date: Thu, 9 Feb 2012 10:41:04 +0000
Subject: [PATCH] BUG: cvMesh: Allow external boundaries to be filtered but not
 proc boundaries

---
 .../conformalVoronoiMeshCalcDualMesh.C        | 19 +++++--------------
 1 file changed, 5 insertions(+), 14 deletions(-)

diff --git a/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/conformalVoronoiMeshCalcDualMesh.C b/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/conformalVoronoiMeshCalcDualMesh.C
index 0a79cd620d1..04ef2af045d 100644
--- a/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/conformalVoronoiMeshCalcDualMesh.C
+++ b/applications/utilities/mesh/generation/cvMesh/conformalVoronoiMesh/conformalVoronoiMesh/conformalVoronoiMeshCalcDualMesh.C
@@ -79,9 +79,7 @@ void Foam::conformalVoronoiMesh::calcDualMesh
         }
     }
 
-// REMOVED BECAUSE THIS CODE STOPS ALL FACES NEAR ANY BOUNDARY (PROC OR REAL)
-// FROM BEING FILTERED.
-//
+    // THIS CODE STOPS ALL FACES NEAR ANY PROCESSOR BOUNDARY BEING FILTERED.
     for
     (
         Delaunay::Finite_vertices_iterator vit = finite_vertices_begin();
@@ -104,19 +102,12 @@ void Foam::conformalVoronoiMesh::calcDualMesh
             // Allow filtering if any vertices are far points. Otherwise faces
             // with boundary points attached to a cell with a far point will
             // not be filtered.
-//            if
-//            (
-//                (!(*cit)->vertex(0)->real() && !(*cit)->vertex(0)->farPoint())
-//             || (!(*cit)->vertex(1)->real() && !(*cit)->vertex(1)->farPoint())
-//             || (!(*cit)->vertex(2)->real() && !(*cit)->vertex(2)->farPoint())
-//             || (!(*cit)->vertex(3)->real() && !(*cit)->vertex(3)->farPoint())
-//            )
             if
             (
-                (!(*cit)->vertex(0)->real())
-             || (!(*cit)->vertex(1)->real())
-             || (!(*cit)->vertex(2)->real())
-             || (!(*cit)->vertex(3)->real())
+                (!(*cit)->vertex(0)->real() && !(*cit)->vertex(0)->farPoint())
+             || (!(*cit)->vertex(1)->real() && !(*cit)->vertex(1)->farPoint())
+             || (!(*cit)->vertex(2)->real() && !(*cit)->vertex(2)->farPoint())
+             || (!(*cit)->vertex(3)->real() && !(*cit)->vertex(3)->farPoint())
             )
             {
                 hasProcPt = true;
-- 
GitLab