I added gizmo to it and it’s very big. Is there any way to scale the gizmo on my own? So when I scroll in this mode gizmo will be bigger/smaller depends on the scroll value.
Thanks, gizmo.scaleRatio looks much better than gizmo.xGizmo._rootMesh.getChildren()[0].scaling.set(gizmoScaling, gizmoScaling, gizmoScaling).
Please correct me if I’m wrong but I think scaleRatio doesn’t work on gizmoManager https://playground.babylonjs.com/#4TBMBR#62 ← this playground doesn’t work after adding scale ratio for eq. position gizmo
Thanks, that’s very helpful. I switched to version 4.2.0-beta.16 so I’ve got those extra arguments in GizmoManager in my app. I’m wondering if there’s a method/property so I could get all GizmoManagers from the scene and filter ones I need to use. Or does GizmoManager have id or something that I could get it from the scene?
@Cedric Ye, I think that’s easier for me to manage multiple meshes and components made out of them.
I was thinking about extending GizmoManager class and add to it uniqe id. But still I wont have list of gizmoManagers in my scene. So I’ll have to extend scene class by gizmoManager list.
@Cedric, actually I’ve got a question about gizmoManagers. I think the main reason why I’m creating many gizmoManagers it’s because I want different dragBehaviors on specific meshes.
Can we, in babylon, somehow distinguish different dragBehavior on the same gizmo (for the same gizmo, eq. yPlane)?
I made this playground for an example https://playground.babylonjs.com/#4YM59Z#1
it’s no matter to which sphere gizmo is attached, it will always console.log(“sphere 1 drag behavior”). I know I could make global variable and change it in the gizmoManager.onAttachedToMeshObservable and then add some if's or switch in the onDragObservable but I guess that’s not the point. Or is it?
I think it would be great if there was info about mesh the that’s being dragged, in the callback function