mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-11 16:57:53 -06:00
Fixed scaling of multivolumes selection - Added local scale by pressing Alt key while dragging the scale gizmo
This commit is contained in:
parent
f6831dfdea
commit
bcfff27921
4 changed files with 35 additions and 12 deletions
|
@ -787,13 +787,14 @@ void GLGizmoScale3D::on_render(const GLCanvas3D::Selection& selection) const
|
|||
const GLCanvas3D::Selection::IndicesList& idxs = selection.get_volume_idxs();
|
||||
for (unsigned int idx : idxs)
|
||||
{
|
||||
box.merge(selection.get_volume(idx)->bounding_box);
|
||||
const GLVolume* vol = selection.get_volume(idx);
|
||||
box.merge(vol->bounding_box.transformed(vol->get_volume_transformation().get_matrix()));
|
||||
}
|
||||
|
||||
// gets transform from first selected volume
|
||||
const GLVolume* v = selection.get_volume(*idxs.begin());
|
||||
#if ENABLE_MODELVOLUME_TRANSFORM
|
||||
transform = v->world_matrix();
|
||||
transform = v->get_instance_transformation().get_matrix();
|
||||
// gets angles from first selected volume
|
||||
angles = v->get_instance_rotation();
|
||||
// consider rotation+mirror only components of the transform for offsets
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue