mirror of
https://github.com/overte-org/overte.git
synced 2025-04-21 06:44:06 +02:00
Add hand roll, pitch, and yaw
This commit is contained in:
parent
3ddd5854cd
commit
1527c40e1d
1 changed files with 12 additions and 2 deletions
|
@ -236,8 +236,18 @@ var leapHands = (function () {
|
|||
handRoll = handRoll + PI / 2.0;
|
||||
}
|
||||
|
||||
// Hand position ...
|
||||
MyAvatar.setJointModelPositionAndOrientation(hands[h].jointName, handOffset);
|
||||
// Hand position and orientation ...
|
||||
if (h === 0) {
|
||||
MyAvatar.setJointModelPositionAndOrientation(hands[h].jointName, handOffset, Quat.fromPitchYawRollRadians(
|
||||
handPitch,
|
||||
-PI / 2.0 - handYaw,
|
||||
handRoll), true);
|
||||
} else {
|
||||
MyAvatar.setJointModelPositionAndOrientation(hands[h].jointName, handOffset, Quat.fromPitchYawRollRadians(
|
||||
handPitch,
|
||||
PI / 2.0 - handYaw,
|
||||
handRoll), true);
|
||||
}
|
||||
|
||||
// Finger joints ...
|
||||
// TODO: 2.0 * scale factors should not be necessary; Leap Motion controller code needs investigating.
|
||||
|
|
Loading…
Reference in a new issue