Open lrineau opened 1 year ago
Note: I encountered that issue while working on CDT_3. My data set was not 2D, but as the triangulation is built incrementally, segment by segment, if the the first loaded segments are in the xy-plane, I have that issue. That is not a blocker bug.
As for the gist, the easiest is to clone it locally:
git clone https://gist.github.com/d2002ee2044502a8200ad49de6dc7058.git
I tried it with CGAL-5.5.x and master.
Issue Details
With a 2D triangulation, the class
Triangulation_segment_cell_iterator_3
does not work, and crashes.Source Code
See the full code at https://gist.github.com/lrineau/d2002ee2044502a8200ad49de6dc7058. Extract:
There is a self-contained
.cpp
file, andCMakeLists.txt
file. The.cpp
loads a pre-existing 2DTriangulation_3<Epick>
object, that is valid.There is also a
.js
file to load with the CGAL 3D demo, to load that scene:The black lines are a triangulation in the plane z==0, and the red line is the query segment for
Triangulation_segment_cell_iterator_3
.In the following picture, the visited cells, are:
[1, 2, 3, 4]
and then a crash:But the correct cell sequence should be
[2, 3, 5, 6]
.The problem seems in
void Triangulation_segment_cell_iterator_3<Tr,Inc>::walk_to_next_2()
.