mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 22:47:29 -06:00
No longer add nodes that don't have children or MeshData
CURA-3493
This commit is contained in:
parent
c9d223acd4
commit
d93b137c95
1 changed files with 8 additions and 1 deletions
|
@ -92,7 +92,12 @@ class ThreeMFReader(MeshReader):
|
||||||
um_node.setMeshData(mesh_data)
|
um_node.setMeshData(mesh_data)
|
||||||
|
|
||||||
for child in savitar_node.getChildren():
|
for child in savitar_node.getChildren():
|
||||||
um_node.addChild(self._convertSavitarNodeToUMNode(child))
|
child_node = self._convertSavitarNodeToUMNode(child)
|
||||||
|
if child_node:
|
||||||
|
um_node.addChild(child_node)
|
||||||
|
|
||||||
|
if um_node.getMeshData() is None and len(um_node.getChildren()) == 0:
|
||||||
|
return None
|
||||||
|
|
||||||
settings = savitar_node.getSettings()
|
settings = savitar_node.getSettings()
|
||||||
|
|
||||||
|
@ -152,6 +157,8 @@ class ThreeMFReader(MeshReader):
|
||||||
self._unit = scene_3mf.getUnit()
|
self._unit = scene_3mf.getUnit()
|
||||||
for node in scene_3mf.getSceneNodes():
|
for node in scene_3mf.getSceneNodes():
|
||||||
um_node = self._convertSavitarNodeToUMNode(node)
|
um_node = self._convertSavitarNodeToUMNode(node)
|
||||||
|
if um_node is None:
|
||||||
|
continue
|
||||||
# compensate for original center position, if object(s) is/are not around its zero position
|
# compensate for original center position, if object(s) is/are not around its zero position
|
||||||
|
|
||||||
transform_matrix = Matrix()
|
transform_matrix = Matrix()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue