From 710666a51bc111069b93f6d37b9befd1b2a1f05e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mael=20Rouxel-Labb=C3=A9?= Date: Mon, 10 Jun 2024 13:57:38 +0200 Subject: [PATCH] Use the normal computation function that uses approximate_sqrt As to be able to write even for kernels that do not offer sqrt --- Stream_support/include/CGAL/IO/STL.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Stream_support/include/CGAL/IO/STL.h b/Stream_support/include/CGAL/IO/STL.h index d2c31b00cf8..bc74e20799b 100644 --- a/Stream_support/include/CGAL/IO/STL.h +++ b/Stream_support/include/CGAL/IO/STL.h @@ -317,7 +317,7 @@ bool write_STL(std::ostream& os, const Point& q = get(point_map, points[face[1]]); const Point& r = get(point_map, points[face[2]]); - const Vector_3 n = collinear(p,q,r) ? Vector_3(1,0,0) : unit_normal(p,q,r); + const Vector_3 n = internal::construct_normal_of_STL_face(p, q, r, k); const float coords[12] = { static_cast(n.x()), static_cast(n.y()), static_cast(n.z()), static_cast(p.x()), static_cast(p.y()), static_cast(p.z()),