Make sure that when drill holes are manipulated with, all data are invalidated properly

It is needed to regenerate hollow_mesh_with_holes completely, it may contain holes that were deleted by the user in the meantime
This commit is contained in:
Lukas Matena 2020-02-03 17:29:15 +01:00
parent ad3e3be3bc
commit d0f21dda4a
2 changed files with 28 additions and 16 deletions

View file

@ -84,7 +84,7 @@ public:
// Get the mesh that is going to be printed with all the modifications
// like hollowing and drilled holes.
const TriangleMesh & get_mesh_to_print() const {
return m_hollowing_data ? m_hollowing_data->hollow_mesh_with_holes : transformed_mesh();
return (m_hollowing_data && is_step_done(slaposDrillHoles)) ? m_hollowing_data->hollow_mesh_with_holes : transformed_mesh();
}
// This will return the transformed mesh which is cached