Refactoring. Use Model class for representing the plate in GUI

This commit is contained in:
Alessandro Ranellucci 2013-12-12 20:19:33 +01:00
parent f55e057504
commit 0e8a0ef1ca
19 changed files with 610 additions and 620 deletions

View file

@ -1,4 +1,5 @@
#include "ExPolygonCollection.hpp"
#include "Geometry.hpp"
namespace Slic3r {
@ -57,4 +58,13 @@ ExPolygonCollection::simplify(double tolerance)
this->expolygons = expp;
}
void
ExPolygonCollection::convex_hull(Polygon* hull) const
{
Points pp;
for (ExPolygons::const_iterator it = this->expolygons.begin(); it != this->expolygons.end(); ++it)
pp.insert(pp.end(), it->contour.points.begin(), it->contour.points.end());
Slic3r::Geometry::convex_hull(pp, hull);
}
}