Commit graph

363 commits

Author SHA1 Message Date
Anthony J. Thibault
cd4d9255bd Added defaultPoseFlags to avatar protocol
Change rotationSet to rotationIsDefaultPose for JointData
Also for translation.  Fixed all code to flip boolean value.
Created EntityJointData so that the ModelEntity stuff doesn't need to change.
2018-01-19 15:34:27 -08:00
Anthony J. Thibault
bc587bf6d8 Removal of legacy Rig methods 2018-01-16 18:19:35 -08:00
Anthony J. Thibault
576273efe3 Remove Rig::restoreJointPosition and references to it. 2018-01-16 18:01:58 -08:00
Anthony J. Thibault
7753b8a0b5 Merge branch 'master' into feature/dual-quat 2018-01-11 17:31:29 -08:00
Anthony J. Thibault
ae997928c1 Bug fix to prevent wrists entering the avatar's torso.
This was inadvertently disabled in PR #11978.
2018-01-10 11:51:44 -08:00
Anthony J. Thibault
565875e823 WIP first attempt at dual quat skinning 2018-01-04 16:09:02 -08:00
Anthony J. Thibault
e2df9e29e2 Fix for crash in AnimSkeleton::getNumJoints()
When initAnimGraph is called it asynchronously loads the Animation graph in the background.
If the model url is changed, or the Model is deleted in between the initial load and it's completion,
It's possible to access a bad Rig::_animSkeleton pointer.
The fix is to hold onto the _animSkeleton pointer via a weak ref.
2017-12-15 16:46:27 -08:00
luiscuenca
bf0d55aa98 9267 Fix not restoring animations after changing view modes 2017-11-15 15:04:24 -07:00
Anthony J. Thibault
4169e11e77 Merge branch 'master' into bug-fix/div-by-zero 2017-11-10 10:15:26 -08:00
Anthony J. Thibault
9724a5e5b8 Fix for address sanitizer warning
This fixes a potential null pointer dereference.
2017-11-09 10:53:36 -08:00
luiscuenca
81509b3e92 coding standard 2017-11-02 10:34:57 -07:00
luiscuenca
e201e82ec2 formatting 2017-11-01 19:45:56 -07:00
luiscuenca
6a2dc38fdd restoring previous roles 2017-11-01 19:38:37 -07:00
luiscuenca
da63e85699 Bug 8270 fixed 2017-11-01 09:17:04 -07:00
Andrew Meadows
c79bf3bc04 cleanup WANT_DETAILED_PROFILING 2017-10-19 14:31:50 -07:00
Andrew Meadows
339edc67c8 ifdef out more per-frame-per-entity profiling 2017-10-16 17:27:53 -07:00
Anthony J. Thibault
fe57a20979 div by zero fix 2017-10-10 16:22:49 -07:00
Anthony J. Thibault
18d723b6b4 div by zero fixes, detected by address sanitizer 2017-10-10 16:17:39 -07:00
SamGondelman
a6f2545511 fix local t pose 2017-10-03 12:51:37 -07:00
SamGondelman
b8ea6c22fa no tpose when switching avatars
(cherry picked from commit fcfac9efc0)
2017-09-29 13:47:09 -07:00
SamGondelman
306cf883fe don't reload animGraph if url didn't change 2017-09-26 18:18:41 -07:00
Anthony J. Thibault
573985c7c9 Merge branch 'master' into feature/ant-man 2017-08-28 09:27:04 -07:00
Anthony J. Thibault
5042b90052 Rig: Fix for debug mode assert 2017-08-24 10:47:48 -07:00
Brad Hefta-Gaub
afce8b547a Merge pull request #11197 from hyperlogic/bug-fix/prevent-rig-crash-in-lambda
Rig: Use a registry to prevent use after free crashes/corruption
2017-08-23 15:09:28 -07:00
Anthony J. Thibault
aef19c6f97 Rig: Use a registry to prevent use after free crashes/corruption
Create a global registry to hold all the currently active Rig instances.
Use this registry and it's mutex to prevent accessing the rig after it has already been destroyed,
or is in the process of being destroyed on the main thread.
2017-08-15 18:28:51 -07:00
Anthony J. Thibault
e9b8e5431d Fix for incorrectly scaled bounding volumes when switching avatars
Make sure to explicitly set the _geometryToRigTransform in Rig::initJointStates().

