mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-12 02:29:04 +08:00
Fixed access violation when using multimaterial priming with multi-extruder printer (#11174, #11197, SPE-1849)
This commit is contained in:
parent
a89860d7d3
commit
1f510bcc00
@ -239,11 +239,12 @@ namespace Slic3r {
|
|||||||
|
|
||||||
const bool needs_toolchange = gcodegen.writer().need_toolchange(new_extruder_id);
|
const bool needs_toolchange = gcodegen.writer().need_toolchange(new_extruder_id);
|
||||||
const bool will_go_down = ! is_approx(z, current_z);
|
const bool will_go_down = ! is_approx(z, current_z);
|
||||||
const bool is_ramming = (gcodegen.config().single_extruder_multi_material && ! tcr.priming)
|
const bool is_ramming = (gcodegen.config().single_extruder_multi_material)
|
||||||
|| (! gcodegen.config().single_extruder_multi_material && gcodegen.config().filament_multitool_ramming.get_at(tcr.initial_tool));
|
|| (! gcodegen.config().single_extruder_multi_material && gcodegen.config().filament_multitool_ramming.get_at(tcr.initial_tool));
|
||||||
const bool should_travel_to_tower = tcr.force_travel // wipe tower says so
|
const bool should_travel_to_tower = ! tcr.priming
|
||||||
|| ! needs_toolchange // this is just finishing the tower with no toolchange
|
&& (tcr.force_travel // wipe tower says so
|
||||||
|| is_ramming;
|
|| ! needs_toolchange // this is just finishing the tower with no toolchange
|
||||||
|
|| is_ramming);
|
||||||
if (should_travel_to_tower) {
|
if (should_travel_to_tower) {
|
||||||
// FIXME: It would be better if the wipe tower set the force_travel flag for all toolchanges,
|
// FIXME: It would be better if the wipe tower set the force_travel flag for all toolchanges,
|
||||||
// then we could simplify the condition and make it more readable.
|
// then we could simplify the condition and make it more readable.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user