mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-02 06:40:40 +08:00
Fix crash in multi-material segmentation when there wasn't any input polygon for some layer.
This commit is contained in:
parent
4f5bd3ff5b
commit
5c7888b114
@ -1801,6 +1801,9 @@ std::vector<std::vector<ExPolygons>> segmentation_by_painting(const PrintObject
|
|||||||
throw_on_cancel_callback();
|
throw_on_cancel_callback();
|
||||||
|
|
||||||
std::vector<ColorProjectionLines> &input_polygons_projection_lines = input_polygons_projection_lines_layers[layer_idx];
|
std::vector<ColorProjectionLines> &input_polygons_projection_lines = input_polygons_projection_lines_layers[layer_idx];
|
||||||
|
if (input_polygons_projection_lines.empty()) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
if constexpr (MM_SEGMENTATION_DEBUG_COLOR_RANGES) {
|
if constexpr (MM_SEGMENTATION_DEBUG_COLOR_RANGES) {
|
||||||
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]);
|
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]);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user