mirror of
https://github.com/FULU-Foundation/OrcaSlicer-bambulab.git
synced 2026-05-15 01:22:37 -07:00
Use Clipper for line clipping
This commit is contained in:
@@ -41,4 +41,15 @@ PolylineCollection::chained_path_from(const Point* start_near, bool no_reverse)
|
||||
return retval;
|
||||
}
|
||||
|
||||
Point*
|
||||
PolylineCollection::leftmost_point() const
|
||||
{
|
||||
const Point* p = NULL;
|
||||
for (Polylines::const_iterator it = this->polylines.begin(); it != this->polylines.end(); ++it) {
|
||||
if (p == NULL || it->points.front().x < p->x)
|
||||
p = &(it->points.front());
|
||||
}
|
||||
return new Point (*p);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user