mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-22 22:23:57 -06:00
Reset the entire transformation when merging
This fixes the issue when the packing algorithm rotated an object CURA-7796
This commit is contained in:
parent
6799e3fd7d
commit
d35d6b087a
1 changed files with 2 additions and 5 deletions
|
@ -1522,13 +1522,10 @@ class CuraApplication(QtApplication):
|
|||
|
||||
# Move each node to the same position.
|
||||
for mesh, node in zip(meshes, group_node.getChildren()):
|
||||
transformation = node.getLocalTransformation()
|
||||
transformation.setTranslation(zero_translation)
|
||||
transformed_mesh = mesh.getTransformed(transformation)
|
||||
|
||||
node.setTransformation(Matrix())
|
||||
# Align the object around its zero position
|
||||
# and also apply the offset to center it inside the group.
|
||||
node.setPosition(-transformed_mesh.getZeroPosition() - offset)
|
||||
node.setPosition(-mesh.getZeroPosition() - offset)
|
||||
|
||||
# Use the previously found center of the group bounding box as the new location of the group
|
||||
group_node.setPosition(group_node.getBoundingBox().center)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue