mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-25 07:34:03 -06:00
FIX: auto-arrange fails for multi-color objects
The cost for switching extruders was too big. Change-Id: Ic9de6b6aabb7e69db79a0201f0dbb9d039097df9
This commit is contained in:
parent
06f878f13b
commit
d95e85851c
4 changed files with 46 additions and 19 deletions
|
@ -436,10 +436,12 @@ protected:
|
|||
if (!params.allow_multi_materials_on_same_plate)
|
||||
score += LARGE_COST_TO_REJECT * (item.extrude_id != p.extrude_id);
|
||||
}
|
||||
|
||||
// for layered printing, we want extruder change as few as possible
|
||||
// this has very weak effect, CAN NOT use a large weight
|
||||
if (!params.is_seq_print) {
|
||||
extruder_ids.insert(item.extrude_id);
|
||||
score += 0.2 * LARGE_COST_TO_REJECT * std::max(0, ((int)extruder_ids.size() - 1));
|
||||
score += 1 * std::max(0, ((int)extruder_ids.size() - 1));
|
||||
}
|
||||
|
||||
return std::make_tuple(score, fullbb);
|
||||
|
|
|
@ -138,11 +138,9 @@ ArrangePolygon get_instance_arrange_poly(ModelInstance* instance, const Slic3r::
|
|||
ap.print_temp = config.opt_int("nozzle_temperature", ap.extrude_ids.back() - 1);
|
||||
if (config.has("nozzle_temperature_initial_layer")) //get the nozzle_temperature_initial_layer
|
||||
ap.first_print_temp = config.opt_int("nozzle_temperature_initial_layer", ap.extrude_ids.back() - 1);
|
||||
// BBS: since first_bed_temp packs all 3 temperatures, vitrify_temp should follow same routine
|
||||
|
||||
if (config.has("temperature_vitrification")) {
|
||||
int tmp = config.opt_int("temperature_vitrification", ap.extrude_ids.back() - 1);
|
||||
for (int i = 0; i < BedType::btCount; i++)
|
||||
ap.vitrify_temp += tmp * pow(100, BedType::btCount - i - 1);
|
||||
ap.vitrify_temp = config.opt_int("temperature_vitrification", ap.extrude_ids.back() - 1);
|
||||
}
|
||||
|
||||
// get brim width
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue