diff --git a/Stream_support/include/CGAL/IO/OBJ/File_writer_wavefront.h b/Stream_support/include/CGAL/IO/OBJ/File_writer_wavefront.h index 526f1182235..a9fbffc5bbb 100644 --- a/Stream_support/include/CGAL/IO/OBJ/File_writer_wavefront.h +++ b/Stream_support/include/CGAL/IO/OBJ/File_writer_wavefront.h @@ -53,11 +53,11 @@ public: void write_footer() const { out() << "\n# End of Wavefront obj format #" << std::endl; } void write_vertex(const double x, const double y, const double z) { - out() << "v " << x << ' ' << y << ' ' << z << '\n'; + out() << "v " << oformat(x) << ' ' << oformat(y) << ' ' << oformat(z) << '\n'; } void write_vertex_normal(const double x, const double y, const double z) { - out() << "vn " << x << ' ' << y << ' ' << z << '\n'; + out() << "vn " << oformat(x) << ' ' << oformat(y) << ' ' << oformat(z) << '\n'; } void write_vertex_color(const double, const double, const double) { } diff --git a/Stream_support/include/CGAL/IO/OFF/File_writer_OFF.h b/Stream_support/include/CGAL/IO/OFF/File_writer_OFF.h index 4bc11868384..3dd42654951 100644 --- a/Stream_support/include/CGAL/IO/OFF/File_writer_OFF.h +++ b/Stream_support/include/CGAL/IO/OFF/File_writer_OFF.h @@ -75,7 +75,7 @@ public: } else { - out() << '\n' << x << ' ' << y << ' ' << z; + out() << '\n' << oformat(x) << ' ' << oformat(y) << ' ' << oformat(z); } } @@ -89,7 +89,7 @@ public: } else { - out() << ' ' << ' ' << x << ' ' << y << ' ' << z; + out() << ' ' << ' ' << oformat(x) << ' ' << oformat(y) << ' ' << oformat(z); } } @@ -103,7 +103,7 @@ public: } else { - out() << ' ' << ' ' << r << ' ' << g << ' ' << b; + out() << ' ' << ' ' << oformat(r) << ' ' << oformat(g) << ' ' << oformat(b); } } @@ -116,7 +116,7 @@ public: } else { - out() << ' ' << ' ' << tx << ' ' << ty; + out() << ' ' << ' ' << oformat(tx) << ' ' << oformat(ty); } } diff --git a/Stream_support/include/CGAL/IO/OI/File_writer_inventor.h b/Stream_support/include/CGAL/IO/OI/File_writer_inventor.h index 7feef93c563..a3fe97d865c 100644 --- a/Stream_support/include/CGAL/IO/OI/File_writer_inventor.h +++ b/Stream_support/include/CGAL/IO/OI/File_writer_inventor.h @@ -57,7 +57,7 @@ public: void write_vertex( const double x, const double y, const double z) { - out() << " " << x << ' ' << y << ' ' << z << ',' <<'\n'; + out() << " " << oformat(x) << ' ' << oformat(y) << ' ' << oformat(z) << ',' <<'\n'; } void write_facet_header() const diff --git a/Stream_support/include/CGAL/IO/OI/Inventor_ostream.h b/Stream_support/include/CGAL/IO/OI/Inventor_ostream.h index 975ea1ed542..00d4d11f70b 100644 --- a/Stream_support/include/CGAL/IO/OI/Inventor_ostream.h +++ b/Stream_support/include/CGAL/IO/OI/Inventor_ostream.h @@ -106,21 +106,21 @@ operator<<(Inventor_ostream& os, os.os() << "\n Coordinate3 { \n" << Indent << "point [\n" << Indent << " " - << CGAL::to_double(t[0].x()) << " " - << CGAL::to_double(t[0].y()) << " " - << CGAL::to_double(t[0].z()) << " ,\n" + << oformat(CGAL::to_double(t[0].x())) << " " + << oformat(CGAL::to_double(t[0].y())) << " " + << oformat(CGAL::to_double(t[0].z())) << " ,\n" << Indent << " " - << CGAL::to_double(t[1].x()) << " " - << CGAL::to_double(t[1].y()) << " " - << CGAL::to_double(t[1].z()) << " ,\n" + << oformat(CGAL::to_double(t[1].x())) << " " + << oformat(CGAL::to_double(t[1].y())) << " " + << oformat(CGAL::to_double(t[1].z())) << " ,\n" << Indent << " " - << CGAL::to_double(t[2].x()) << " " - << CGAL::to_double(t[2].y()) << " " - << CGAL::to_double(t[2].z()) << " ,\n" + << oformat(CGAL::to_double(t[2].x())) << " " + << oformat(CGAL::to_double(t[2].y())) << " " + << oformat(CGAL::to_double(t[2].z())) << " ,\n" << Indent << " " - << CGAL::to_double(t[3].x()) << " " - << CGAL::to_double(t[3].y()) << " " - << CGAL::to_double(t[3].z()) << " ]" + << oformat(CGAL::to_double(t[3].x())) << " " + << oformat(CGAL::to_double(t[3].y())) << " " + << oformat(CGAL::to_double(t[3].z())) << " ]" << "\n } #Coordinate3" ; os.os() << "\n IndexedFaceSet {" << Indent << "coordIndex [ 0,1,2,-1, 1,3,2,-1,\n" diff --git a/Stream_support/include/CGAL/IO/VRML/File_writer_VRML_2.h b/Stream_support/include/CGAL/IO/VRML/File_writer_VRML_2.h index aa90d44ff77..eabebd32eb9 100644 --- a/Stream_support/include/CGAL/IO/VRML/File_writer_VRML_2.h +++ b/Stream_support/include/CGAL/IO/VRML/File_writer_VRML_2.h @@ -70,7 +70,7 @@ public: void write_vertex( const double x, const double y, const double z) { out() << " " - << x << ' ' << y << ' ' << z << ',' << '\n'; + << oformat(x) << ' ' << oformat(y) << ' ' << oformat(z) << ',' << '\n'; } void write_facet_header() const diff --git a/Stream_support/include/CGAL/IO/VRML/VRML_1_ostream.h b/Stream_support/include/CGAL/IO/VRML/VRML_1_ostream.h index a73a591ad5a..ec2b135a027 100644 --- a/Stream_support/include/CGAL/IO/VRML/VRML_1_ostream.h +++ b/Stream_support/include/CGAL/IO/VRML/VRML_1_ostream.h @@ -71,21 +71,21 @@ operator<<(VRML_1_ostream& os, os.os() << "\n Coordinate3 { \n" << Indent << "point [\n" << Indent << " " - << CGAL::to_double(t[0].x()) << " " - << CGAL::to_double(t[0].y()) << " " - << CGAL::to_double(t[0].z()) << " ,\n" + << oformat(CGAL::to_double(t[0].x())) << " " + << oformat(CGAL::to_double(t[0].y())) << " " + << oformat(CGAL::to_double(t[0].z())) << " ,\n" << Indent << " " - << CGAL::to_double(t[1].x()) << " " - << CGAL::to_double(t[1].y()) << " " - << CGAL::to_double(t[1].z()) << " ,\n" + << oformat(CGAL::to_double(t[1].x())) << " " + << oformat(CGAL::to_double(t[1].y())) << " " + << oformat(CGAL::to_double(t[1].z())) << " ,\n" << Indent << " " - << CGAL::to_double(t[2].x()) << " " - << CGAL::to_double(t[2].y()) << " " - << CGAL::to_double(t[2].z()) << " ,\n" + << oformat(CGAL::to_double(t[2].x())) << " " + << oformat(CGAL::to_double(t[2].y()) << " " + << oformat(CGAL::to_double(t[2].z()) << " ,\n" << Indent << " " - << CGAL::to_double(t[3].x()) << " " - << CGAL::to_double(t[3].y()) << " " - << CGAL::to_double(t[3].z()) << " ]" + << oformat(CGAL::to_double(t[3].x())) << " " + << oformat(CGAL::to_double(t[3].y())) << " " + << oformat(CGAL::to_double(t[3].z())) << " ]" << "\n } #Coordinate3" ; os.os() << "\n IndexedFaceSet {" diff --git a/Stream_support/include/CGAL/IO/VRML/VRML_2_ostream.h b/Stream_support/include/CGAL/IO/VRML/VRML_2_ostream.h index d5d3a36a37f..6b18d24e406 100644 --- a/Stream_support/include/CGAL/IO/VRML/VRML_2_ostream.h +++ b/Stream_support/include/CGAL/IO/VRML/VRML_2_ostream.h @@ -97,7 +97,7 @@ inline VRML_2_ostream& operator<<(VRML_2_ostream& os, inline VRML_2_ostream& operator<<(VRML_2_ostream& os, const double& d) { - os.os() << d; + os.os() << oformat(d); return os; } @@ -129,21 +129,21 @@ operator<<(VRML_2_ostream& os, " coord Coordinate {\n" " point [ \n" << Indent << " " - << CGAL::to_double(t[0].x()) << " " - << CGAL::to_double(t[0].y()) << " " - << CGAL::to_double(t[0].z()) << " ,\n" + << oformat(CGAL::to_double(t[0].x())) << " " + << oformat(CGAL::to_double(t[0].y())) << " " + << oformat(CGAL::to_double(t[0].z())) << " ,\n" << Indent << " " - << CGAL::to_double(t[1].x()) << " " - << CGAL::to_double(t[1].y()) << " " - << CGAL::to_double(t[1].z()) << " ,\n" + << oformat(CGAL::to_double(t[1].x())) << " " + << oformat(CGAL::to_double(t[1].y())) << " " + << oformat(CGAL::to_double(t[1].z())) << " ,\n" << Indent << " " - << CGAL::to_double(t[2].x()) << " " - << CGAL::to_double(t[2].y()) << " " - << CGAL::to_double(t[2].z()) << " ,\n" + << oformat(CGAL::to_double(t[2].x())) << " " + << oformat(CGAL::to_double(t[2].y())) << " " + << oformat(CGAL::to_double(t[2].z())) << " ,\n" << Indent << " " - << CGAL::to_double(t[3].x()) << " " - << CGAL::to_double(t[3].y()) << " " - << CGAL::to_double(t[3].z()) << + << oformat(CGAL::to_double(t[3].x())) << " " + << oformat(CGAL::to_double(t[3].y())) << " " + << oformat(CGAL::to_double(t[3].z())) << "\n ]\n" " }\n" " solid FALSE\n" diff --git a/Stream_support/include/CGAL/IO/VTK.h b/Stream_support/include/CGAL/IO/VTK.h index d37b96586eb..3f12067cda6 100644 --- a/Stream_support/include/CGAL/IO/VTK.h +++ b/Stream_support/include/CGAL/IO/VTK.h @@ -209,7 +209,7 @@ void write_soup_points_tag(std::ostream& os, { os << "\">\n"; for(const Point& p : points) - os << p.x() << " " << p.y() << " " << p.z() << " "; + os << oformat(p.x()) << " " << oformat(p.y()) << " " << oformat(p.z()) << " "; os << " \n"; } os << " \n";