Revert "Revert "Merge branch 'master' of https://github.com/QIDITECH/QIDISlicer""

This reverts commit 5bba8ccb1b.
This commit is contained in:
sunsets
2024-01-17 14:38:24 +08:00
parent 5bba8ccb1b
commit bf9dbfae79
12 changed files with 594 additions and 13 deletions

View File

@@ -79,7 +79,8 @@ std::string Wipe::wipe(GCodeGenerator &gcodegen, bool toolchange)
static constexpr const std::string_view wipe_retract_comment = "wipe and retract"sv;
// Remaining quantized retraction length.
if (double retract_length = extruder.retract_to_go(toolchange ? extruder.retract_length_toolchange() : extruder.retract_length());
//w15
if (double retract_length = extruder.retract_to_go(toolchange ? extruder.retract_length_toolchange() * 0.95 : extruder.retract_length()) * 0.95;
retract_length > 0 && this->has_path()) {
// Delayed emitting of a wipe start tag.
bool wiped = false;
@@ -197,11 +198,11 @@ std::string Wipe::wipe(GCodeGenerator &gcodegen, bool toolchange)
prev = p;
auto end = this->path().end();
for (; it != end && ! done; ++ it) {
//w15
if (wipe_dist >= wipe_dist_max)
break;
p = gcodegen.point_to_gcode(it->point + m_offset);
if (p != prev) {
//w15
if (wipe_dist >= wipe_dist_max)
break;
start_wipe();
if (it->linear() ?
wipe_linear(prev, p) :