Some reduction of unnecessary conversions when calling ClipperUtils.

This commit is contained in:
Vojtech Bubnik 2021-09-13 15:13:05 +02:00
parent 60b5e0d0d5
commit cab71073a1
11 changed files with 29 additions and 24 deletions

View file

@ -10,14 +10,7 @@
namespace Slic3r {
Polyline::operator Polylines() const
{
Polylines polylines;
polylines.push_back(*this);
return polylines;
}
Polyline::operator Line() const
Line Polyline::line() const
{
if (this->points.size() > 2)
throw Slic3r::InvalidArgument("Can't convert polyline with more than two points to a line");