mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-07-10 03:21:47 +08:00
Disable subtree rescure when discarding subtrees
It generates many abandoned single pillars
This commit is contained in:
parent
3d81800d15
commit
60b59d08b9
@ -70,6 +70,22 @@ class BranchingTreeBuilder: public branchingtree::Builder {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void discard_subtree(size_t root)
|
void discard_subtree(size_t root)
|
||||||
|
{
|
||||||
|
// Discard all the support points connecting to this branch.
|
||||||
|
traverse(m_cloud, root, [this](const branchingtree::Node &node) {
|
||||||
|
int suppid_parent = m_cloud.get_leaf_id(node.id);
|
||||||
|
int suppid_left = m_cloud.get_leaf_id(node.left);
|
||||||
|
int suppid_right = m_cloud.get_leaf_id(node.right);
|
||||||
|
if (suppid_parent >= 0)
|
||||||
|
m_unroutable_pinheads.emplace_back(suppid_parent);
|
||||||
|
if (suppid_left >= 0)
|
||||||
|
m_unroutable_pinheads.emplace_back(suppid_left);
|
||||||
|
if (suppid_right >= 0)
|
||||||
|
m_unroutable_pinheads.emplace_back(suppid_right);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
void discard_subtree_rescure(size_t root)
|
||||||
{
|
{
|
||||||
// Discard all the support points connecting to this branch.
|
// Discard all the support points connecting to this branch.
|
||||||
// As a last resort, try to route child nodes to ground and stop
|
// As a last resort, try to route child nodes to ground and stop
|
||||||
|
Loading…
x
Reference in New Issue
Block a user