diff --git a/Surface_mesh_topology/examples/Surface_mesh_topology/CMakeLists.txt b/Surface_mesh_topology/examples/Surface_mesh_topology/CMakeLists.txt index 31a82ebc13d..d971511e0b8 100644 --- a/Surface_mesh_topology/examples/Surface_mesh_topology/CMakeLists.txt +++ b/Surface_mesh_topology/examples/Surface_mesh_topology/CMakeLists.txt @@ -10,6 +10,8 @@ if(CGAL_Qt5_FOUND) add_definitions(-DCGAL_USE_BASIC_VIEWER -DQT_NO_KEYWORDS) endif() +# add_definitions(-DCGAL_TRACE_PATH_TESTS) + if ( CGAL_FOUND ) # create a target per cppfile diff --git a/Surface_mesh_topology/examples/Surface_mesh_topology/path_homotopy.cpp b/Surface_mesh_topology/examples/Surface_mesh_topology/path_homotopy.cpp index f178365f450..ebbd6a1665c 100644 --- a/Surface_mesh_topology/examples/Surface_mesh_topology/path_homotopy.cpp +++ b/Surface_mesh_topology/examples/Surface_mesh_topology/path_homotopy.cpp @@ -126,6 +126,10 @@ int main(int argc, char** argv) for (unsigned int i=0; i::max())); @@ -150,8 +154,7 @@ int main(int argc, char** argv) CGAL::Path_on_surface path1(lcc); path1.generate_random_closed_path(F, random); - //if (path1.length()<100000) // TEMPO FOR DEBUG - { + //if (path1.length()<100000) { // TEMPO FOR DEBUG std::cout<<"Path1 size: "<end; } + void display_flat(std::ostream& os, const List_iterator& flat) + { + os<<"["<begin)<<", " + <end)<<" (l="<length<<")]"; + } + /// @return true iff the path is valid; i.e. a sequence of flats two by /// two adjacent. /// if test_minimal is true, test that there is no two consecutive flats @@ -977,6 +983,12 @@ public: if (!can_merge_with_next_flat(it, positive2, negative2)) { return false; } +#ifdef CGAL_TRACE_PATH_TESTS + std::cout<<"Merge with next flat: "; + display_flat(std::cout, it); std::cout<<" and "; + display_flat(std::cout, next_iterator(it)); std::cout<