History

final

Howard Stearns committed 11 years ago

Commit 476ca361 parent 57e4ff11 file · +7 −2Browse files

Showing the changes to interface/src/avatar/SkeletonModel.cpp (1 of 1 file). Show all

Unified · Split

interface/src/avatar/SkeletonModel.cpp+7−2
@@ -41,7 +41,7 @@ SkeletonModel::~SkeletonModel() { · 40 unmodified lines
41 41
42void SkeletonModel::initJointStates(QVector<JointState> states) {42void SkeletonModel::initJointStates(QVector<JointState> states) {
43 const FBXGeometry& geometry = _geometry->getFBXGeometry();43 const FBXGeometry& geometry = _geometry->getFBXGeometry();
44 glm::mat4 parentTransform = glm::scale(_scale) * glm::translate(_offset) * geometry.offset/* * glm::mat4_cast(getRotation())*/;44 glm::mat4 parentTransform = glm::scale(_scale) * glm::translate(_offset) * geometry.offset;
45 45
46 int rootJointIndex = geometry.rootJointIndex;46 int rootJointIndex = geometry.rootJointIndex;
47 int leftHandJointIndex = geometry.leftHandJointIndex;47 int leftHandJointIndex = geometry.leftHandJointIndex;
@@ -123,10 +123,15 @@ void SkeletonModel::updateRig(float deltaTime, glm::mat4 parentTransform) { · 75 unmodified lines
123 params.rightEyeJointIndex = geometry.rightEyeJointIndex;123 params.rightEyeJointIndex = geometry.rightEyeJointIndex;
124 124
125 _rig->updateFromHeadParameters(params);125 _rig->updateFromHeadParameters(params);
126 } else if (true/*_owningAvatar->getHead()->isLookingAtMe()*/) {126 } else {
127 // This is a little more work than we really want.
128 //
127 // Other avatars joint, including their eyes, should already be set just like any other joints129 // Other avatars joint, including their eyes, should already be set just like any other joints
128 // from the wire data. But when looking at me, we want the eyes to use the corrected lookAt.130 // from the wire data. But when looking at me, we want the eyes to use the corrected lookAt.
129 //131 //
132 // Thus this should really only be ... else if (_owningAvatar->getHead()->isLookingAtMe()) {...
133 // However, in the !isLookingAtMe case, the eyes aren't rotating the way they should right now.
134 // We will revisit that as priorities allow, and particularly after the new rig/animation/joints.
130 const FBXGeometry& geometry = _geometry->getFBXGeometry();135 const FBXGeometry& geometry = _geometry->getFBXGeometry();
131 Head* head = _owningAvatar->getHead();136 Head* head = _owningAvatar->getHead();
132 // If the head is not positioned, updateEyeJoints won't get the math right137 // If the head is not positioned, updateEyeJoints won't get the math right

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t