summaryrefslogtreecommitdiff
path: root/src/cgaladv.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/cgaladv.cc')
-rw-r--r--src/cgaladv.cc31
1 files changed, 13 insertions, 18 deletions
diff --git a/src/cgaladv.cc b/src/cgaladv.cc
index 48f14c7..45a3bdd 100644
--- a/src/cgaladv.cc
+++ b/src/cgaladv.cc
@@ -34,7 +34,7 @@
#ifdef ENABLE_CGAL
extern CGAL_Nef_polyhedron3 minkowski3(CGAL_Nef_polyhedron3 a, CGAL_Nef_polyhedron3 b);
extern CGAL_Nef_polyhedron2 minkowski2(CGAL_Nef_polyhedron2 a, CGAL_Nef_polyhedron2 b);
-extern CGAL_Nef_polyhedron2 convexhull2(CGAL_Nef_polyhedron2 a, CGAL_Nef_polyhedron2 b);
+extern CGAL_Nef_polyhedron2 convexhull2(CGAL_Nef_polyhedron2 a);
#endif
enum cgaladv_type_e {
@@ -183,24 +183,19 @@ CGAL_Nef_polyhedron CgaladvNode::render_cgal_nef_polyhedron() const
if (type == HULL)
{
- bool first = true;
+
foreach(AbstractNode * v, children) {
- if (v->modinst->tag_background)
- continue;
- if (first) {
- N = v->render_cgal_nef_polyhedron();
- if (N.dim != 0)
- first = false;
- } else {
- CGAL_Nef_polyhedron tmp = v->render_cgal_nef_polyhedron();
- if (N.dim == 3 && tmp.dim == 3) {
-
- }
- if (N.dim == 2 && tmp.dim == 2) {
- N.p2 = convexhull2(N.p2, tmp.p2);
- }
- }
- v->progress_report();
+ if (v->modinst->tag_background)
+ continue;
+ N = v->render_cgal_nef_polyhedron();
+ if (N.dim == 3) {
+
+ }
+ if (N.dim == 2) {
+ N.p2 = convexhull2(N.p2);
+ }
+ v->progress_report();
+ break;
}
}
contact: Jan Huwald // Impressum