From 3633112148e5da0c192b4ad0f099af171beaac3c Mon Sep 17 00:00:00 2001 From: enricoturri1966 Date: Wed, 16 Feb 2022 10:17:57 +0100 Subject: [PATCH 1/3] Follow-up of 7150e0adda2673797b624e314782a81ca8279bb7 - Fix in clamping max bounding box to avoid z-fighting in gcode preview --- src/slic3r/GUI/GLCanvas3D.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/slic3r/GUI/GLCanvas3D.cpp b/src/slic3r/GUI/GLCanvas3D.cpp index edd62ce0ab..1df16e6b75 100644 --- a/src/slic3r/GUI/GLCanvas3D.cpp +++ b/src/slic3r/GUI/GLCanvas3D.cpp @@ -5025,9 +5025,9 @@ BoundingBoxf3 GLCanvas3D::_max_bounding_box(bool include_gizmos, bool include_be // clamp max bb size with respect to bed bb size if (!m_picking_enabled) { - static const double max_scale_factor = 1.5; + static const double max_scale_factor = 2.0; const Vec3d bb_size = bb.size(); - const Vec3d bed_bb_size = bed_bb.size(); + const Vec3d bed_bb_size = m_bed.build_volume().bounding_volume().size(); if (bb_size.x() > max_scale_factor * bed_bb_size.x() || bb_size.y() > max_scale_factor * bed_bb_size.y() || bb_size.z() > max_scale_factor * bed_bb_size.z()) { @@ -5037,6 +5037,9 @@ BoundingBoxf3 GLCanvas3D::_max_bounding_box(bool include_gizmos, bool include_be } } +//@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ + std::cout << to_string(bb.size()) << "\n"; +//@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ return bb; } From 6c397e291cc199d4da8d9ffc23dff1384584049d Mon Sep 17 00:00:00 2001 From: enricoturri1966 Date: Wed, 16 Feb 2022 10:18:47 +0100 Subject: [PATCH 2/3] Removed debug code committed by mistake --- src/slic3r/GUI/GLCanvas3D.cpp | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/slic3r/GUI/GLCanvas3D.cpp b/src/slic3r/GUI/GLCanvas3D.cpp index 1df16e6b75..865190e465 100644 --- a/src/slic3r/GUI/GLCanvas3D.cpp +++ b/src/slic3r/GUI/GLCanvas3D.cpp @@ -5037,9 +5037,6 @@ BoundingBoxf3 GLCanvas3D::_max_bounding_box(bool include_gizmos, bool include_be } } -//@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ - std::cout << to_string(bb.size()) << "\n"; -//@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ return bb; } From b407540f268e949d2efc8769000aa1b6ea763778 Mon Sep 17 00:00:00 2001 From: tamasmeszaros Date: Thu, 17 Feb 2022 13:43:11 +0100 Subject: [PATCH 3/3] Downgrade log message from sla support tree creation --- src/libslic3r/SLA/SupportTreeBuildsteps.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libslic3r/SLA/SupportTreeBuildsteps.cpp b/src/libslic3r/SLA/SupportTreeBuildsteps.cpp index 6134e1f5ab..aa69fdc777 100644 --- a/src/libslic3r/SLA/SupportTreeBuildsteps.cpp +++ b/src/libslic3r/SLA/SupportTreeBuildsteps.cpp @@ -982,7 +982,7 @@ bool SupportTreeBuildsteps::connect_to_model_body(Head &head) double w = dist - 2 * head.r_pin_mm - head.r_back_mm; if (w < 0.) { - BOOST_LOG_TRIVIAL(error) << "Pinhead width is negative!"; + BOOST_LOG_TRIVIAL(warning) << "Pinhead width is negative!"; w = 0.; }