This should fix small bounding volume when switching from the Gamebot avatar (which has 0.008 scaling)
to another avatar (which ususally have 0.01 scaling).
2017-08-15 17:26:51 -07:00
Anthony J. Thibault
f46198c2fd Simplified/Improved avatar capsule calculation
IK is no longer performed during capsule calculation, This fixes an issue with the mannequin avatar in the marketplace.
Specifically, it was causing the hips to rise during IK which would result in an incorrectly sized and offset capsule.
2017-08-15 13:48:10 -07:00
Anthony J. Thibault
04006a9f76 code review feedback 2017-08-15 11:19:41 -07:00
Anthony J. Thibault
cd57c0706a more warning fixes 2017-08-11 17:46:50 -07:00
Anthony J. Thibault
9e1218b4a4 Use k-dop collision to prevent hands from entering body. 2017-08-11 14:50:00 -07:00
Anthony J. Thibault
33a1d6e225 Merge branch 'master' into feature/secondary-pose-support 2017-07-24 17:27:33 -07:00
Andrew Meadows
5a4f56388b Merge pull request #10881 from hyperlogic/feature/smooth-ik-chains
Smooth IK when trackers are disabled / enabled.
2017-07-14 16:59:30 -07:00
Anthony J. Thibault
c85e187c61 first stab at secondary target pose support 2017-07-13 18:12:33 -07:00
Anthony J. Thibault
1cdc0071f3 Fixed issue with hips and chest not ramping off properly. 2017-07-10 16:17:25 -07:00
Seth Alves
15d379cc5a coding style 2017-07-06 17:36:28 -07:00
Seth Alves
24c8267030 in Rig joint accessors, if on the Rig's thread use internalPoseSet, else use external 2017-07-06 13:22:14 -07:00
Anthony J. Thibault
06d512dab9 Warning fixes 2017-07-05 10:43:24 -07:00
Anthony J. Thibault
2f6a37ee53 Removed interpolation of hand controllers 2017-07-03 16:31:05 -07:00
Anthony J. Thibault
aba164b26e more clean up of Rig::computeAvatarBoundingCapsule 2017-06-30 13:27:53 -07:00
Anthony J. Thibault
237872e477 sizes and order of IKTargetVarVec and IKTargetVec are now the same.
Also, A change in how the bone name to bone index lookup occurs exposed a bug
in Rig::computeAvatarBoundingCapsule(), basically it was not actually preforming IK,
and the ik targets were in the wrong coordinate frame.  So when IK was actually
performed it would give bad results.  This bug is now fixed.
2017-06-30 12:47:01 -07:00
Sam Gateau
f7a3b3a411 Experimenting faster getters on Avatar for scripts 2017-06-29 15:55:47 +02:00
Anthony J. Thibault
8602d57a57 Eliminated to wiggle while pucks are enabled.
* Added new anim node AnimDefaultPose
* AnimNodeLoader was changed to support the addition of the AnimDefaultPose node
* Edited default avatar-animation.json to insert an AnimOverlay and AnimDefaultPose between the IK node and the rest of the "underPose".
* Rig uses this to fade in default pose for the toes when the hip/feet puck are active.
  This effectively deadens the toe animations, without effecting the hand animations.
* Also, the rig was changed to use the LimitCenter solution when the feet are enabled but the hips are not.
2017-06-26 14:09:10 -07:00
Anthony J. Thibault
b8c638b2b7 warning fixes 2017-06-23 14:36:59 -07:00
Anthony J. Thibault
f320610681 opened up shoulder constraint + other fixes
* bent elbows will be away from the body a bit more.
* sped up smoothing of pole vectors
2017-06-23 14:06:00 -07:00
Anthony J. Thibault
54af6af651 Fix for pole vector stability and knee pole vector computation 2017-06-23 10:38:21 -07:00
Anthony J. Thibault
0f51236fb0 Rig.cpp: take avatar scale into account when computing elbow pole vector 2017-06-21 14:36:42 -07:00
Anthony J. Thibault
1979ed7f3a Disable elbow pole vector if arm/shoulder pucks are enabled 2017-06-19 16:58:11 -07:00
Anthony J. Thibault
c236afe68c Simplify passing data from MySkeletonModel to Rig 2017-06-19 16:54:39 -07:00
Anthony J. Thibault
3f5aba2655 improved elbow pole vector calculation
Also, pole vectors are blended spherical linearly, this might help fast moving
pole vectors from rotating too quickly.
2017-06-19 13:21:12 -07:00
Anthony J. Thibault
81852cd91c warning fixes 2017-06-16 18:15:41 -07:00