Overloaded append() to add single ExPolygons (avoids having to create a vector for no purpose)

This commit is contained in:
Joseph Lenox 2018-05-01 22:31:38 -05:00
parent 5f405b60e9
commit 1074b04326
2 changed files with 6 additions and 0 deletions

View File

@ -135,5 +135,10 @@ ExPolygonCollection::append(const ExPolygons &expp)
{
this->expolygons.insert(this->expolygons.end(), expp.begin(), expp.end());
}
void
ExPolygonCollection::append(const ExPolygon &expp)
{
this->expolygons.push_back(expp);
}
}

View File

@ -33,6 +33,7 @@ class ExPolygonCollection
Polygons contours() const;
Polygons holes() const;
void append(const ExPolygons &expolygons);
void append(const ExPolygon &expolygons);
};
inline ExPolygonCollection&