Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/supermerill/SuperSlicer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'xs/src/libslic3r/ExPolygonCollection.cpp')
-rw-r--r--xs/src/libslic3r/ExPolygonCollection.cpp18
1 files changed, 18 insertions, 0 deletions
diff --git a/xs/src/libslic3r/ExPolygonCollection.cpp b/xs/src/libslic3r/ExPolygonCollection.cpp
index 3de86e7c6..181288c95 100644
--- a/xs/src/libslic3r/ExPolygonCollection.cpp
+++ b/xs/src/libslic3r/ExPolygonCollection.cpp
@@ -64,6 +64,24 @@ ExPolygonCollection::contains_point(const Point &point) const
return false;
}
+bool
+ExPolygonCollection::contains_line(const Line &line) const
+{
+ for (ExPolygons::const_iterator it = this->expolygons.begin(); it != this->expolygons.end(); ++it) {
+ if (it->contains_line(line)) return true;
+ }
+ return false;
+}
+
+bool
+ExPolygonCollection::contains_polyline(const Polyline &polyline) const
+{
+ for (ExPolygons::const_iterator it = this->expolygons.begin(); it != this->expolygons.end(); ++it) {
+ if (it->contains_polyline(polyline)) return true;
+ }
+ return false;
+}
+
void
ExPolygonCollection::simplify(double tolerance)
{