Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Converting Tetgen triangulation to CGAL

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Converting Tetgen triangulation to CGAL


Chronological Thread 
  • From: Andreas Fabri <>
  • To:
  • Subject: Re: [cgal-discuss] Converting Tetgen triangulation to CGAL
  • Date: Wed, 30 Nov 2016 08:19:52 +0100
  • Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None ; spf=None ; spf=None
  • Ironport-phdr: 9a23:s/0WchJZFhUkKMle9tmcpTZWNBhigK39O0sv0rFitYgUKvjxwZ3uMQTl6Ol3ixeRBMOAuqkC0Lqd6vi6ESxYuNDa7yBEKMQNHzY+yuwo3CUYSPafDkP6KPO4JwcbJ+9lEGFfwnegLEJOE9z/bVCB6le77DoVBwmtfVEtfre9LKeJ0J/yj7z6u8CLIlYAuD3oarx7KFC6rB7aq9INqYpkMKc4jBXT8VVSfOED7GVkP1+ahF7S782q/dY3+iJcof8o7IhOWK/gfow3QLtdASg8Im4879HsrwiFRgyKsChPGl4KmwZFVlCWpCrxWY3853aiuw==
  • Organization: GeometryFactory


Hello,

On 30/11/2016 08:16, Thomas Holzmann wrote:
So if I additionally add the cell neighbors and the infinite cells, it
should work like I did it?

Does tetgen produce a tetrahedrization of the convex hull of the points?
The infinite cells are outside of the convex hull.

You probably also have to set the cell incident to each vertex.

best,

andreas


Thanks!

Thomas


On 11/29/2016 05:26 PM, Andreas Fabri wrote:
Not only you are responsible for the neighbor, but CGAL has
also the infinite cells, incident to the infinite vertex,
in case tetgen has no infinite vertex.

andreas


On 29/11/2016 17:23, Thomas Holzmann wrote:
Hi all,

I created a constrained Delaunay triangulation in 3D with Tetgen and
want to convert it now to a CGAL triangulation. As it is no Delaunay
triangulation anymore, I try to create an unrestricted
CGAL::Triangulation_3<CGAL::Exact_predicates_inexact_constructions_kernel,CGAL::Triangulation_data_structure_3<Vbh,

Cb> > wit the data from the CDT.

When I use the "normal" insert function to incrementally create the
triangulation, I cannot directly influence the structure of the
triangulation and therefore, as I want to keep the structure, this is
not an option for me (am I right?).

So I tried to directly add the vertices and cells in the TDS using:

v1 = cgalTriangulation.tds().create_vertex(cgal_pt);
...
cell = cgalTriangulation.tds().create_cell(v1, v2, v3, v4);

However, it seems as if the cells are not added.

Here are the statistics of the triangulation after adding the data:

number_of_vertices() = 253792

number_of_finite_facets () = 0

number_of_finite_cells () = 0


cgalTriangulation.is_valid(true) says:
valid data structure
valid triangulation

Do I also need to set the cell neighbors and/or facets? Or am I
completely wrong with my approach?

Any help would be appreciated!

Thomas

--
====================================================
Dipl.-Ing. Thomas Holzmann
TU Graz - Institut fuer Maschinelles Sehen und Darstellen
Graz University of Technology - Institute for Computer Graphics & Vision
Inffeldgasse 16/II, 8010 Graz, Austria

http://www.icg.tugraz.at/
phone: +43 316 873 5091
====================================================




--
Andreas Fabri, PhD
Chief Officer, GeometryFactory
Editor, The CGAL Project

phone: +33.492.954.912 skype: andreas.fabri



Archive powered by MHonArc 2.6.18.

Top of Page