mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-17 14:55:52 +08:00
Merge the two pull requests as asked by @fieldOfView
This commit is contained in:
commit
e7194db7f6
@ -74,14 +74,14 @@ class ShapeArray:
|
|||||||
# If the child-nodes are included, adjust convex hulls as well:
|
# If the child-nodes are included, adjust convex hulls as well:
|
||||||
if include_children:
|
if include_children:
|
||||||
children = node.getAllChildren()
|
children = node.getAllChildren()
|
||||||
if not children is None:
|
if children is not None:
|
||||||
for child in children:
|
for child in children:
|
||||||
# 'Inefficient' combination of convex hulls through known code rather than mess it up:
|
# 'Inefficient' combination of convex hulls through known code rather than mess it up:
|
||||||
child_hull = child.callDecoration("getConvexHull")
|
child_hull = child.callDecoration("getConvexHull")
|
||||||
if not child_hull is None:
|
if child_hull is not None:
|
||||||
hull_verts = hull_verts.unionConvexHulls(child_hull)
|
hull_verts = hull_verts.unionConvexHulls(child_hull)
|
||||||
child_hull_head = child.callDecoration("getConvexHullHead") or child_hull
|
child_hull_head = child.callDecoration("getConvexHullHead") or child_hull
|
||||||
if not child_hull_head is None:
|
if child_hull_head is not None:
|
||||||
hull_head_verts = hull_head_verts.unionConvexHulls(child_hull_head)
|
hull_head_verts = hull_head_verts.unionConvexHulls(child_hull_head)
|
||||||
|
|
||||||
offset_verts = hull_head_verts.getMinkowskiHull(Polygon.approximatedCircle(min_offset))
|
offset_verts = hull_head_verts.getMinkowskiHull(Polygon.approximatedCircle(min_offset))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user