Speed up of organic support smoothing & collision detection.

This commit is contained in:
Vojtech Bubnik 2023-01-24 14:31:20 +01:00
parent d327a6b2ab
commit 3d9f39e258
3 changed files with 326 additions and 98 deletions

View file

@ -237,6 +237,11 @@ public:
*/
const Polygons& getCollision(const coord_t radius, LayerIndex layer_idx, bool min_xy_dist) const;
// Get a collision area at a given layer for a radius that is a lower or equial to the key radius.
// It is expected that the collision area is precalculated for a given layer at least for the radius zero.
// Used for pushing tree supports away from object during the final Organic optimization step.
std::optional<std::pair<coord_t, std::reference_wrapper<const Polygons>>> get_collision_lower_bound_area(LayerIndex layer_id, coord_t max_radius) const;
/*!
* \brief Provides the areas that have to be avoided by the tree's branches
* in order to reach the build plate.