mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-21 05:37:52 -06:00
[Bug fix] Fixes retraction on layer change being performed when retract travel threshold is set to 0 (#3614)
Fixes retraction on layer change being performed when retract travel threshold is set to 0
This commit is contained in:
parent
fff85195b8
commit
698aba3570
1 changed files with 3 additions and 1 deletions
|
@ -126,7 +126,9 @@ std::string SpiralVase::process_layer(const std::string &gcode, bool last_layer)
|
||||||
m_reader.parse_buffer(gcode, [&new_gcode, &z, total_layer_length, layer_height, transition_in, &len, ¤t_layer, &previous_layer, &transition_gcode, transition_out, smooth_spiral, &max_xy_dist_for_smoothing, &last_point]
|
m_reader.parse_buffer(gcode, [&new_gcode, &z, total_layer_length, layer_height, transition_in, &len, ¤t_layer, &previous_layer, &transition_gcode, transition_out, smooth_spiral, &max_xy_dist_for_smoothing, &last_point]
|
||||||
(GCodeReader &reader, GCodeReader::GCodeLine line) {
|
(GCodeReader &reader, GCodeReader::GCodeLine line) {
|
||||||
if (line.cmd_is("G1")) {
|
if (line.cmd_is("G1")) {
|
||||||
if (line.has_z()) {
|
// Orca: Filter out retractions at layer change
|
||||||
|
if (line.retracting(reader) || (line.extruding(reader) && line.dist_XY(reader) < EPSILON)) return;
|
||||||
|
if (line.has_z() && !line.retracting(reader)) {
|
||||||
// If this is the initial Z move of the layer, replace it with a
|
// If this is the initial Z move of the layer, replace it with a
|
||||||
// (redundant) move to the last Z of previous layer.
|
// (redundant) move to the last Z of previous layer.
|
||||||
line.set(reader, Z, z);
|
line.set(reader, Z, z);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue