From 4525eeb988d23c0e81831b6cd4564a664e0c8aed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Loriot?= Date: Thu, 25 Apr 2024 19:29:48 +0200 Subject: [PATCH] do not modify the map if not the default one --- .../CGAL/Polygon_mesh_processing/remesh_planar_patches.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Polygon_mesh_processing/include/CGAL/Polygon_mesh_processing/remesh_planar_patches.h b/Polygon_mesh_processing/include/CGAL/Polygon_mesh_processing/remesh_planar_patches.h index 7d41f28d5b7d..71e49fcbffa0 100644 --- a/Polygon_mesh_processing/include/CGAL/Polygon_mesh_processing/remesh_planar_patches.h +++ b/Polygon_mesh_processing/include/CGAL/Polygon_mesh_processing/remesh_planar_patches.h @@ -1430,6 +1430,7 @@ void remesh_planar_patches(const TriangleMeshIn& tm_in, typedef typename GetVertexPointMap ::type VPM_out; using parameters::choose_parameter; using parameters::get_parameter; + using parameters::is_default_parameter; typedef typename boost::graph_traits graph_traits; typedef typename graph_traits::edge_descriptor edge_descriptor; @@ -1465,7 +1466,8 @@ void remesh_planar_patches(const TriangleMeshIn& tm_in, face_cc_ids = choose_parameter(get_parameter(np_in, internal_np::face_patch), dynamic_face_property_t(), tm_in); - for(edge_descriptor e : edges(tm_in)) put(edge_is_constrained, e, false); + if (is_default_parameter::value) + for(edge_descriptor e : edges(tm_in)) put(edge_is_constrained, e, false); for(vertex_descriptor v : vertices(tm_in)) put(vertex_corner_id, v, Planar_segmentation::default_id()); for(face_descriptor f : faces(tm_in)) put(face_cc_ids, f, -1);