control the joints using quaternion or rotation matrix.
Posted: 05 May 2020, 17:35
Hi, there.
I'm trying to control joints of a mannequin with the euler angle getting from the motion capture.However, I have a problem. In the process of calculating the angle, I have to use "asin". As you know, this range is [pi/2, -pi/2]. In other words, the range of motion of the joints is this range.I want to solve this problem, so I'm thinking of controlling the joints using quaternion or rotation matrix. I know about sim.setObjectMatrix/sim.setObjectquaternion, but this is for the object not joints. I know about sim.setSphericalJointMatrix too, but spherical joint can't be "Moter enabled".
Is there other API or methods to control the joint using quaternion or matrix ?
I'm trying to control joints of a mannequin with the euler angle getting from the motion capture.However, I have a problem. In the process of calculating the angle, I have to use "asin". As you know, this range is [pi/2, -pi/2]. In other words, the range of motion of the joints is this range.I want to solve this problem, so I'm thinking of controlling the joints using quaternion or rotation matrix. I know about sim.setObjectMatrix/sim.setObjectquaternion, but this is for the object not joints. I know about sim.setSphericalJointMatrix too, but spherical joint can't be "Moter enabled".
Is there other API or methods to control the joint using quaternion or matrix ?