First, I am trying to create a fixed size coordinate system in the bottom right of a scene, refer to this topic, How to get X,Y and Z labels attached to axes? - Questions - Babylon.js (babylonjs.com)
However, I found that the model cannot transform bigger or smaller, due to the camera mode is ORTHOGRAPHIC_CAMERA I guess?
So, I tried to change the camera mode, this is my pg: glTF Loader Demo | Babylon.js Playground (babylonjs.com)
but I found that the axis was a little transformed and were not perpendicular to each other?
Is there any way to solve this problem, by making a fixed not transformed axes and can also change the size of the model?
Do I need to draw the axes using CreateLines?
Note that the multiplication by quatX / quatY for the x/y axes is due to the fact that there is a default rotation for these two axes in the AxisViewer class, and that we must therefore take them into account.
Sorry to bother, I am trying to add a pick mesh function based on this pg glTF Loader Demo | Babylon.js Playground (babylonjs.com)
Line 19, I added: scene.onPointerDown = function (evt, pickResult) { console.log('pickResult', pickResult) };
But it does not work, I am guessing that the axisCamera blocked the mesh?
Is there any solutions?
You need to set scene.cameraToUseForPointers with the first camera, else the system is using the last camera of scene.activeCameras by default for pointer events:
I was trying use this PG to create fixed axis, it is useful, and success;
In addition I need add dynamic texture (x,y,z) in the axis , when I add texture on the axis and rotate the scene, the text label is static not follow the axis to rotate ; how can I let the texture label follow the axis to rotate; I need help