Subject: CGAL users discussion list
List archive
- From: sergio campo <>
- To:
- Subject: Re: [cgal-discuss] How to find the adjacent faces of every edge?
- Date: Fri, 22 Jun 2018 12:24:35 +0200
- Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None ; spf=Pass ; spf=None
- Ironport-phdr: 9a23:RN/FiRcR0+bcCYdUBhgh0aEVlGMj4u6mDksu8pMizoh2WeGdxcS/ZB7h7PlgxGXEQZ/co6odzbaO7ua4ASQp2tWoiDg6aptCVhsI2409vjcLJ4q7M3D9N+PgdCcgHc5PBxdP9nC/NlVJSo6lPwWB6nK94iQPFRrhKAF7Ovr6GpLIj8Swyuu+54Dfbx9HiTahYb5+Ngm6oRnMvcQKnIVuLbo8xAHUqXVSYeRWwm1oJVOXnxni48q74YBu/SdNtf8/7sBMSar1cbg2QrxeFzQmLns65Nb3uhnZTAuA/WUTX2MLmRdVGQfF7RX6XpDssivms+d2xSeXMdHqQb0yRD+v6bpgRh31hycdLzM28m/XhMx+gqxYvRyvuQBwzpXOb42JLvdzZL/Rcc8YSGdHQ81fVzZBAoS5b4YXFOoOI/xYr4b8p1sJsBCxGROjBOb3yj9Pm3T72rM63P49HgHH2gwgENwOsHPOrNXyL6oSXuW1w7PJzTXHdf9ZxTD96I3Rfx0nvPqCU7Vwcc/LxkkuEQPIllOQppb+MDyO0uQCrXKX4PZnVeKqk2InqgdxoiKuxsg2kIXJiJgVxkjY+iV22ok1Ice0SElhYd6rCJdfqy6aOJFyQs84WW1ovzw6yrIAtJWmfyYK0IwqywDDZ/GDaYSF4RLuWPyPLTtkh39pYrOyiha0/EO90OPzTNO030xPriddktnDqHQN1xvL58iCUPR9/0Oh1S+R2A/O9+1IOE40mKvbJpI7zb4wkZ0TsUvHHiDogkn5kKiWdkA89uip7eTofKnmq4eCO4NojgzyKKcjl8ylDegmLgQDXHKX9OW82bH7+E32WrRKjvk4kqnDt5DaINwWprCjDABJ04Yj7Rm/Dzmh0NQCmnkKN11FeBedgIjoP1HCOuz3DfC6g1i0ijdk2+jGPqH9ApXKNnXMjLjhcqx560JF1QUzzMtf6I5JCrEaO/L+QVTxtdzdDh8hKQO42efnCNNn1oMfQ22DGKGZMLmB+WKO/f8ldumQeJcO6nG6MOkg//eojHkjmFZbc7PuxooScHn/H/JoJAKSbnPox9sACmwXpRFtcOu/g1KLVXtfZm25QrknzjA9EoOvS4nZFa63h7nUxyqhEZxRLmtPD0iLWSP2fo6FXfgCbziVCsBkmz0AE7OmTtlyhlmVqAbmxu8/faLv8SoCuMe7jYkn16jojRg3sAdMIYGY2mCJQXtzmzpRFTAz1aF750d6zwXaiPQqs7ljDdVWoshxfEIiL5eFlr51DtnzXkTKedLbEA/7EOXjOik4S5cK+/FLY0t5HI//3BXK3i7vDrNM0rLVWdo79aXT23W3LMF4mS7L
What happen if the structure has non-manifold edges, it will work?
On Fri, Jun 22, 2018 at 11:35 AM, Sebastien Loriot (GeometryFactory) <> wrote:
If you have a index associated to faces, then from a halfedge you can access the faces using
halfedge_descriptor h;
face_descriptor f1 = face(h, mesh);
halfedge_descriptor h_opp = opposite(h, mesh);
if (!CGAL::is_border(h_opp, mesh))
face_descriptor f2 = face(h_opp, mesh);
with halfedge_descriptor and face_descriptor being nested types of
boost::graph_traits<Mesh_type>
To associate an id to a face, you can use internal property (built-in
with Surface_mesh or with a traits with ids like CGAL::Polyhedron_items_with_id_3 [1]). In general you can also use
dynamic properties [2]
Sebastien.
[1] https://doc.cgal.org/latest/BGL/classCGAL_1_1Polyhedron__items__with__id__3.html
[2] https://doc.cgal.org/latest/BGL/index.html#title25
On 06/22/2018 10:48 AM, sergio wrote:
I have the following loop iterator:
void printAdjancenFaceToEdge(Polyhedron mesh)
{
std::vector<int> nBorder(mesh.size_of_vertices(), 0);
for (Polyhedron::Halfedge_const_iterator he = mesh.halfedges_begin(); he
!= mesh.halfedges_end(); he++) {
if (!he->is_border())
continue;
// print here ids
}
return true;
}
is it possible to print the adjacent faces index of every edge?
--
Sent from: http://cgal-discuss.949826.n4.nabble.com/
--
You are currently subscribed to cgal-discuss.
To unsubscribe or access the archives, go to
https://sympa.inria.fr/sympa/info/cgal-discuss
- [cgal-discuss] How to find the adjacent faces of every edge?, sergio, 06/22/2018
- Re: [cgal-discuss] How to find the adjacent faces of every edge?, Sebastien Loriot (GeometryFactory), 06/22/2018
- Re: [cgal-discuss] How to find the adjacent faces of every edge?, sergio campo, 06/22/2018
- Re: [cgal-discuss] How to find the adjacent faces of every edge?, Sebastien Loriot (GeometryFactory), 06/22/2018
- Re: [cgal-discuss] How to find the adjacent faces of every edge?, sergio campo, 06/22/2018
- Re: [cgal-discuss] How to find the adjacent faces of every edge?, Shankar Kulumani, 06/22/2018
- Re: [cgal-discuss] How to find the adjacent faces of every edge?, sergio campo, 06/22/2018
- Re: [cgal-discuss] How to find the adjacent faces of every edge?, Sebastien Loriot (GeometryFactory), 06/22/2018
Archive powered by MHonArc 2.6.18.