From 40c84bdfd0182c7936abbe7912d274e99a45c4bf Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jean-Fran=C3=A7ois=20Remacle=20=28students=29?=
 <jean-francois.remacle@uclouvain.be>
Date: Tue, 21 Apr 2009 11:51:20 +0000
Subject: [PATCH] Added a function to detect if a GVertex is on a seam of a
 GFace

---
 Geo/GVertex.cpp | 9 +++++++++
 Geo/GVertex.h   | 3 +++
 2 files changed, 12 insertions(+)

diff --git a/Geo/GVertex.cpp b/Geo/GVertex.cpp
index 3bf0d3fa29..4eb8f03ed3 100644
--- a/Geo/GVertex.cpp
+++ b/Geo/GVertex.cpp
@@ -73,3 +73,12 @@ MElement *GVertex::getMeshElement(unsigned int index)
     return points[index]; 
   return 0;
 }
+
+bool GVertex::isOnSeam(const GFace *gf) const
+{
+  std::list<GEdge*>::const_iterator eIter = l_edges.begin();
+  for (; eIter != l_edges.end(); eIter++) {
+    if ( (*eIter)->isSeam(gf) ) return true;
+  }
+  return false;
+}
diff --git a/Geo/GVertex.h b/Geo/GVertex.h
index 27db6204b6..65cd4ddf67 100644
--- a/Geo/GVertex.h
+++ b/Geo/GVertex.h
@@ -71,6 +71,9 @@ class GVertex : public GEntity
   // get the element at the given index
   MElement *getMeshElement(unsigned int index);
 
+  // return true if this vertex is on a seam of the given face
+  bool isOnSeam(const GFace *gf) const;
+
   std::vector<MPoint*> points;
 };
 
-- 
GitLab