Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Triangulation iterator: too many edges?

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Triangulation iterator: too many edges?


Chronological Thread 
  • From: "Laurent Rineau (GeometryFactory)" <>
  • To:
  • Subject: Re: [cgal-discuss] Triangulation iterator: too many edges?
  • Date: Tue, 21 Jun 2011 15:07:43 +0200
  • Organization: GeometryFactory

On mardi 21 juin 2011 14:40:41 GClaeys wrote:
> Hello,
>
> I have a problem with iterating over all edges of a 3D mesh complex. I use
> the finite_edges_iterator from the
> CGAL::Mesh_complex_3_in_triangulation_3::Triangulation class, but this
> iterator returns not only the internal edges but also edges outside the
> tetrahedron mesh.
>
> for (Triangulation::Finite_edges_iterator it = tr.finite_edges_begin(); it
> != tr.finite_edges_end(); ++it) {
> start = it->first->vertex(it->second)->point();
> end = it->first->vertex(it->third)->point();
> //...
> }
>
> Is there a way to iterate over the internal edges only (those of the
> tetrahedra)?

That is difficult.

Why do you need only the edges of the mesh? Would it be OK to iterate over
the
facets or the tetrahedra of the mesh instead?

--
Laurent Rineau, PhD
R&D Engineer at GeometryFactory http://www.geometryfactory.com/
Release Manager of the CGAL Project http://www.cgal.org/



Archive powered by MHonArc 2.6.16.

Top of Page