mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-08-31 13:57:07 +00:00
Code optimisation
This commit is contained in:
@@ -306,8 +306,9 @@ public:
|
|||||||
const ExtendedPoint &curr = extended_points[i];
|
const ExtendedPoint &curr = extended_points[i];
|
||||||
const ExtendedPoint &next = extended_points[i + 1 < extended_points.size() ? i + 1 : i];
|
const ExtendedPoint &next = extended_points[i + 1 < extended_points.size() ? i + 1 : i];
|
||||||
|
|
||||||
// The following code artifically increases the distance to provide slowdown for extrusions that are over curled lines
|
|
||||||
float artificial_distance_to_curled_lines = 0.0;
|
float artificial_distance_to_curled_lines = 0.0;
|
||||||
|
if(slowdown_for_curled_edges) {
|
||||||
|
// The following code artifically increases the distance to provide slowdown for extrusions that are over curled lines
|
||||||
const double dist_limit = 10.0 * path.width;
|
const double dist_limit = 10.0 * path.width;
|
||||||
{
|
{
|
||||||
Vec2d middle = 0.5 * (curr.position + next.position);
|
Vec2d middle = 0.5 * (curr.position + next.position);
|
||||||
@@ -353,6 +354,7 @@ public:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
auto calculate_speed = [&speed_sections, &original_speed](float distance) {
|
auto calculate_speed = [&speed_sections, &original_speed](float distance) {
|
||||||
float final_speed;
|
float final_speed;
|
||||||
|
|||||||
Reference in New Issue
Block a user