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:
authorbubnikv <bubnikv@gmail.com>2016-09-30 16:23:18 +0300
committerbubnikv <bubnikv@gmail.com>2016-09-30 16:23:18 +0300
commit3a81e6bee420196698e3f1409a8a7318dd35965b (patch)
tree70574b85f26c77406691b1ed188049fd201911ee /xs/src/libslic3r/ExPolygon.hpp
parentb5e24d3527db0bc9153365b0709787e145aeb982 (diff)
Bugfix of bottom bridges. If close regions shall be closed by bridges,
these regions are grown to anchor the bridge lines to the bottom surface. The grown regions may overlap. In that case the regions are now merged before the bridging direction is calculated for the merged region.
Diffstat (limited to 'xs/src/libslic3r/ExPolygon.hpp')
-rw-r--r--xs/src/libslic3r/ExPolygon.hpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/xs/src/libslic3r/ExPolygon.hpp b/xs/src/libslic3r/ExPolygon.hpp
index ada37cecc..f283822da 100644
--- a/xs/src/libslic3r/ExPolygon.hpp
+++ b/xs/src/libslic3r/ExPolygon.hpp
@@ -18,17 +18,28 @@ class ExPolygon
Polygons holes;
operator Points() const;
operator Polygons() const;
+ operator Polylines() const;
+ void clear() { contour.points.clear(); holes.clear(); }
void scale(double factor);
void translate(double x, double y);
void rotate(double angle);
void rotate(double angle, const Point &center);
double area() const;
bool is_valid() const;
+
+ // Contains the line / polyline / polylines etc COMPLETELY.
bool contains(const Line &line) const;
bool contains(const Polyline &polyline) const;
+ bool contains(const Polylines &polylines) const;
bool contains(const Point &point) const;
bool contains_b(const Point &point) const;
bool has_boundary_point(const Point &point) const;
+
+ // Does this expolygon overlap another expolygon?
+ // Either the ExPolygons intersect, or one is fully inside the other,
+ // and it is not inside a hole of the other expolygon.
+ bool overlap(const ExPolygon &other) const;
+
void simplify_p(double tolerance, Polygons* polygons) const;
Polygons simplify_p(double tolerance) const;
ExPolygons simplify(double tolerance) const;