From a7b6f61ca1f1d6b6d8d7252db093760a37561b70 Mon Sep 17 00:00:00 2001 From: Ben Laurie Date: Mon, 14 Dec 2020 10:57:49 +0000 Subject: [PATCH] Use C++ casts and the right type. --- BGL/include/CGAL/boost/graph/generators.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/BGL/include/CGAL/boost/graph/generators.h b/BGL/include/CGAL/boost/graph/generators.h index 4160b1cc0ae..151ffe1df50 100644 --- a/BGL/include/CGAL/boost/graph/generators.h +++ b/BGL/include/CGAL/boost/graph/generators.h @@ -483,15 +483,15 @@ make_regular_prism(typename boost::graph_traits::vertices_size_type nb_ve for(typename boost::graph_traits::vertices_size_type i=0; i < nb_vertices; ++i) { put(vpmap, vertices[i], - P(0.5*diameter * cos(i*precision*to_rad) + base_center.x(), + P(0.5*diameter * cos(to_double(FT(i)*precision*to_rad)) + base_center.x(), height+base_center.y(), - -0.5*diameter * sin(to_double((double)i*precision*to_rad)) + base_center.z())); + -0.5*diameter * sin(to_double(FT(i)*precision*to_rad)) + base_center.z())); put(vpmap, vertices[i+nb_vertices], - P(0.5*diameter * cos(to_double((double)i*precision*to_rad)) + base_center.x(), + P(0.5*diameter * cos(to_double(FT(i)*precision*to_rad)) + base_center.x(), base_center.y(), - -0.5*diameter * sin(to_double((double)i*precision*to_rad)) + base_center.z())); + -0.5*diameter * sin(to_double(FT(i)*precision*to_rad)) + base_center.z())); } //fill faces @@ -589,9 +589,9 @@ make_pyramid(typename boost::graph_traits::vertices_size_type nb_vertices for(typename boost::graph_traits::vertices_size_type i=0; i