summaryrefslogtreecommitdiff
path: root/src/cgaladv.cc
diff options
context:
space:
mode:
authorGiles Bathgate <gilesbathgate@gmail.com>2011-04-09 09:27:50 (GMT)
committerGiles Bathgate <gilesbathgate@gmail.com>2011-04-09 09:27:50 (GMT)
commit9cc441025cda17a494259b1ae2cafc5b48c14a12 (patch)
treea7cc8722fb6e8841edee230615f64f84ff048743 /src/cgaladv.cc
parent18a11b5c3c567bb9796ed40434c3fb4f8a5ec45c (diff)
Basic implementation of convex hull for 2d polyhedra.
The code was provided to me by Len Trigg via email.
Diffstat (limited to 'src/cgaladv.cc')
-rw-r--r--src/cgaladv.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cgaladv.cc b/src/cgaladv.cc
index 3e53569..48f14c7 100644
--- a/src/cgaladv.cc
+++ b/src/cgaladv.cc
@@ -30,11 +30,11 @@
#include "builtin.h"
#include "printutils.h"
#include "cgal.h"
-#include <CGAL/ch_graham_andrew.h>
#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);
#endif
enum cgaladv_type_e {
@@ -197,7 +197,7 @@ CGAL_Nef_polyhedron CgaladvNode::render_cgal_nef_polyhedron() const
}
if (N.dim == 2 && tmp.dim == 2) {
-
+ N.p2 = convexhull2(N.p2, tmp.p2);
}
}
v->progress_report();
contact: Jan Huwald // Impressum