ENH: tree support uses accurate lslices

For tree support, use lslices as tree support island when generating brim,
as this is faster and more accurate.
For normal support, still use "support_fills.polygons_covered_by_spacing()" as support island when generating brim;

Jira: studio 4332

Change-Id: Ibfadd3a166606f824e5780b57112fff221470aaf
(cherry picked from commit 64960b19818c7029eaaaf3d8a89804aeaa26f11d)
This commit is contained in:
Arthur
2023-09-14 17:20:58 +08:00
committed by Lane.Wei
parent bf23f6f023
commit 181b05c236
2 changed files with 23 additions and 12 deletions

View File

@@ -939,12 +939,19 @@ static ExPolygons outer_inner_brim_area(const Print& print,
support_material_extruder = printExtruders.front() + 1;
}
if (support_material_extruder == extruderNo && brimToWrite.at(object->id()).sup) {
if (!object->support_layers().empty()) {
if (!object->support_layers().empty() && object->support_layers().front()->support_type == stInnerNormal) {
for (const Polygon& support_contour : object->support_layers().front()->support_fills.polygons_covered_by_spacing()) {
no_brim_area_support.emplace_back(support_contour);
}
}
if (!object->support_layers().empty() && object->support_layers().front()->support_type == stInnerTree) {
for (const ExPolygon& ex_poly : object->support_layers().front()->lslices) {
no_brim_area_support.emplace_back(ex_poly.contour);
}
}
brimToWrite.at(object->id()).sup = false;
for (const PrintInstance& instance : object->instances()) {
if (!brim_area_support.empty())