mirror of https://github.com/CGAL/cgal
fixed test suite errors in examples
This commit is contained in:
parent
ec13e880a4
commit
c2a1f047eb
|
|
@ -109,7 +109,7 @@ int main (int argc, char** argv)
|
|||
|
||||
// Save in colored_circles.ply
|
||||
std::ofstream out ("colored_circles.ply");
|
||||
CGAL::set_binary_mode (out);
|
||||
CGAL::IO::set_binary_mode (out);
|
||||
out << points3;
|
||||
|
||||
return EXIT_SUCCESS;
|
||||
|
|
|
|||
|
|
@ -90,7 +90,7 @@ int main (int argc, char** argv)
|
|||
|
||||
// Save in colored_cylinders.ply
|
||||
std::ofstream out ("colored_cylinders.ply");
|
||||
CGAL::set_binary_mode (out);
|
||||
CGAL::IO::set_binary_mode (out);
|
||||
out << points;
|
||||
|
||||
return EXIT_SUCCESS;
|
||||
|
|
|
|||
|
|
@ -90,7 +90,7 @@ int main (int argc, char** argv)
|
|||
|
||||
// Save in colored_spheres.ply
|
||||
std::ofstream out ("colored_spheres.ply");
|
||||
CGAL::set_binary_mode (out);
|
||||
CGAL::IO::set_binary_mode (out);
|
||||
out << points;
|
||||
|
||||
return EXIT_SUCCESS;
|
||||
|
|
|
|||
|
|
@ -44,6 +44,9 @@ namespace internal {
|
|||
public:
|
||||
FT operator()(const FT value) const {
|
||||
|
||||
// TODO: This happens for circles and cylinders only! Maybe after my
|
||||
// precision cleaning in the new revision PR, this will be gone for all platforms.
|
||||
if (value < FT(0)) return FT(0); // clamp to zero
|
||||
CGAL_precondition(value >= FT(0));
|
||||
return static_cast<FT>(CGAL::sqrt(CGAL::to_double(value)));
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue