Skip to content

Commit 5c7888b

Browse files
committed
Fix crash in multi-material segmentation when there wasn't any input polygon for some layer.
1 parent 4f5bd3f commit 5c7888b

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/libslic3r/MultiMaterialSegmentation.cpp

+3
Original file line numberDiff line numberDiff line change
@@ -1801,6 +1801,9 @@ std::vector<std::vector<ExPolygons>> segmentation_by_painting(const PrintObject
18011801
throw_on_cancel_callback();
18021802

18031803
std::vector<ColorProjectionLines> &input_polygons_projection_lines = input_polygons_projection_lines_layers[layer_idx];
1804+
if (input_polygons_projection_lines.empty()) {
1805+
continue;
1806+
}
18041807

18051808
if constexpr (MM_SEGMENTATION_DEBUG_COLOR_RANGES) {
18061809
export_color_projection_lines_color_ranges_to_svg(debug_out_path("mm-color-ranges-%d.svg", layer_idx), input_polygons_projection_lines, input_expolygons[layer_idx]);

0 commit comments

Comments
 (0)