summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/CGALEvaluator.cc8
-rw-r--r--src/csgterm.cc7
-rw-r--r--src/csgterm.h2
3 files changed, 11 insertions, 6 deletions
diff --git a/src/CGALEvaluator.cc b/src/CGALEvaluator.cc
index 1b307be..ee04e05 100644
--- a/src/CGALEvaluator.cc
+++ b/src/CGALEvaluator.cc
@@ -34,8 +34,8 @@
#include <assert.h>
#include <boost/foreach.hpp>
-#include <boost/unordered_map.hpp>
#include <boost/bind.hpp>
+#include <map>
CGAL_Nef_polyhedron CGALEvaluator::evaluateCGALMesh(const AbstractNode &node)
{
@@ -445,9 +445,9 @@ CGAL_Nef_polyhedron CGALEvaluator::evaluateCGALMesh(const PolySet &ps)
struct PolyReducer
{
Grid2d<int> grid;
- boost::unordered_map<std::pair<int,int>, std::pair<int,int> > edge_to_poly;
- boost::unordered_map<int, CGAL_Nef_polyhedron2::Point> points;
- typedef boost::unordered_map<int, std::vector<int> > PolygonMap;
+ std::map<std::pair<int,int>, std::pair<int,int> > edge_to_poly;
+ std::map<int, CGAL_Nef_polyhedron2::Point> points;
+ typedef std::map<int, std::vector<int> > PolygonMap;
PolygonMap polygons;
int poly_n;
diff --git a/src/csgterm.cc b/src/csgterm.cc
index 4e6912b..8b0c8a4 100644
--- a/src/csgterm.cc
+++ b/src/csgterm.cc
@@ -178,7 +178,7 @@ void CSGChain::import(shared_ptr<CSGTerm> term, CSGTerm::type_e type)
}
}
-std::string CSGChain::dump()
+std::string CSGChain::dump(bool full=false)
{
std::stringstream dump;
@@ -193,6 +193,11 @@ std::string CSGChain::dump()
else if (types[i] == CSGTerm::TYPE_INTERSECTION)
dump << " *";
dump << labels[i];
+ if (full) {
+ dump << " polyset: \n" << polysets[i]->dump() << "\n";
+ dump << " matrix: \n" << matrices[i].matrix() << "\n";
+ dump << " color: \n" << colors[i] << "\n";
+ }
}
dump << "\n";
return dump.str();
diff --git a/src/csgterm.h b/src/csgterm.h
index 4278d85..95cfafd 100644
--- a/src/csgterm.h
+++ b/src/csgterm.h
@@ -59,7 +59,7 @@ public:
void add(const shared_ptr<PolySet> &polyset, const Transform3d &m, const Color4f &color, CSGTerm::type_e type, std::string label);
void import(shared_ptr<CSGTerm> term, CSGTerm::type_e type = CSGTerm::TYPE_UNION);
- std::string dump();
+ std::string dump(bool full);
BoundingBox getBoundingBox() const;
};
contact: Jan Huwald // Impressum