Hi, I’m creating an application that loads dynamically/interactively Position and Rotation for the object from a text file.
The point is: I have all coordinates setup on external 3D software, but when I simply use the same exported coordinates (from Unity) to Playcanvas all gets very twisted.
I understand this might be related to quaternion conversion because of the different axis orientations… so I managed to adapt a spreadsheet to convert Unity3D euler angles to Playcanvas euler angles with quaternions in the middle for the conversion. I can get the good angles when the input is (X;0;0), (0;Y;0) and (0;0;Z), but when all 3 parameters change I can also get the 3 correponding angles, but it’s messed up, example: I have to change X with Y or find which ones should be negative… I’m very close, but missing something in this axis conversion yet.
I realize also that Playcanvas zeros out all coordinates on import, so there might be a conflict in this as well, but I’m really confused on how to compatibilize and migrate coordinates from Unity to Playcanvas. It’s been very difficult to create a consistent working method for all angles.
Quaternion spreadsheet (yes, there is a excel macro for the complex calculations):
Please help out! In need to deliver our MVP at a trade show next week and this is lagging so much!!!