mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-18 11:02:08 +00:00
Small memory optimization for some infills (#12063)
This commit is contained in:
@@ -277,7 +277,7 @@ void Fill3DHoneycomb::_fill_surface_single(
|
|||||||
multiline_fill(polylines, params, spacing);
|
multiline_fill(polylines, params, spacing);
|
||||||
|
|
||||||
// clip pattern to boundaries, chain the clipped polylines
|
// clip pattern to boundaries, chain the clipped polylines
|
||||||
polylines = intersection_pl(polylines, to_polygons(expolygon));
|
polylines = intersection_pl(std::move(polylines), to_polygons(expolygon));
|
||||||
|
|
||||||
if (! polylines.empty()) {
|
if (! polylines.empty()) {
|
||||||
// Remove very small bits, but be careful to not remove infill lines connecting thin walls!
|
// Remove very small bits, but be careful to not remove infill lines connecting thin walls!
|
||||||
|
|||||||
@@ -208,7 +208,7 @@ void FillCrossHatch ::_fill_surface_single(
|
|||||||
// Apply multiline offset if needed
|
// Apply multiline offset if needed
|
||||||
multiline_fill(polylines, params, spacing);
|
multiline_fill(polylines, params, spacing);
|
||||||
|
|
||||||
polylines = intersection_pl(polylines, to_polygons(expolygon));
|
polylines = intersection_pl(std::move(polylines), to_polygons(expolygon));
|
||||||
|
|
||||||
// --- remove small remains from gyroid infill
|
// --- remove small remains from gyroid infill
|
||||||
if (!polylines.empty()) {
|
if (!polylines.empty()) {
|
||||||
|
|||||||
@@ -187,7 +187,7 @@ void FillGyroid::_fill_surface_single(
|
|||||||
// Apply multiline offset if needed
|
// Apply multiline offset if needed
|
||||||
multiline_fill(polylines, params, spacing);
|
multiline_fill(polylines, params, spacing);
|
||||||
|
|
||||||
polylines = intersection_pl(polylines, expolygon);
|
polylines = intersection_pl(std::move(polylines), expolygon);
|
||||||
|
|
||||||
if (! polylines.empty()) {
|
if (! polylines.empty()) {
|
||||||
// Remove very small bits, but be careful to not remove infill lines connecting thin walls!
|
// Remove very small bits, but be careful to not remove infill lines connecting thin walls!
|
||||||
|
|||||||
@@ -58,7 +58,7 @@ void FillLine::_fill_surface_single(
|
|||||||
pts.push_back(it->a);
|
pts.push_back(it->a);
|
||||||
pts.push_back(it->b);
|
pts.push_back(it->b);
|
||||||
}
|
}
|
||||||
Polylines polylines = intersection_pl(polylines_src, offset(expolygon, scale_(0.02)));
|
Polylines polylines = intersection_pl(std::move(polylines_src), offset(expolygon, scale_(0.02)));
|
||||||
|
|
||||||
// FIXME Vojtech: This is only performed for horizontal lines, not for the vertical lines!
|
// FIXME Vojtech: This is only performed for horizontal lines, not for the vertical lines!
|
||||||
const float INFILL_OVERLAP_OVER_SPACING = 0.3f;
|
const float INFILL_OVERLAP_OVER_SPACING = 0.3f;
|
||||||
|
|||||||
@@ -133,7 +133,7 @@ void FillTpmsD::_fill_surface_single(
|
|||||||
// Apply multiline offset if needed
|
// Apply multiline offset if needed
|
||||||
multiline_fill(polylines, params, spacing);
|
multiline_fill(polylines, params, spacing);
|
||||||
|
|
||||||
polylines = intersection_pl(polylines, expolygon);
|
polylines = intersection_pl(std::move(polylines), expolygon);
|
||||||
|
|
||||||
if (! polylines.empty()) {
|
if (! polylines.empty()) {
|
||||||
// Remove very small bits, but be careful to not remove infill lines connecting thin walls!
|
// Remove very small bits, but be careful to not remove infill lines connecting thin walls!
|
||||||
|
|||||||
Reference in New Issue
Block a user