Skip to Content.
Sympa Menu

cgal-discuss - [cgal-discuss] Getting vertices and tetra indices from Mesh_complex_3_in_triangulation_3

Subject: CGAL users discussion list

List archive

[cgal-discuss] Getting vertices and tetra indices from Mesh_complex_3_in_triangulation_3


Chronological Thread 
  • From: wakko <>
  • To:
  • Subject: [cgal-discuss] Getting vertices and tetra indices from Mesh_complex_3_in_triangulation_3
  • Date: Sun, 02 Dec 2012 12:09:15 +0100

Hi.
I have now spent several hours trying to retrieve the vertices
and tetrahedra indices from a tetra mesh generated using the
mesh_polyhedral_domain.cpp example. With no success, though...

Following the code, I expected the tetra vertices and indices
to be contained in the
typedef CGAL::Mesh_complex_3_in_triangulation_3<Tr> C3t3;
that will finally be written to the .mesh file.
Unfortunately, iterating over the Complex_Vertex_Iterator
(typedef
CGAL::Mesh_complex_3_in_triangulation_3<Tr>::Vertices_in_complex_iterator
Complex_Vertex_Iterator; )
does not output any vertices ( c3t3.number_of_vertices_in_complex()
returns 0 ), additionally there are no cells available. Not even the
field or a cell iterator is present.

std::cout<<"Complex Vertices :
"<<c3t3.number_of_vertices_in_complex()<<std::endl;
for (Complex_Vertex_Iterator it = c3t3.vertices_in_complex_begin();
it != c3t3.vertices_in_complex_end(); ++it)
{
std::cout<<"Complex Vertex #"<<i<<" :
"<<it->point()<<std::endl;
++i;
}

Can anyone give me some hints on how access the vertices and
tetra indices, as I am planning to use those in my own
data structures.

(Slightly off-topic:)
I am also wondering about the huge binary size of the
resulting executable (10 MB for release version, 90 MB
for Debug...). Have I missed a compiler/linker switch
for gcc/g++? Or is this normal for applications linking to CGAL?
(Current development system is Ubuntu 12.04, 32 bit,
using the packages from Ubuntu repositories).

Best regards.
Dennis






Archive powered by MHonArc 2.6.18.

Top of Page