diff --git a/src/csg/cgal_helper_polygon.cpp b/src/csg/cgal_helper_polygon.cpp index 2b95b9d9b977d3206bc4e0c26f48d04aca25a0fc..af0c422695e8244cc339b7576fe219900b1b1128 100644 --- a/src/csg/cgal_helper_polygon.cpp +++ b/src/csg/cgal_helper_polygon.cpp @@ -1,11 +1,7 @@ #include "csg_cgal_helper.hpp" -#include -#include - namespace { -typedef CGAL::Polygon_2 Polygon; -typedef CGAL::Point_2 Point; +typedef CGAL::Point_2 Point; } // namespace namespace cgal_helper { @@ -32,8 +28,7 @@ Polygon create_polygon(const std::vector> &points, bool inside(const Polygon &polygon, double xx, double yy) { - return CGAL::bounded_side_2(polygon.begin(), polygon.end(), Point(xx, yy), - IK()) == CGAL::ON_BOUNDED_SIDE; + return polygon.is_simple(); } } // namespace cgal_helper diff --git a/src/csg_cgal_helper.hpp b/src/csg_cgal_helper.hpp index 0326d23b8b50363efaac97ab3733d79595c8072e..f4daf152b3f12b48db9cd66fabe2bca8edbbb621 100644 --- a/src/csg_cgal_helper.hpp +++ b/src/csg_cgal_helper.hpp @@ -11,7 +11,7 @@ namespace cgal_helper { typedef CGAL::Simple_cartesian CK; typedef CGAL::Polyhedron_3 Polyhedron; typedef CGAL::Exact_predicates_inexact_constructions_kernel IK; -typedef CGAL::Polygon_2 Polygon; +typedef CGAL::Polygon_2 Polygon; Polyhedron create_polyhedron(const std::vector> &points,