summaryrefslogtreecommitdiff
path: root/src/CGAL_Nef_polyhedron_DxfData.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/CGAL_Nef_polyhedron_DxfData.cc')
-rw-r--r--src/CGAL_Nef_polyhedron_DxfData.cc25
1 files changed, 25 insertions, 0 deletions
diff --git a/src/CGAL_Nef_polyhedron_DxfData.cc b/src/CGAL_Nef_polyhedron_DxfData.cc
index fe58636..d5f774d 100644
--- a/src/CGAL_Nef_polyhedron_DxfData.cc
+++ b/src/CGAL_Nef_polyhedron_DxfData.cc
@@ -77,4 +77,29 @@ DxfData *CGAL_Nef_polyhedron::convertToDxfData() const
return dxfdata;
}
+// moved here to reduce compile size/time of CGAL_Nef_polyhedron.cc
+std::string CGAL_Nef_polyhedron::dump_p2() const
+{
+ std::stringstream out;
+ CGAL_Nef_polyhedron2::Explorer explorer = this->p2->explorer();
+ CGAL_Nef_polyhedron2::Explorer::Vertex_const_iterator i;
+ out << "CGAL_Nef_polyhedron::p2 vertices";
+ for (i = explorer.vertices_begin(); i != explorer.vertices_end(); ++i) {
+ if ( explorer.is_standard( i ) ) {
+ CGAL_Nef_polyhedron2::Explorer::Point point = explorer.point( i );
+ out << "\n Standard vertex x y: "
+ << CGAL::to_double(point.x()) << " "
+ << CGAL::to_double(point.y());
+ } else {
+ CGAL_Nef_polyhedron2::Explorer::Ray ray = explorer.ray( i );
+ CGAL_Nef_polyhedron2::Explorer::Point point = ray.point( 0 );
+ out << "\n Ray x y dx dy: "
+ << CGAL::to_double(point.x()) << " " << CGAL::to_double(point.y())
+ << CGAL::to_double(ray.direction().dx()) << " " << CGAL::to_double(ray.direction().dy()) << "\n";
+ }
+ }
+ out << "\nCGAL_Nef_polyhedron::p2 vertices end";
+ return out.str();
+}
+
#endif // ENABLE_CGAL
contact: Jan Huwald // Impressum