2013-07-14 00:38:01 +02:00
|
|
|
#ifndef slic3r_ExPolygonCollection_hpp_
|
|
|
|
|
#define slic3r_ExPolygonCollection_hpp_
|
|
|
|
|
|
2013-07-16 21:04:14 +02:00
|
|
|
#include <myinit.h>
|
2013-07-14 00:38:01 +02:00
|
|
|
#include "ExPolygon.hpp"
|
|
|
|
|
|
|
|
|
|
namespace Slic3r {
|
|
|
|
|
|
2014-05-13 20:06:01 +02:00
|
|
|
class ExPolygonCollection;
|
|
|
|
|
typedef std::vector<ExPolygonCollection> ExPolygonCollections;
|
|
|
|
|
|
2013-07-14 00:38:01 +02:00
|
|
|
class ExPolygonCollection
|
|
|
|
|
{
|
|
|
|
|
public:
|
2013-08-08 02:10:34 +02:00
|
|
|
ExPolygons expolygons;
|
2014-05-13 20:06:01 +02:00
|
|
|
|
|
|
|
|
ExPolygonCollection() {};
|
|
|
|
|
ExPolygonCollection(const ExPolygons &expolygons) : expolygons(expolygons) {};
|
|
|
|
|
operator Points() const;
|
2013-11-21 17:53:50 +01:00
|
|
|
operator Polygons() const;
|
2014-05-13 20:06:01 +02:00
|
|
|
operator ExPolygons&();
|
2013-07-14 00:38:01 +02:00
|
|
|
void scale(double factor);
|
|
|
|
|
void translate(double x, double y);
|
2014-04-24 13:43:24 +02:00
|
|
|
void rotate(double angle, const Point ¢er);
|
2014-04-24 16:40:10 +02:00
|
|
|
bool contains_point(const Point &point) const;
|
2013-11-21 20:25:24 +01:00
|
|
|
void simplify(double tolerance);
|
2013-12-12 20:19:33 +01:00
|
|
|
void convex_hull(Polygon* hull) const;
|
2013-07-14 00:38:01 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
#endif
|