BABYLONJS has this method to calculate rotation BABYLON.Quaternion.RotationQuaternionFromAxis(xaxis(v3), yaxis(v3), zaxis(v3));
what is method similar to use in threejs
BABYLONJS has this method to calculate rotation BABYLON.Quaternion.RotationQuaternionFromAxis(xaxis(v3), yaxis(v3), zaxis(v3));
what is method similar to use in threejs
Quaternion.setFromAxisAngle( axis, angle);
https://threejs.org/docs/index.html#api/en/math/Quaternion.setFromAxisAngle
I’m not sure this is the correct method. The method from BabylonJS creates the quaternion from three vectors. It seems to me this workflow is more correct:
matrix.makeBasis( xAxis, yAxis, zAxis );
quaternion.setFromRotationMatrix( matrix );