Fixed short edge collapse algortihm, so that it does not decimate all triangles on very high detailed models

Relevant issue 8834 Access Error when slicing
This commit is contained in:
PavelMikus 2022-09-09 12:50:10 +02:00
parent 82716cd78c
commit 2781f716f4
3 changed files with 8 additions and 3 deletions

View file

@ -642,8 +642,8 @@ void compute_global_occlusion(GlobalModelInfo &result, const PrintObject *po,
BOOST_LOG_TRIVIAL(debug)
<< "SeamPlacer: decimate: start";
its_short_edge_collpase(triangle_set, 25000);
its_short_edge_collpase(negative_volumes_set, 25000);
its_short_edge_collpase(triangle_set, SeamPlacer::fast_decimation_triangle_count_target);
its_short_edge_collpase(negative_volumes_set, SeamPlacer::fast_decimation_triangle_count_target);
size_t negative_volumes_start_index = triangle_set.indices.size();
its_merge(triangle_set, negative_volumes_set);