From c96d472af53c2c5f3d66fffbb16051afb141a287 Mon Sep 17 00:00:00 2001 From: XunZhangBambu Date: Fri, 15 Mar 2024 16:50:30 +0800 Subject: [PATCH] ENH: recover the origin order of prepare infill 1.Change small sparse infill to solid infill after doing expand introduces too much solid infill. jira:NEW Signed-off-by: XunZhangBambu Change-Id: If8ac07356185729c192d42bae8d9325ebe5fee87 --- src/libslic3r/PrintObject.cpp | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/libslic3r/PrintObject.cpp b/src/libslic3r/PrintObject.cpp index 8a3983715..0b13215a2 100644 --- a/src/libslic3r/PrintObject.cpp +++ b/src/libslic3r/PrintObject.cpp @@ -260,6 +260,14 @@ void PrintObject::prepare_infill() this->detect_surfaces_type(); m_print->throw_if_canceled(); + // Also tiny stInternal surfaces are turned to stInternalSolid. + BOOST_LOG_TRIVIAL(info) << "Preparing fill surfaces..." << log_memory_info(); + for (auto *layer : m_layers) + for (auto *region : layer->m_regions) { + region->prepare_fill_surfaces(); + m_print->throw_if_canceled(); + } + // this will detect bridges and reverse bridges // and rearrange top/bottom/internal surfaces // It produces enlarged overlapping bridging areas. @@ -306,13 +314,6 @@ void PrintObject::prepare_infill() } // for each region #endif /* SLIC3R_DEBUG_SLICE_PROCESSING */ - // Also tiny stInternal surfaces are turned to stInternalSolid. - BOOST_LOG_TRIVIAL(info) << "Preparing fill surfaces..." << log_memory_info(); - for (auto *layer : m_layers) - for (auto *region : layer->m_regions) { - region->prepare_fill_surfaces(); - m_print->throw_if_canceled(); - } // Only active if config->infill_only_where_needed. This step trims the sparse infill, // so it acts as an internal support. It maintains all other infill types intact.