diff --git a/src/libslic3r/BoundingBox.hpp b/src/libslic3r/BoundingBox.hpp index 9a4c68a147..f8da75ac6d 100644 --- a/src/libslic3r/BoundingBox.hpp +++ b/src/libslic3r/BoundingBox.hpp @@ -68,7 +68,9 @@ private: template> static void construct(BoundingBoxType &out, It from, It to) { - if (from != to) { + if (from == to) { + out.defined = false; + } else { auto it = from; out.min = it->template cast(); out.max = out.min; diff --git a/src/libslic3r/PrintObject.cpp b/src/libslic3r/PrintObject.cpp index 5340599722..cdd5874810 100644 --- a/src/libslic3r/PrintObject.cpp +++ b/src/libslic3r/PrintObject.cpp @@ -1611,7 +1611,7 @@ void PrintObject::discover_vertical_shells() to_polygons(m_layers[idx_layer + 1]->lslices) : Polygons{}; object_volume = intersection(shrinked_bottom_slice, shrinked_upper_slice); - internal_volume = closing(polygonsInternal, SCALED_EPSILON); + internal_volume = closing(polygonsInternal, float(SCALED_EPSILON)); } // The regularization operation may cause scattered tiny drops on the smooth parts of the model, filter them out diff --git a/src/slic3r/GUI/Gizmos/GLGizmoCut.cpp b/src/slic3r/GUI/Gizmos/GLGizmoCut.cpp index 6f372123b1..52d0037819 100644 --- a/src/slic3r/GUI/Gizmos/GLGizmoCut.cpp +++ b/src/slic3r/GUI/Gizmos/GLGizmoCut.cpp @@ -3022,7 +3022,7 @@ void GLGizmoCut3D::toggle_model_objects_visibility() { bool has_active_volume = false; std::vector>* raycasters = m_parent.get_raycasters_for_picking(SceneRaycaster::EType::Volume); - for (const auto raycaster : *raycasters) + for (const std::shared_ptr &raycaster : *raycasters) if (raycaster->is_active()) { has_active_volume = true; break;