From ec8bfa577a5e7018a4d74ace4b56bd8967104d6f Mon Sep 17 00:00:00 2001 From: Sebastien Loriot Date: Thu, 4 Mar 2021 09:02:33 +0100 Subject: [PATCH 1/3] missing typename --- .../test/Polygon_mesh_processing/remeshing_test.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Polygon_mesh_processing/test/Polygon_mesh_processing/remeshing_test.cpp b/Polygon_mesh_processing/test/Polygon_mesh_processing/remeshing_test.cpp index 90bbd45564e..82d15fc9a7b 100644 --- a/Polygon_mesh_processing/test/Polygon_mesh_processing/remeshing_test.cpp +++ b/Polygon_mesh_processing/test/Polygon_mesh_processing/remeshing_test.cpp @@ -248,9 +248,9 @@ Main(int argc, char* argv[]) } else if (sharp_angle > 0) { - typedef boost::property_map::type EIFMap; - typedef boost::property_map >::type PIMap; - typedef boost::property_map >::type VIMap; + typedef typename boost::property_map::type EIFMap; + typedef typename boost::property_map >::type PIMap; + typedef typename boost::property_map >::type VIMap; EIFMap eif = get(CGAL::edge_is_feature, m); PIMap pid = get(CGAL::face_patch_id_t(), m); From 0710924d3b1bcef208702947823d72e00ff842a2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Loriot?= Date: Thu, 4 Mar 2021 09:34:40 +0100 Subject: [PATCH 2/3] accomodate is_badly_shape API update --- .../internal/Isotropic_remeshing/remesh_impl.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Polygon_mesh_processing/include/CGAL/Polygon_mesh_processing/internal/Isotropic_remeshing/remesh_impl.h b/Polygon_mesh_processing/include/CGAL/Polygon_mesh_processing/internal/Isotropic_remeshing/remesh_impl.h index 9e82555bbd9..847f4aa8e6a 100644 --- a/Polygon_mesh_processing/include/CGAL/Polygon_mesh_processing/internal/Isotropic_remeshing/remesh_impl.h +++ b/Polygon_mesh_processing/include/CGAL/Polygon_mesh_processing/internal/Isotropic_remeshing/remesh_impl.h @@ -841,13 +841,14 @@ namespace internal { std::array r1 = PMP::internal::is_badly_shaped( face(he, mesh_), - mesh_, vpmap_, ecmap_, gt_, + mesh_, vpmap_, vcmap_, ecmap_, gt_, cap_threshold, // bound on the angle: above 160 deg => cap 4, // bound on shortest/longest edge above 4 => needle 0);// collapse length threshold : not needed here std::array r2 = PMP::internal::is_badly_shaped( face(opposite(he, mesh_), mesh_), - mesh_, vpmap_, ecmap_, gt_, cap_threshold, 4, 0); + mesh_, vpmap_, vcmap_, ecmap_, gt_, cap_threshold, 4, 0); + const bool badly_shaped = (r1[0] != boost::graph_traits::null_halfedge()//needle || r1[1] != boost::graph_traits::null_halfedge()//cap || r2[0] != boost::graph_traits::null_halfedge()//needle From a177ed01a45e0e55620756da161a6ee4b8114525 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Loriot?= Date: Thu, 4 Mar 2021 09:34:56 +0100 Subject: [PATCH 3/3] fix warnings --- .../remeshing_test.cpp | 25 ++++++++++--------- 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/Polygon_mesh_processing/test/Polygon_mesh_processing/remeshing_test.cpp b/Polygon_mesh_processing/test/Polygon_mesh_processing/remeshing_test.cpp index 82d15fc9a7b..80c8a810e22 100644 --- a/Polygon_mesh_processing/test/Polygon_mesh_processing/remeshing_test.cpp +++ b/Polygon_mesh_processing/test/Polygon_mesh_processing/remeshing_test.cpp @@ -152,7 +152,7 @@ public: -Main(int argc, char* argv[]) +Main(int argc, const char* argv[]) { #ifdef CGAL_PMP_REMESHING_DEBUG std::cout.precision(17); @@ -256,9 +256,8 @@ Main(int argc, char* argv[]) PIMap pid = get(CGAL::face_patch_id_t(), m); VIMap vip = get(CGAL::vertex_incident_patches_t(), m); - std::size_t number_of_patches; if (sharp_angle > 0) - number_of_patches = PMP::sharp_edges_segmentation(m, sharp_angle, eif, pid, + PMP::sharp_edges_segmentation(m, sharp_angle, eif, pid, PMP::parameters::vertex_incident_patches_map(vip)); std::vector sharp_edges; @@ -310,20 +309,22 @@ Main(int argc, char* argv[]) } }; -int main(int argc, char* argv[]) +int main(int argc, const char* argv[]) { Main m(argc,argv); - char* param[6] = { "remesh",//command - "data_remeshing/cheese_transformed-facets.off",//input - "0.0015", //target edge length - "3", //#iterations - "0", //selection file - "60." }; //sharp angle bound + const char* param[6] = { "remesh",//command + "data_remeshing/cheese_transformed-facets.off",//input + "0.0015", //target edge length + "3", //#iterations + "0", //selection file + "60." }; //sharp angle bound Main sharp1(6, param); - param[1] = "data_remeshing/cheese_transformed-facets-2.off"; - Main sharp2(6, param); + const char* param_bis[6] = { param[0], + "data_remeshing/cheese_transformed-facets-2.off", + param[2], param[3], param[4], param[5] }; + Main sharp2(6, param_bis); return 0; }