Hello all,
This question may be quite simple for the experts.
I am trying to use the gizmo on meshes that belong to a hierarchy. The meshes are to be positioned and rotated in local space. Since only some meshes are to be allowed for manipulation, the are made part of the attachableMeshes array.
While positiongizmo seems to work in this way, rotationgizmo seems to do something unexpected. Instead of rotating on its own axis, it seems to be doing something else.
OK, I understand a bit better now. It appears you’re working in Euler space and not in quaternion space. Just rotate in quaternions and you’ll avoid the limit of 180 degrees vs. -180 degrees. It’s a bit of math, but a skill which is always valuable.
I’ve actually ignored gizmos in my code, and simply parented every object I need to manipulate. If you discard Gizmos, does your scene work? Sometimes we need to take a step back. Not fun, but saves more time than looking for the tools that might work for the masses.
The scene works perfectly. Very happy with babylonjs. I am using babylonjs for engineering applications and prefer to use built in functions as I am not really a developer. I had my own code for translation and rotation (Euler angles though), however moved to gizmos for the looks and consistent behaviour and ease of use.
I am using Babylonjs 3.3.0 and have the same issue. I saw that the solution is in a PR. How can I update my babylonjs without using version 4 (since this version is breaking many things)?
I could solve some of the problems when migrating from 3.3.0 to 4.0.3, but now I cannot see the gizmo, even though I am copying the code from here, and in there, it is working properly. Can someone help me?