mirror of
https://github.com/FULU-Foundation/OrcaSlicer-bambulab.git
synced 2026-05-16 08:12:39 -07:00
New coverage detection for bridges. Includes implementation of ExPolygon::get_trapezoids()
This commit is contained in:
@@ -34,12 +34,12 @@ Point::translate(double x, double y)
|
||||
}
|
||||
|
||||
void
|
||||
Point::rotate(double angle, Point* center)
|
||||
Point::rotate(double angle, const Point ¢er)
|
||||
{
|
||||
double cur_x = (double)this->x;
|
||||
double cur_y = (double)this->y;
|
||||
this->x = (coord_t)round( (double)center->x + cos(angle) * (cur_x - (double)center->x) - sin(angle) * (cur_y - (double)center->y) );
|
||||
this->y = (coord_t)round( (double)center->y + cos(angle) * (cur_y - (double)center->y) + sin(angle) * (cur_x - (double)center->x) );
|
||||
this->x = (coord_t)round( (double)center.x + cos(angle) * (cur_x - (double)center.x) - sin(angle) * (cur_y - (double)center.y) );
|
||||
this->y = (coord_t)round( (double)center.y + cos(angle) * (cur_y - (double)center.y) + sin(angle) * (cur_x - (double)center.x) );
|
||||
}
|
||||
|
||||
bool
|
||||
|
||||
Reference in New Issue
Block a user