@@ -718,15 +718,7 @@ bool PrintObject::invalidate_state_by_config_options(
718
718
|| opt_key == " first_layer_extrusion_width" ) {
719
719
steps.emplace_back (posInfill);
720
720
} else if (opt_key == " fill_pattern" ) {
721
- steps.emplace_back (posInfill);
722
-
723
- const auto *old_fill_pattern = old_config.option <ConfigOptionEnum<InfillPattern>>(opt_key);
724
- const auto *new_fill_pattern = new_config.option <ConfigOptionEnum<InfillPattern>>(opt_key);
725
- assert (old_fill_pattern && new_fill_pattern);
726
- // We need to recalculate infill surfaces when infill_only_where_needed is enabled, and we are switching from
727
- // the Lightning infill to another infill or vice versa.
728
- if (m_config.infill_only_where_needed && (new_fill_pattern->value == ipLightning || old_fill_pattern->value == ipLightning))
729
- steps.emplace_back (posPrepareInfill);
721
+ steps.emplace_back (posPrepareInfill);
730
722
} else if (opt_key == " fill_density" ) {
731
723
// One likely wants to reslice only when switching between zero infill to simulate boolean difference (subtracting volumes),
732
724
// normal infill and 100% (solid) infill.
@@ -1641,6 +1633,11 @@ void PrintObject::bridge_over_infill()
1641
1633
continue ;
1642
1634
};
1643
1635
1636
+ if (expansion_space[candidates.first ].empty ()){
1637
+ // there is no expansion space to which can anchors on this island, skip
1638
+ continue ;
1639
+ }
1640
+
1644
1641
// Gather lower layers sparse infill areas, to depth defined by used bridge flow
1645
1642
Polygons lower_layers_sparse_infill{};
1646
1643
double bottom_z = layer->print_z - max_bridge_flow_height[candidates.first ] - EPSILON;
@@ -1663,9 +1660,11 @@ void PrintObject::bridge_over_infill()
1663
1660
1664
1661
for (size_t region_idx : regions_under_to_check) {
1665
1662
const LayerRegion *region = po->get_layer (i)->get_region (region_idx);
1666
- for (const Surface *surface : region->fill_surfaces ().filter_by_type (stInternal)) {
1667
- Polygons p = to_polygons (surface->expolygon );
1668
- lower_layers_sparse_infill.insert (lower_layers_sparse_infill.end (), p.begin (), p.end ());
1663
+ if (region->region ().config ().fill_density .value < 100 ) {
1664
+ for (const Surface *surface : region->fill_surfaces ().filter_by_type (stInternal)) {
1665
+ Polygons p = to_polygons (surface->expolygon );
1666
+ lower_layers_sparse_infill.insert (lower_layers_sparse_infill.end (), p.begin (), p.end ());
1667
+ }
1669
1668
}
1670
1669
}
1671
1670
}
0 commit comments