Seth Alves
43592fd699
Merge pull request #7048 from hyperlogic/tony/avatar-on-moving-platform
...
Better avatar animation when attached to a moving entity
2016-02-09 14:30:02 -08:00
Brad Davis
7d99f9e72f
PR comments
2016-02-09 10:16:44 -08:00
Brad Davis
421160eeb6
Make the file parsing threads run at lower priority
2016-02-08 23:55:02 -08:00
Anthony J. Thibault
2667fe3c24
Merge branch 'master' into tony/avatar-on-moving-platform
2016-02-08 14:32:46 -08:00
Anthony J. Thibault
20a38f613e
Rig: remove position delta based velocity.
...
In general, the physics body velocity is MUCH more behaved now.
2016-02-08 14:30:28 -08:00
Philip Rosedale
63afa8c1ed
Merge pull request #7040 from hyperlogic/tony/landing-animation
...
MyAvatar: added standing and run landing animations
2016-02-08 11:38:12 -08:00
Brad Hefta-Gaub
eebf6f8883
Merge pull request #7021 from hyperlogic/tony/animation-mirror-support
...
AnimClip: Animation mirror support
2016-02-05 19:25:01 -08:00
Anthony J. Thibault
d24a024726
MyAvatar: added standing and run landing animations
2016-02-05 17:53:50 -08:00
Anthony J. Thibault
bfeace78f7
AnimInverseKinematics: warning fixes
2016-02-04 18:51:48 -08:00
Anthony J. Thibault
51189cfc50
AnimInverseKinematics: opened up UpLeg and Leg constraints
...
This improves the quality of the jump animations, while IK is enabled.
2016-02-04 17:56:41 -08:00
Anthony J. Thibault
8ca8550f26
MyAvatar: Standing Takeoff and In-Air Animations
...
Now there are two sets of of jump takeoff and in-air animations.
* Run - Used when the character jumps or falls with a small forward velocity.
* Standing - Used when the character jumps or falls in-place or backward.
CharacterController
* increased takeoff duration to 250 ms
* increased takeoff to fly duration to 1100 ms
* added standing jump and in-air animations
* added 250 milisecond delay between ground and hover, to prevent going into hover when walking over cracks.
* take-off to in-air transitions now use the new snapshotPrev interp type for a smoother tweening.
2016-02-04 17:56:07 -08:00
Anthony J. Thibault
a8e092272c
AnimStateMachine: added new State parameter interpType
...
interpType defines how the interpolation between two states is performed.
* SnapshotBoth: Stores two snapshots, the previous animation before interpolation begins and the target state at the
interTarget frame. Then during the interpolation period the two snapshots are interpolated to produce smooth motion between them.
* SnapshotPrev: Stores a snapshot of the previous animation before interpolation begins. However the target state is
evaluated dynamically. During the interpolation period the previous snapshot is interpolated with the target pose
to produce smooth motion between them. This mode is useful for interping into a blended animation where the actual
blend factor is not known at the start of the interp or is might change dramatically during the interp.
2016-02-04 10:32:58 -08:00
Andrew Meadows
861082964e
Merge pull request #7017 from hyperlogic/tony/fly
...
MyAvatar: Improved Jump / InAir / Fly behavior
2016-02-03 12:22:30 -08:00
Stephen Birarda
93530fca72
fix the last of the current override warnings for OS X
2016-02-03 11:08:41 -08:00
Anthony J. Thibault
03d5bc885b
AnimClip: added mirrorFlag anim var
2016-02-02 17:10:15 -08:00
Anthony J. Thibault
e6abc026c8
AnimClip: mirror animation support
2016-02-02 17:02:29 -08:00
Anthony J. Thibault
656608e2ff
Fixes for away.js
2016-02-02 12:08:52 -08:00
Anthony J. Thibault
47f3ce3786
CharacterController jump is more reliable.
2016-02-02 11:26:16 -08:00
Anthony J. Thibault
2936811484
Added takeoff animation, WIP
...
Character controller still has some jump/in-air bugs.
2016-02-02 11:26:15 -08:00
Anthony J. Thibault
61c55ebf6c
Updated character controller with a state enumeration
...
Also, adjusted checkForSupport logic such that very slanted walls are not considered support.
2016-02-02 11:26:15 -08:00
Anthony J. Thibault
e9fd439ffd
Added inAir animations
2016-02-02 11:23:46 -08:00
Andrew Meadows
71664dffae
change string comparisons to be CaseSensitive
2016-02-01 09:50:01 -08:00
Andrew Meadows
de54a0ac4b
remove cruft
2016-01-29 14:51:24 -08:00
Andrew Meadows
14ec1b6295
reduce hand IK coupling to hip position
2016-01-29 14:28:56 -08:00
Andrew Meadows
a98459dfa8
minor IK optimization: changed accumulators only
2016-01-29 14:28:56 -08:00
Andrew Meadows
449d566d2a
properly track lowestMovedIndex
2016-01-29 14:28:56 -08:00
Andrew Meadows
48f6a9c05f
fix IK looping error after minor refactor
2016-01-29 14:28:56 -08:00
Andrew Meadows
7b3f688a17
pull CCD IK solution pass into protected method
2016-01-29 14:28:56 -08:00
Andrew Meadows
1b45f5cc0c
tweaks to neck and spine constraints
2016-01-27 14:45:09 -08:00
Andrew Meadows
f67a20ee68
apply _hipsOffset in hips local-frame
2016-01-27 14:45:08 -08:00
Andrew Meadows
00715f1906
apply "hips offset" to root of state graph
...
(Somemtimes the hips are not the root.
I'm looking at YOU blender!)
2016-01-27 14:45:06 -08:00
Anthony Thibault
3cdd88e06c
Merge pull request #6951 from ZappoMan/fixAnimationRestart
...
fix for animations stopping after domain restart
2016-01-27 14:31:27 -08:00
Howard Stearns
0d257b82fa
Merge pull request #6934 from hyperlogic/tony/anim-pre-post-rot-support
...
Avatar Developer Menu: added animation debug options
2016-01-27 10:39:25 -08:00
Brad Hefta-Gaub
f178fc789c
fix for animations stopping after domain restart
2016-01-26 18:44:34 -08:00
Anthony J. Thibault
33993b8c44
AnimClip: removed unused static member.
2016-01-26 13:34:21 -08:00
Anthony J. Thibault
69d833a6c0
AnimClip: consistent application of translations
...
Apply animation translation the same way regardless of state of usePreAndPostPoseFromAnimation.
2016-01-26 10:53:21 -08:00
U-GAPOS\andrew
2728290ffb
fix bug in IK and tune head/neck constraints
2016-01-26 09:37:33 -08:00
Anthony J. Thibault
3b062b7a31
AnimClip: special case the translation on the eyes
2016-01-25 18:52:14 -08:00
Anthony J. Thibault
3cee3cbb5a
Avatar Developer Menu: added animation debug options
...
This options are for for developers only and might help debug animation related issues.
* Enable Inverse Kinematics: this can be toggled to disable IK for the avatar.
* Enable Anim Pre and Post Rotations: this option can be used to use FBX pre-rotations from source avatar animations, instead of the current default, which is to use them from the source model.
This only effects FBX files loaded by the animation system, it does not affect changing model orientations via JavaScript.
2016-01-25 18:52:13 -08:00
Anthony J. Thibault
1bdeeeceeb
AnimSkeleton: Added getPre and Post rotation accessors
2016-01-25 18:52:12 -08:00
Anthony J. Thibault
7af20e90c8
Hooked up fly animation to json and Rig
2016-01-22 13:47:09 -08:00
Anthony J. Thibault
cac19b8579
grab animation work
...
Hand animations now have 5 states:
* idle
* open
* grasp
* point
* farGrasp
The handControllerGrab.js script now chooses one of these five animations, based on the state of the HandController object.
Also, removed hand trigger AnimVar setting from C++ Rig class.
2016-01-07 19:36:57 -08:00
Anthony J. Thibault
3e6ff0eb68
Moved hand animation control into grab script.
2016-01-05 19:56:56 -08:00
Brad Hefta-Gaub
02835fc960
Merge pull request #6702 from hyperlogic/tony/soft-attachments
...
Soft Attachment Support
2016-01-03 08:46:16 -10:00
Brad Davis
76eba89f7d
Merge pull request #6745 from hyperlogic/tony/neuron-plugin
...
Support for Perception Neuron
2015-12-30 11:39:32 -05:00
Andrew Meadows
ec27c75332
Merge pull request #6660 from hyperlogic/tony/anim-expressions
...
AnimExpression: boolean expression parser and evaluator
2015-12-30 08:36:44 -08:00
Anthony J. Thibault
c2dd00375d
Merge branch 'master' into tony/soft-attachments
2015-12-29 13:21:37 -08:00
Anthony J. Thibault
6afe3bae5e
Copy Neuron joints into controller poses
...
This makes the accessible for controller mapping and to JavaScript.
Added 'neuronAvatar.js' as an example of reading joints from the neuron and setting them
on the avatar. NOTE: the rotations are currently in the wrong coordinate frame.
2015-12-22 17:21:33 -08:00
Andrew Meadows
aa3d1c6e4c
Merge pull request #6680 from hyperlogic/tony/windmill-anim-fix
...
ModelEntityItem: Fix for incorrect animations with preTranslations
2015-12-18 14:16:35 -08:00
Anthony J. Thibault
6b5b272cd7
Added SoftAttachmentModel class.
...
Is a subclass of Model, it overrides the updateClusterMatrices so it will pull
the actual joint matrices from a different rig override.
For the avatar soft attachment system, this override will be the Avatar::_skeletonModel rig.
This will give us the ability for an avatar to "wear" non-rigid attachments, such as clothing.
2015-12-18 09:52:11 -08:00
Anthony J. Thibault
3b1ba67a88
ModelEntityItem: Fix for incorrect animations with preTranslations
...
ModelEntities that were playing animations on models with local pivot offsets were not working correctly.
Specifically, the windmill animation in the demo domain.
We now compose a matrix containing all of the FBX's preTranslation, preRotation and postTranformations.
2015-12-16 17:08:22 -08:00
Anthony J. Thibault
30480f126b
Improved idle to walk forward transition
...
Hooked up a transition animation from idle to walk in the animation json.
Also fixed a bug in the AnimBlendLinearMove which was preventing the interpolation
into idle from being correct.
2015-12-15 17:26:17 -08:00
Anthony J. Thibault
ab85e2967a
AnimExpression: support for unary not.
2015-12-15 13:18:30 -08:00
Anthony J. Thibault
22756d168b
Changed grammar to support boolean and and or.
2015-12-15 10:35:35 -08:00
Anthony J. Thibault
2b0ed55077
Merge branch 'master' into tony/anim-expressions
2015-12-15 10:35:19 -08:00
Anthony J. Thibault
3f0cdb3c02
Merge branch 'master' into tony/js-avatar-default-pose
2015-12-14 11:19:24 -08:00
Atlante45
d3224bfde3
More warning fixes
2015-12-11 16:03:44 -08:00
Atlante45
da63357254
More warning fixes
2015-12-11 15:42:15 -08:00
Atlante45
ce51350b65
Fix warnings on windows 64bit
2015-12-11 15:42:15 -08:00
Howard Stearns
dfec222c81
Report animation triggers to normal javascript animationStateHandlers, and update away.js as an example.
2015-12-10 20:39:01 -08:00
Anthony J. Thibault
652ce5501f
Expose Avatar default pose to JavaScript
...
New JavaScript API to get the avatar's default pose.
MyAvatar.getDefaultJointRotation(index);
MyAvatar.getDefaultJointTranslation(index);
See `examples/tPose.js` for example usage
2015-12-10 13:57:31 -08:00
Seth Alves
f99812a903
adjust method names to fit convention
2015-12-07 14:31:08 -08:00
Anthony J. Thibault
fd4ed29405
MyAvatar.clearJointData bug fix
...
MyAvatar.setJointRotation() now works properly after MyAvatar.clearJointData()
2015-12-07 09:03:40 -08:00
Seth Alves
a948ae5f19
children of avatar joints might be right, now
2015-12-06 10:48:00 -08:00
Anthony J. Thibault
7abfc93ff9
Avatar::getJointRotation and getJointTranslation is thread-safe
...
It can be called from script with minimal blocking,
because it inspects a copy of the joint values from the Rig, which is updated atomically.
This copy occurs in Rig::updateAnimations()
2015-12-04 16:16:17 -08:00
Anthony J. Thibault
ba001ef4b0
Rig: split Poses into internal and external sets.
...
In preparation for making some accessors thread safe.
2015-12-04 15:15:18 -08:00
Anthony J. Thibault
99223d0a3c
AnimExpression: support for parsing simple expressions
...
supports parens, binary +, -, / and *.
/ and * have higher precedence then + and -
2015-12-03 15:02:00 -08:00
Anthony J. Thibault
710ce7e639
Merge branch 'master' into tony/anim-expressions
2015-12-03 09:56:28 -08:00
Anthony J. Thibault
9c0b4bc2a2
Fix for model entities with non-uniform scaled mesh
...
Logic which extracted rotations from a non-uniformly scaled matrices was sometimes incorrect.
This should fix the roads in Qbit as well as the blocks in toybox.
2015-12-02 14:09:47 -08:00
Anthony J. Thibault
e2d9e37eb8
Fix for head offset for models with no eyes
...
This was causing in correct body poses while wearing an HMD.
2015-11-30 14:08:21 -08:00
Anthony J. Thibault
5072339a22
Warning fix
2015-11-25 14:04:01 -08:00
Anthony J. Thibault
23def8d173
Merge branch 'master' into tony/remove-joint-states
2015-11-25 13:55:23 -08:00
Anthony J. Thibault
97a2eb62d4
Fix for incorrect avatar bounds after changing avatars
2015-11-25 12:06:50 -08:00
Anthony J. Thibault
868cf83b48
Fix for attachments and MyAvatar::getDefaultEyePosition()
2015-11-25 10:07:29 -08:00
Anthony Thibault
527199bc69
Merge pull request #1 from AndrewMeadows/fix-avatar-capsule
...
compute bounding capsule of avatars
2015-11-25 09:39:18 -08:00
Andrew Meadows
2cc1dfe819
getRootAbsoluteBindPoseByChildName() is deprecated
2015-11-24 20:39:26 -08:00
Andrew Meadows
3ae082f09c
compute bounding capsule of avatars
2015-11-24 20:28:39 -08:00
Anthony J. Thibault
386dad7aff
Fixes hand IK for some avatars
...
Specifically:
https://hifi-content.s3.amazonaws.com/ozan/dev/avatars/hifi_team/ryan/_test/ryan.fst
https://hifi-content.s3.amazonaws.com/ozan/dev/avatars/hifi_team/brad/brad.fst
https://s3.amazonaws.com/hifi-public/tony/blackmery/blackmery.fst
These avatars have "Hips" joints that are NOT the root of the skeleton.
This would cause the getRootAbsoluteBindPoseByChildName() to return (0,0,0).
Causing the IK targets to be lower then they should have.
2015-11-24 18:57:35 -08:00
Anthony J. Thibault
76034d62d5
Eye tracking fixes
2015-11-24 16:57:26 -08:00
Anthony J. Thibault
f120e10ff4
Merge branch 'master' into tony/remove-joint-states
2015-11-24 15:00:05 -08:00
Anthony J. Thibault
e07e1c5c92
Fix for avatar eye tracking
...
When computing a full eye to world matrix, the translations need to be the geometry coordinate frame, not scaled into meters.
2015-11-24 14:01:01 -08:00
Anthony J. Thibault
14189ac909
Move Y_180 flip rotation out of Rig
...
This Y_180 flip is defined in skeletonModel not in the rig.
This is important if we wish to use the Rig for both Avatars (180 flip) and Entity models (no 180 flip).
We can hide this 180 flip from script, if we wish, by including it in all the accessors to and from
MyAvatar -> skeletalModel -> Rig.
Added Quaternions::Y_180 to GLMHelpers.
2015-11-23 19:31:27 -08:00
Anthony J. Thibault
8f46b8a765
Added USE_PRE_ROT_FROM_ANIM option to AnimClip
...
This will allow us in the future to pull preRotations from
animations instead of the model skeleton. It is disabled
by default because our current animations preRotations are
not correct for the left hand.
2015-11-23 15:58:18 -08:00
Anthony J. Thibault
8252bbed9b
AnimSkeleton: added pre rotation accessor methods
2015-11-23 13:50:14 -08:00
Anthony J. Thibault
db21db3cbc
Rig.h: more coordinate space comments
2015-11-22 16:34:06 -08:00
Anthony J. Thibault
dc169dc0aa
Rig.h: updated comments with coordinate spaces
2015-11-22 16:21:22 -08:00
Anthony J. Thibault
fe683edb66
Avatar Debug Draw Default Pose now works
2015-11-21 10:53:24 -08:00
Anthony J. Thibault
6cfd831a5a
Menu: Added Developer > Avatar > Debug Draw Position
...
Also renamed "Debug Draw Bind Pose" to "Debug Draw Default Pose"
2015-11-21 09:50:56 -08:00
Anthony J. Thibault
995958a8f0
Rig: normalized index bounds checking.
2015-11-20 18:45:53 -08:00
Anthony J. Thibault
54408a9c87
AnimVars are now in avatar/rig space
...
This makes it much simpler for code out side of the rig to manipulate AnimVars
* Removed mat4 type from AnimVars
* AnimVariantMap now has a _rigToGeometryTransform matrix
used to transform positions and rotations into the correct coordinate frame.
* Moved AnimPose code to extract a quat from a scaled matrix into GLMHelpers
2015-11-20 18:29:17 -08:00
Anthony J. Thibault
4f8cd6930d
Rig: Fixes for initializing _absolutePoses during initJointStates
2015-11-20 15:13:16 -08:00
Anthony J. Thibault
2f37335d77
Warning fixes
2015-11-20 14:50:42 -08:00
Anthony J. Thibault
30087ef0bd
Removed dead code
2015-11-20 14:37:53 -08:00
Anthony J. Thibault
cb89f09635
Removed EntityRig and AvatarRig. One Rig to rule them all.
2015-11-20 14:27:01 -08:00
Anthony J. Thibault
a77ea8da43
Removed JointStates! You won't be missed.
2015-11-20 14:15:37 -08:00
Anthony J. Thibault
a4116e633a
Removed last consumer of JointState class
...
Removed option to render IK constraints used by old animation system
2015-11-20 11:26:54 -08:00
Anthony J. Thibault
df7ca3bc38
Rig: getJointRotation and getJointTranslation use _relativePoses
2015-11-20 10:36:40 -08:00
Anthony J. Thibault
923d60e452
Rig: Bug fix for copyJointsIntoJointData
2015-11-20 10:30:12 -08:00
Anthony J. Thibault
ad4b8e0001
Avatar transmission fixes, moved JointData into shared
...
* Moved JointData into shared library
* added methods to the rig to copy into and out of JointData
* JointData translations must be in meters this is so the
fixed point compression wont overflow, also, it's a
consistent wire format.
2015-11-20 10:24:24 -08:00
Anthony J. Thibault
27685e0425
Bug fixes for other Avatar root translation
2015-11-20 09:33:57 -08:00
Anthony J. Thibault
c2ae6f0c8e
Fix for remote Avatar
...
Make sure to copy the correct data to and from AvatarData::JointData
2015-11-20 09:20:41 -08:00
Anthony J. Thibault
302b6f7e26
Mac and Debug build fixes
2015-11-19 18:28:15 -08:00
Anthony J. Thibault
9e36a79155
Rig: hooked up script overridePoses
2015-11-19 18:14:04 -08:00
Anthony J. Thibault
46d23a9f38
head IK and controller IK work again!
2015-11-19 17:30:56 -08:00
Anthony J. Thibault
982e2c06a9
Rig: Switched over to use AnimPoses instead of JointStates
...
* fixed debug rendering
* improved jointState/animPose diff detection code.
2015-11-19 12:14:04 -08:00
Anthony J. Thibault
721da29432
WIP checkpoint
...
* No longer normalizing scale in AnimSkeleton and AnimClip
This means graph is animating in 'geometry' coordinates
before unit scale is even applied. This is necessary to
properly work with both Avatar based models and ModelEntity
based models
Many things are broken.
* debug rendering (translations are x100)
* IK hand targets
* follow cam
* I did not even dare to try HMD mode
2015-11-18 18:47:33 -08:00
Anthony J. Thibault
b054ef1488
Rig: fixes for rigs used for ModelEntities.
2015-11-18 16:04:34 -08:00
Anthony J. Thibault
3a74d188b0
AnimSkeleton: Added default poses
2015-11-18 16:03:28 -08:00
Anthony J. Thibault
5ffef7f41a
AnimPose: bug fix for extracting rotations from matrices with large scale
2015-11-18 16:02:30 -08:00
Anthony J. Thibault
b481d7c73d
Merge branch 'master' into tony/remove-joint-states
2015-11-18 09:38:21 -08:00
Anthony J. Thibault
9a39da9050
new absolutePoses work for avatars, but not for model entities.
2015-11-17 18:53:38 -08:00
Anthony J. Thibault
e93b5c5838
Bug fixes for avatars with no eyes
...
Changed default eye position to 1.9 meters because
the hifi_team avatars are 2.0 meters tall.
Also, prevent array access with negative indices when eye bones are missing.
ಠ_ಠ
2015-11-17 14:02:27 -08:00
Anthony J. Thibault
80eb247b9c
WIP checkin
...
* AnimManipulator: added absolute and relative position and translation support
* Rig: added _overrideFlags and _overridePoses for script overrides.
2015-11-16 18:49:47 -08:00
U-GAPOS\andrew
6733767d8b
use animation state to compute bodyInSensorFrame
2015-11-13 16:39:40 -08:00
Anthony J. Thibault
e698d3c1e8
Isolate JointStates within the Rig class
...
Except for SkeletalModel::computeBounds() JointStates are now completly
encapsulated by the Rig. Now we can start using AnimPoses instead and
in parallel with the JointState implementation. Then we can assert that
they are identical, before removing JointStates.
This check in has many comments with the AJT tag.
Each one of these cases will need to be revisitied and fixed.
In particular // AJT: LEGACY will be used to enclose all code
in the Rig which manipulates the _jointState QVector.
2015-11-11 18:23:58 -08:00
Anthony J. Thibault
11440f92f4
Removed rig animations
...
* Deleted AnimationHandle class
* Removed enableAnimGraph and anableRigAnimations from Menu.
* Removed *some* references to old IK system.
But it is still used when computing collision bounding volumes
2015-11-11 15:32:57 -08:00
Anthony J. Thibault
56e96ed24c
Merge branch 'master' into tony/script-start-stop-anim
2015-11-11 11:33:24 -08:00
Anthony J. Thibault
e1d0a97807
Implemented MyAvatar.prefetchAnimation() JS method
2015-11-10 16:51:48 -08:00
Anthony J. Thibault
936c55a94e
New MyAvatar animation JS interface
...
JavaScript changes:
* removed MyAvatar.playAnimation
* removed MyAvatar.stopAnimation
* removed MyAVatar.getGetAnimationDetails
* removed MyAvatar.startAnimationByRole
* removed MyAvatar.stopAnimationByRole
* removed MyAVatar.getGetAnimationDetailsByRole
* removed MyAVatar.clearJointPriorities
* added MyAvatar.overrideAnimation(url, fps, loop, firstFrame, lastFrame)
* added MyAvatar.restoreAnimation()
* added MyAvatar.getAnimationRoles()
* added MyAvatar.overrideRoleAnimation(role, url, fps, loop, firstFrame, lastFrame)
* added MyAvatar.restoreRoleAnimation(role)
* added MyAvatar.prefetchAnimation(url)
* update kneel.js with new api.
* added theBird.js to test role override api.
C++ changes:
* Added getParent() and replaceChild() to AnimNode
* Added findByName() and traverse() to AnimNode
* Changed AnimStateMachine to hold nodes by childIndex instead of smart pointer.
This allows script to replace nodes dynamically via overrideRoleAnimation
2015-11-10 16:34:38 -08:00
Anthony J. Thibault
eacc2cae0c
WIP checkpoint
2015-11-09 18:36:23 -08:00
Anthony J. Thibault
af2b3bb9d5
MyAvatar: removed priority, hold and maskedJoints from playAnimation js call
2015-11-09 16:56:49 -08:00
U-GAPOS\andrew
390310f822
swap the order of checks
2015-11-09 14:15:09 -08:00
U-GAPOS\andrew
c07b97920e
fix for avatars created with blender
2015-11-09 14:11:45 -08:00
U-GAPOS\andrew
2716a9f2b4
fix IK for feet targets
2015-11-09 13:11:03 -08:00
Anthony J. Thibault
a0f21228f6
AnimGraph support for start and stop animation from JavaScript
...
Follows the same model as the existing startAnimation and stopAnimation calls.
See kneel.js for an example.
2015-11-09 12:19:01 -08:00
Howard Stearns
314c11e8d4
Make life easier for Sam.
2015-11-06 16:59:46 -08:00
Andrew Meadows
e410030dd9
Merge pull request #6320 from hyperlogic/tony/blender-avatar-ik-fix
...
IK fix for avatars exported from Blender
2015-11-06 15:00:25 -08:00
Anthony J. Thibault
20d95080f1
IK fix for avatars exported from Blender
...
This should fix the issue with the hips moving erratically when arm IK
is enabled. The main issue is that the IK system assumed that the "Hips"
joint was the root of the skeleton. For Blender avatar this is not the case
as it inserts an "Armature" node at the root instead.
2015-11-05 12:03:45 -08:00
Howard Stearns
aef8b7639d
Merge branch 'master' of https://github.com/highfidelity/hifi into away
2015-11-05 11:58:08 -08:00
Anthony J. Thibault
2318e48fa8
AvatarRig: fix for crash when index was -1
2015-11-05 09:43:41 -08:00
Anthony J. Thibault
431a108c35
Bugfixes to expression for !!x expressions
...
Added stub eval methods. only boolean not, boolean and, boolean or and unary minus
are implemented.
2015-11-04 20:13:17 -08:00
Anthony J. Thibault
04d8a598da
First step toward evaluation
...
* added OpCodes
* added first parser rules
* removed mat4 support from AnimVariantMap
2015-11-04 16:56:34 -08:00
Anthony J. Thibault
a80ab0003c
Removed vec literal values
2015-11-04 14:51:05 -08:00
Anthony J. Thibault
32c40d37c0
Removed vec literals tokens and renamed int and float token types
2015-11-04 14:51:05 -08:00
Anthony J. Thibault
4394083138
Added comma token
2015-11-04 14:51:05 -08:00
Anthony J. Thibault
7f0fc4f6eb
Added limited floating point support
2015-11-04 14:51:05 -08:00
Anthony J. Thibault
340096d457
Initial version of AnimExpression class with minimal tokenizer
2015-11-04 14:51:05 -08:00
Howard Stearns
94ae1ef638
Fix accumulateTime
2015-11-02 20:37:57 -08:00
Anthony J. Thibault
e3e759248f
Merge branch 'master' into tony/anim-sync-blend
2015-11-02 08:37:10 -08:00
Seth Alves
224aeea044
quiet compiler
2015-10-31 08:11:43 -07:00
Howard Stearns
eb9e54de41
Make AnimVariantXXX.xxx consistent.
2015-10-29 19:45:23 -07:00
Howard Stearns
d491ddc3d6
comment.
2015-10-29 19:43:57 -07:00
Howard Stearns
1918f1835c
Tolerate AnimVars that are float when we want int, and vice versa.
2015-10-29 19:37:13 -07:00
Howard Stearns
f7d558a252
comment
2015-10-29 19:26:54 -07:00
Howard Stearns
dcc173c93a
comment.
2015-10-29 19:21:24 -07:00
Howard Stearns
5d1ba90f1e
More readable code.
2015-10-29 19:18:34 -07:00
Howard Stearns
502cc7f580
Don't copy while converting.
2015-10-29 16:44:01 -07:00
Howard Stearns
303491817b
assert to get hard error in dev, warning and no-op in release.
2015-10-29 16:35:59 -07:00
Anthony J. Thibault
f7b6fab0c3
Merge branch 'master' into tony/anim-sync-blend
2015-10-29 11:35:48 -07:00
Howard Stearns
4083c5c71b
Handle wrapping of very long-lived sessions.
2015-10-29 10:31:36 -07:00
Howard Stearns
d79d0bc5c5
Merge branch 'master' of https://github.com/highfidelity/hifi into expose-anim-vars
2015-10-29 08:25:41 -07:00
Howard Stearns
697b9fb60b
Merge pull request #6205 from hyperlogic/tony/eye-lookat-fix
...
Fixes locally rendered eye gaze
2015-10-28 21:39:54 -07:00
Anthony J. Thibault
5e73af9272
Rig: Removed dt from updateFromEyeParameters()
2015-10-28 18:10:41 -07:00
Anthony J. Thibault
b3734b5ddb
Rig: removed redundant method updateEyeJoints()
...
Instead we call updateEyeJoint() twice, once for each eye.
2015-10-28 10:46:09 -07:00
Anthony J. Thibault
f9dc05c989
Rig::computeMotionAnimationState better filtering of small dt velocities.
...
Only update _lastVelocity when dt is sufficiently large.
2015-10-27 18:59:02 -07:00
Anthony J. Thibault
ae8938cadc
Fix for local eye tracking in AnimGraph
...
Also moved Rig::updateAnimations() now occurs after
Rig::updateFromHeadParameters() and Rig::updateFromHandParameters().
This should remove a frame of lag for head and hand IK targets.
Rig::updateFromEyeParameters() occurs after Rig::updateAnimations().
But now the eye JointStates are re-computed, this is the actual
fix for the local eye tracking issue.
2015-10-27 18:30:35 -07:00
Anthony J. Thibault
485e36d824
Bug fix for hand IK when using the Owen avatar.
...
The IK was assiming that the "Hips" bone index was always 0.
This was not the case for Owen. Now we lookup the Hips index
and cache it for use during the hipsOffset computation.
2015-10-26 17:17:46 -07:00
Howard Stearns
4b4907c9ef
Allow multiple scripts to register, and allow them to specify the specific anim vars they are interested in.
2015-10-26 10:04:55 -07:00
Howard Stearns
e11b0add9a
Update safety trampoline with correct arguments.
2015-10-24 15:29:49 -07:00
Anthony J. Thibault
06de087802
Filter out velocities computed from position delta if dt is small
...
While in the HMD, updates can occur with very small deltaTime values.
These this makes the position delta method of computing a velocity very
susceptible to noise and precision errors.
2015-10-23 18:27:20 -07:00
Anthony J. Thibault
e639d53139
Use #include<> for headers not in current working directory.
2015-10-23 08:55:38 -07:00
Howard Stearns
84cfeaec13
Linux QT wants .h-less headers.
2015-10-22 17:01:06 -07:00
howard-stearns
92ddedd44b
Make msvc happy.
2015-10-22 16:44:15 -07:00
Anthony J. Thibault
8689170415
Removed sync and timescale from AnimBlendLinear node.
...
AnimBlendLinearMove will now be used instead.
2015-10-22 16:40:53 -07:00
Anthony J. Thibault
a66f31bb20
Added AnimBlendLinearMove node
...
AnimBlendLinearMove is now in use by forward, backward and strafe movements.
Tuned rig moving average speeds to be more sensitive.
2015-10-22 16:33:31 -07:00
Howard Stearns
2b7ceffd64
Get rid of globalObject().property("MyAvatar").property("animationStateHandlerResult").
2015-10-22 16:23:09 -07:00
Howard Stearns
913842ac30
Thread check, for consistency.
2015-10-22 15:31:17 -07:00
Howard Stearns
ecc920199d
Return id suitable for use with remover, per comments.
2015-10-22 15:24:24 -07:00
Howard Stearns
1d0464ede5
Name change and thread checks per comments.
2015-10-22 15:15:10 -07:00
Howard Stearns
759e652506
Thread test per comments.
2015-10-22 15:13:14 -07:00
Howard Stearns
30429e8138
Don't use late-breaking results that got reported after the handler was removed.
2015-10-22 11:43:22 -07:00
Howard Stearns
b5ccd49959
Make ubuntu happy.
2015-10-22 11:42:50 -07:00
Howard Stearns
9fd61907f5
Call back to Javascript asynchronously, so that we don't block and the script's engine doesn't have thread conflicts.
2015-10-21 20:50:07 -07:00
Anthony J. Thibault
c83af43d0e
Added strafe and backward blending
2015-10-21 17:34:09 -07:00
Anthony J. Thibault
41cce4320a
Merge branch 'tony/anim-sync-blend' into test
2015-10-20 17:39:13 -07:00
Howard Stearns
3d2f00c609
Cleaner intgerface, including cleanup.
2015-10-20 17:01:45 -07:00
Anthony J. Thibault
5cd2786c1d
First pass at Rig timeScaling and blending between slow, walk and run.
2015-10-20 16:37:05 -07:00
Howard Stearns
4c6867bb9c
Merge branch 'master' of https://github.com/highfidelity/hifi into expose-anim-vars
2015-10-20 12:17:00 -07:00
Anthony J. Thibault
11f2d29bf8
AnimBlendLinear: bugfixes for sync flag added timeScale
2015-10-20 10:36:37 -07:00
Andrew Meadows
341bc3666f
Merge pull request #6093 from sethalves/hold-action-changes
...
Hold action changes
2015-10-20 09:19:48 -07:00
Howard Stearns
2213a4bb02
Do not set (just rightHand) anim var if a script has done so.
2015-10-19 20:09:48 -07:00
Anthony J. Thibault
073cec41c4
AnimClip & accumulateTime smoother looping anims
...
Looping animations should have an extra frame of interpolation between the start and end frames.
2015-10-19 15:49:52 -07:00
Anthony J. Thibault
9b9bd7fe26
AnimNodeLoader: Fix for crash condition
...
When a node with children had an error loading, it would
lead to a nullptr dereference.
2015-10-19 15:49:50 -07:00
Anthony J. Thibault
2b4788929f
AnimBlendLinear: Untested implementation of sync flag.
...
Move accumulateTime into AnimUtil.
2015-10-19 15:49:49 -07:00
Anthony J. Thibault
3716800b98
Moved AnimPose class into it's own set of files
2015-10-19 15:49:48 -07:00
Andrew Meadows
917bfbf64e
hack to reduce hand influence of hips in HMD mode
2015-10-19 15:19:32 -07:00
Howard Stearns
38a967ac54
Allow compiler after someone broke things.
2015-10-16 16:28:11 -07:00
Howard Stearns
91c2d31118
Merge branch 'master' of https://github.com/highfidelity/hifi into expose-anim-vars
2015-10-16 15:51:09 -07:00
Howard Stearns
f25cc93936
Initial prototype of exposing anim vars to javascript.
2015-10-16 10:48:36 -07:00
Seth Alves
462918ffcf
cleanups
2015-10-15 14:55:17 -07:00
Seth Alves
4903db45b1
give other avatars an anim-skeleton
2015-10-15 14:21:06 -07:00
Seth Alves
a70ba4cd5a
add some accessors
2015-10-15 11:42:53 -07:00
Anthony J. Thibault
e484a904a2
Rotate the avatar to align with the HMD while moving
...
MyAvatar: refactored updateFromHMDSensorMatrix() a bit by splitting it into several methods, because
it was getting quite large and becoming hard to follow.
* beginStraighteningLean() - can be called when we would like to trigger a re-centering action.
* shouldBeginStraighteningLean() - contains some of the logic to decide if we should begin a re-centering action.
for now it encapulates the capsule check.
* processStraighteningLean() - performs the actual re-centering calculation.
New code was added to MyAvatar::updateFromHMDSensorMatrix() to trigger re-centering when the avatar speed rises
over a threshold.
Secondly the Rig::computeMotionAnimationState() state machine for animGraph added a state change hysteresis
of 100ms. This hysteresis should help smooth over two issues.
1) When the delta position is 0, because the physics timestep was not evaluated.
2) During re-centering due to desired motion, the avatar velocity can fluctuate causing undesired animation state fluctuation.
2015-10-13 17:36:00 -07:00
Andrew Meadows
8ebdd25b71
more cleanup
2015-10-12 14:07:23 -07:00
Andrew Meadows
22786dea7d
cleanup
2015-10-12 13:35:26 -07:00
Andrew Meadows
44243aaa52
remove some debug code
2015-10-12 11:39:54 -07:00
U-GAPOS\andrew
f01847de14
experimental HMD hips tracking
2015-10-12 11:39:54 -07:00
Andrew Meadows
35d2a5b5ea
track tipRotation for HmdHead target
2015-10-12 11:39:54 -07:00
Andrew Meadows
5f1068c404
cleanup and optimization of IK loop
2015-10-12 11:39:54 -07:00
Andrew Meadows
6a96d5f0c5
don't bother to create targets with bad types
2015-10-12 11:39:54 -07:00
Andrew Meadows
bc48f70877
move IKTarget into its own files
2015-10-12 11:39:54 -07:00
Andrew Meadows
56f038d5a7
simpler logic for tracking hips offset
2015-10-12 11:39:54 -07:00
Andrew Meadows
03eaa95258
initial hip translation from IK
...
works for 2D 3rd person but probably not well for HMD
2015-10-12 11:39:54 -07:00
Brad Davis
6f5f6450df
Cleanup CMake files
2015-10-11 00:01:03 -07:00
Anthony J. Thibault
1c2f86f8b7
Fix for sending translation for non-animated joints.
...
Only the JointState._defaultTranslation needs to be multiplied
by the unitScale in JointState::translationIsDefault(). This
was incorrectly flagging some non-animated joints as animated.
2015-10-08 17:50:22 -07:00
Andrew Meadows
6c2a94fddb
remove unused method declarations
2015-10-07 14:17:21 -07:00
Brad Hefta-Gaub
7a85e5b7a7
rename frameIndex to currentFrame
2015-10-07 13:02:58 -07:00
Brad Hefta-Gaub
ef054ffc6d
Merge branch 'master' of https://github.com/highfidelity/hifi into animationGroupSettings
...
Conflicts:
libraries/networking/src/udt/PacketHeaders.cpp
libraries/networking/src/udt/PacketHeaders.h
2015-10-07 11:27:50 -07:00
Brad Hefta-Gaub
6eeb64b032
CR feedback
2015-10-07 11:23:24 -07:00
Andrew Meadows
224fc55033
put IK targets in skeleton's model-frame
2015-10-06 16:49:29 -07:00
Brad Hefta-Gaub
016bf4011d
cleanup
2015-10-06 16:07:36 -07:00
Brad Hefta-Gaub
1319642a59
fix frame jumping behavior on restart
2015-10-06 15:59:35 -07:00
Brad Hefta-Gaub
be79101a93
Merge branch 'master' of https://github.com/highfidelity/hifi into animationGroupSettings
2015-10-06 15:20:37 -07:00
Anthony J. Thibault
75849db867
Changed (float)fabs() to fabsf()
2015-10-05 12:00:02 -07:00
Brad Hefta-Gaub
f618a2adfa
gak - get streaming working again
2015-10-02 17:06:32 -07:00
Anthony J. Thibault
b6b57de1c6
animation lib warning fixes
2015-10-02 16:42:50 -07:00
Brad Hefta-Gaub
57bf69cc48
Merge branch 'master' of https://github.com/highfidelity/hifi into animationGroupSettings
...
Conflicts:
libraries/entities/src/ModelEntityItem.cpp
libraries/networking/src/udt/PacketHeaders.cpp
2015-10-02 14:19:15 -07:00
Brad Hefta-Gaub
02536a5ab9
remove animationSettings from particles, add isEmitting
2015-10-02 14:17:01 -07:00
Brad Hefta-Gaub
e6fb587a8c
Merge branch 'master' of https://github.com/highfidelity/hifi into animationGroupSettings
2015-10-02 13:04:14 -07:00
Brad Hefta-Gaub
b27396606b
fix first run
2015-10-02 12:34:46 -07:00
Anthony J. Thibault
c0be32d359
Fix for model offset when using Rig Animations.
2015-10-02 11:40:46 -07:00
Anthony J. Thibault
fc7b6dee84
Merge branch 'master' into transmit-joint-translation
2015-10-02 11:40:33 -07:00
Anthony J. Thibault
a1b54945d6
Compute the model offset in the rig, using the bind pose of the hips.
2015-10-02 10:34:34 -07:00
Brad Hefta-Gaub
cf2693e712
working fistFrame lastFrame
2015-10-02 08:31:22 -07:00
Anthony J. Thibault
fa864d29f9
Merge branch 'master' into transmit-joint-translation
2015-10-01 16:55:24 -07:00
Howard Stearns
53e7d5fd7c
Merge pull request #5975 from AndrewMeadows/cleanup-legacy-constraints
...
remove cruft relating to old verlet avatar skeleton simulation
2015-10-01 16:48:33 -07:00
Anthony J. Thibault
fe5ea471a1
AnimClip: read in translations from fbx file and pre-process them
...
Do the following things to the translations
1. scale by the model offset, this should move the translations into the correct units (meters).
2. compute the ratio between the bone length in the animation and the skeleton.
3. subtract the anim translation from the first translation frame in the animation
effectively turning it into a bind pose delta translation.
4. apply bone length ratio to the resulting delta.
5. set the final translation to be the skeleton rel bind pose + this scaled delta translation
2015-10-01 16:10:33 -07:00
Brad Hefta-Gaub
afe5075e10
Merge pull request #5971 from howard-stearns/AnimVariant-warning-squash
...
Squash compiler warning in AnimVariant.
2015-10-01 14:41:40 -07:00
Howard Stearns
739545794f
Merge pull request #5944 from AndrewMeadows/ik-repairs-007
...
fix bug: IK attenuates fast underpose animations
2015-10-01 14:27:21 -07:00
Andrew Meadows
09ac01a5e7
remove cruft from old verlet avatar simulation
2015-10-01 13:44:50 -07:00
Brad Hefta-Gaub
91a27e3adf
get animation to actually run again
2015-10-01 13:29:07 -07:00
Seth Alves
25cbebb66c
Merge branch 'transmit-joint-translation' of github.com:sethalves/hifi into transmit-joint-translation
2015-10-01 13:24:04 -07:00
Seth Alves
8453043038
remove unused variable
2015-10-01 13:23:51 -07:00
Brad Hefta-Gaub
aca25bd76e
connect up AnimationPropertyGroup to AnimationLoop
2015-10-01 11:05:16 -07:00
Howard Stearns
335d87134b
Squash compiler warning in AnimVariant.
2015-10-01 10:58:31 -07:00
Anthony J. Thibault
d993d39718
Bug fix for deriveBodyFromHMDSensor calculations
...
The calculation that determined where the body position relative to the HMD
was incorrect, one of the components was in the wrong coordinate frame.
Now use the skeleton's bind pose to compute the proper avatar offsets for the eyes, neck and hips.
Use these offsets to calculate where the hips should be given a specific hmd position and orientation.
Also, added a bug fix for Rig, which would cause a -1 index deference when an avatar was missing
certain named joints, such as, "LeftEye", "Neck" and "Head".
2015-09-30 16:28:33 -07:00
Andrew Meadows
b192d0a9cd
make neck IK target type same as head
2015-09-29 17:39:17 -07:00
Anthony J. Thibault
5e2279ed4b
AnimManipulator: Don't read defaultAbsPose.trans anim var.
...
At the moment the manipulator only supports rotations.
2015-09-29 16:37:43 -07:00
Andrew Meadows
a052f5e125
remove commented out debug line
2015-09-29 16:21:08 -07:00
Andrew Meadows
cdae16e07b
fix bug: IK attenuates fast underpose animations
2015-09-29 16:11:27 -07:00
Howard Stearns
745a59af1c
Default animation is anim graph.
...
Remove state change logging from animation graph state machine.
2015-09-29 12:48:57 -07:00
Seth Alves
4179e4aa74
merge from upstream
2015-09-28 15:28:10 -07:00
Seth Alves
04eed64c7c
fix bug in JointState::translationIsDefault
2015-09-28 15:26:32 -07:00
Anthony J. Thibault
a495a45ed0
unset "lean" when headParams.enableLean is false
...
Also added AnimVariantMap::dump() which will print out all the
currently set anim vars and their values.
2015-09-28 11:10:22 -07:00
Anthony J. Thibault
c970ff0c0c
Reset joint priorities back to 0 for new animation system.
...
Added Rig::clearJointStatePriorities() to do this.
2015-09-27 18:25:28 -07:00
Anthony J. Thibault
4b31d87bf5
renamed magic constant to FRAMES_PER_SECOND.
2015-09-27 17:52:53 -07:00
Anthony J. Thibault
5a24a020ca
Fix for HMD rotation sticking between 2d & HMD mode
...
The main fix for this was to set the JointState animation priority to 3.0
The secondary fix was only noticed when we changed the animation priority
Basically, the debugRendering was using the JointStates after they were
manipulated by SkeletonModel to 'relax' them toward thier default pose for
IK purposes.
2015-09-27 17:44:54 -07:00
Anthony J. Thibault
a2562c92f4
Small changes to Anim System for Debugging
...
* Added constant for Rig animation fade time
* Added index output for AnimSkeleton::dump()
2015-09-27 16:24:55 -07:00
Seth Alves
50dd8eba45
Relay joint translations across network. Apply animation's root-joint translation to avatar.
2015-09-26 11:40:39 -07:00
Andrew Meadows
a97f556958
enforce IK target rotation
2015-09-25 15:13:57 -07:00
Howard Stearns
266c69fc70
Disable the old-school Rig::inverseKinematics during reset.
2015-09-24 15:33:52 -07:00
Andrew Meadows
59da684eb9
make IKTarget::setType() a one-liner
2015-09-24 13:15:03 -07:00
Andrew Meadows
17e3e9394f
allow head translation for 3rd person screenie IK
2015-09-24 12:38:46 -07:00
Brad Hefta-Gaub
5e82b9c433
more warning fixes
2015-09-24 08:26:56 -07:00
Anthony J. Thibault
6b47373bcb
Fix for precision error in AnimPose(glm::mat4) constructor.
...
Really the culprit is GLMHelpers extractRotation().
I have a separate unit test that demonstrates the bug.
2015-09-23 15:38:56 -07:00
Anthony J. Thibault
a454584496
Updated default avatar-animation.json
2015-09-23 10:59:52 -07:00
Anthony J. Thibault
a9848cd157
Merge branch 'master' into tony/lean-threshold
2015-09-23 10:54:12 -07:00
Anthony J. Thibault
9ce43a57f1
Better head IK when in an HMD.
...
Because the current IK system doesn't quite handle what we need
for the head and neck IK, we do it procedurally in the rig, and
manually set both neck and head IK targets.
2015-09-22 19:58:21 -07:00
Anthony J. Thibault
d53295655f
Fixes for empty poses
...
This can happen when an animation is evaluated before it is finished loading.
2015-09-22 19:54:51 -07:00
Andrew Meadows
d25ba8946e
fix animation attenuation from IK relaxation step
2015-09-22 17:20:26 -07:00
Howard Stearns
7e52d38870
Don't include the root rot, because it seems that this is already accounted for in the head params.
...
Restore the hmd conditional on setting head position. This had been removed when failing to pin it cause lean.
I believe that lean was being caused by coordinate system issues that are now addressed by the above and Andrew's big cleanup.
2015-09-22 10:12:59 -07:00
Howard Stearns
8f1dde69cc
Always keep targets, even when both position and rotation are unset. (Get from underpose.)
...
Filtering these was necessary before when the underpose coordinate was wrong, but now that we have that working, there shouldn't be any need to filter.
2015-09-22 10:10:29 -07:00
Andrew Meadows
3869887610
splitting AnimNode implementation into two files
2015-09-21 17:53:59 -07:00
Andrew Meadows
e6776ef5eb
split AnimIK::evaluate() into sub-functions
...
also IK targets now in model-frame instead of root-frame
2015-09-21 17:29:39 -07:00
Anthony J. Thibault
eadf212418
Updated avatar.json with talking idle animation.
2015-09-18 18:31:53 -07:00
Anthony J. Thibault
44eb448cbe
Hooked up isTalking flag to Rig and AnimGraph.
2015-09-18 18:05:51 -07:00
Andrew Meadows
07f3abfc91
fix bugs
2015-09-18 12:01:23 -07:00
Andrew Meadows
4cb2249cda
premature optimization: remove another branch
2015-09-18 10:16:19 -07:00
Andrew Meadows
a85afb5280
simplify logic of RotationAccumulator::add()
2015-09-18 10:13:21 -07:00
Andrew Meadows
6ed0a57d9f
avoid unecessary computation of last absolutePose
2015-09-18 10:09:23 -07:00
Andrew Meadows
9e94e7f1d0
less complicated RotationAccumulator
2015-09-18 07:11:36 -07:00
Andrew Meadows
b6a153d926
split RotationAccumulator into its own files
2015-09-17 22:30:44 -07:00
Andrew Meadows
420acde720
blend IK effects between distinct end effectors
2015-09-17 22:11:59 -07:00
Andrew Meadows
4505d5999c
route hand data differently for new Anim system
2015-09-17 16:04:00 -07:00
Andrew Meadows
9746d31f5e
notes for moving hand updates
2015-09-17 16:04:00 -07:00
Anthony J. Thibault
bef136d811
AnimGraph: prefer QString over std::string
2015-09-17 11:21:14 -07:00
Andrew Meadows
e1fc1900ab
remove IK 'flutter' bug
2015-09-16 17:02:12 -07:00
Andrew Meadows
d4ea661aca
cleanup whitespace
2015-09-16 17:02:12 -07:00
Andrew Meadows
9a86fc2e62
build local list of IK targets every frame
2015-09-16 17:02:12 -07:00
Andrew Meadows
089c719612
minor cleanup
2015-09-16 17:02:12 -07:00
Anthony J. Thibault
5aeebba90e
Renamed AnimController to AnimManipulator, Removed offsets on IK targets
2015-09-16 15:49:47 -07:00
Anthony J. Thibault
fae4b08eb0
AnimController Node Bug fixes
...
AnimController: proper support for alpha
AnimController: bug fix for translation.
AnimOverlay: renamed local var when building hand boneSets from head to hand.
2015-09-16 15:11:53 -07:00
Howard Stearns
f6b5f3925a
Place head at requested position in all modes. (At least, until we can figure out how to get underpose position cleanly without tilt.)
2015-09-15 16:43:52 -07:00
Howard Stearns
848bb4fccb
Merge pull request #5813 from hyperlogic/tony/anim-hand-state-machines
...
Added point and grab support to the AnimGraph
2015-09-15 15:47:19 -07:00
Anthony J. Thibault
1948829ca8
Improved state machine for right hand.
...
The hand state machine has the following features
* There's a idle to point animation, followed by a looping point hold state.
* There's a point to idle animation.
* The grab state is composed of a linear blend between an open and closed pose.
Additionally the C++ code will ramp on the left and right hand overlays,
This allows the fingers to be animated normally when the user is not actively
pointing or grabbing.
2015-09-15 15:09:08 -07:00
Clément Brisset
cb1b70820a
Merge pull request #5801 from AndrewMeadows/fix-animation-tests
...
fix animation unit tests
2015-09-15 17:53:06 +02:00
Anthony J. Thibault
90f46ba2c8
Added hand state machines to AnimGraph.
...
* Application: Forward trigger values to the MyAvatar's PalmData
* SkeletonModel: Pass PalmData to Rig via updateRigFromHandData() this is more explicit then
the Rig::inverseKinematics methods.
* AnimNodeLoader & AnimOverlay: add support for LeftHand and RightHand bone sets
* Rig::updateRigFromHandData() read the triggers and set stateMachine trigger vars
* avatar.json - udpated with new hand state machine with temporary animations
2015-09-14 18:54:12 -07:00
Andrew Meadows
d74628720f
fix bug using unitialized std::vector elements
2015-09-14 17:14:04 -07:00
Andrew Meadows
75ec142827
fix animation-tests
2015-09-14 16:42:57 -07:00
Andrew Meadows
a72199a7df
minor IK tuning
2015-09-14 14:44:17 -07:00
Howard Stearns
4ffe2d0747
Merge pull request #5786 from AndrewMeadows/ik-with-constraints
...
inverse kinematics works with rotation constraints
2015-09-11 17:34:50 -07:00
Andrew Meadows
1500a36f72
oops forgot to uncomment constraint initialization
2015-09-11 16:49:49 -07:00
Howard Stearns
140ecc8e2c
Get rid of implicit int->bool cast.
2015-09-11 16:28:41 -07:00
Andrew Meadows
d01c5d1ae5
fix crash bug
2015-09-11 15:01:31 -07:00
Andrew Meadows
2ba446d309
fix IK and constriants
2015-09-11 13:22:12 -07:00
Andrew Meadows
b0520acea9
remove warning about out-of-order-init
2015-09-11 13:22:11 -07:00
Howard Stearns
5314e0c744
Remove unused.
2015-09-11 13:20:56 -07:00
Howard Stearns
02fba12a48
Merge branch 'master' of https://github.com/highfidelity/hifi into rationalize-rig-settings
2015-09-11 11:53:19 -07:00
Howard Stearns
67ce0966d1
Rationalize the rig state setters.
2015-09-11 11:52:20 -07:00
Anthony J. Thibault
8e504e63b0
Removed unused variable, changed glm::vec3(0) to glm::vec3()
2015-09-11 10:43:49 -07:00
Anthony J. Thibault
7996a02bd8
Added head target to AnimGraph IK node.
...
* In HMD mode head orientation and position is set.
* When not in HMD only orientation is set, position should
default to the underlying pose position.
2015-09-11 09:48:48 -07:00
Anthony J. Thibault
9a9838fd0d
Clean up of AnimNodeLoader after merge from master.
2015-09-10 11:47:41 -07:00
Anthony J. Thibault
663e37da66
Merge branch 'master' into tony/ik-and-controllers
2015-09-10 11:37:47 -07:00
Anthony Thibault
e8ede3ad00
Merge pull request #5731 from ChristophHaag/master
...
build fixes
2015-09-10 11:36:45 -07:00
Anthony J. Thibault
3149baeefc
Merge branch 'master' into tony/ik-and-controllers
2015-09-10 11:04:31 -07:00
Anthony J. Thibault
09b2d8e4a4
Seed AnimGraph with hand controller position and orientation.
2015-09-09 18:16:57 -07:00
Anthony J. Thibault
ad49d0dd59
AnimInverseKinematics: update _maxTargetIndex correctly.
2015-09-09 16:09:38 -07:00
Anthony J. Thibault
756eb54a0a
AnimNodeLoader support for InverseKinematics node.
2015-09-09 15:28:21 -07:00
Anthony J. Thibault
c1d7287652
AnimController node now takes absolute rotation vars, instead of relative.
2015-09-09 12:24:32 -07:00
Howard Stearns
f818ac2b74
Merge pull request #5744 from hyperlogic/tony/enable-lean-flag
...
Added a flag to enable and disable lean.
2015-09-09 10:18:12 -07:00
Anthony J. Thibault
146836452f
Merge remote-tracking branch 'andrew/europium' into tony/ik-and-controllers
2015-09-09 09:40:55 -07:00
Howard Stearns
74c92af8e0
Merge pull request #5741 from AndrewMeadows/brokenCapsules
...
fix for bad bounding capsules for avatars
2015-09-09 09:33:57 -07:00
Anthony J. Thibault
39aef6edc9
AnimController fix for crash if underPoses vector was empty.
2015-09-08 21:42:42 -07:00
Anthony J. Thibault
75ecf0020d
WIP commit, added AnimController node.
2015-09-08 20:34:21 -07:00
Andrew Meadows
e86e760118
remove debug stuff and nerfed constriants
2015-09-08 19:14:31 -07:00
Andrew Meadows
381828dac3
remove hackery for bad length units in AnimSkeleton
2015-09-08 19:02:16 -07:00
Andrew Meadows
ee265aba4a
add AnimInverseKinematics class
2015-09-08 18:20:22 -07:00
Andrew Meadows
3d661095dc
fix some bugs in RotationConstraints
2015-09-08 18:20:03 -07:00
Andrew Meadows
b6cef3d1a9
fix Qt includes
2015-09-08 18:19:33 -07:00
Andrew Meadows
00c446d1b0
sort includes
2015-09-08 18:19:18 -07:00
Andrew Meadows
c3e16d33c1
add InverseKinematics type
2015-09-08 18:18:50 -07:00
Seth Alves
e06461ea15
Merge pull request #5724 from hyperlogic/tony/anim-debug-draw-improvements
...
AnimDebugDraw Improvements
2015-09-08 17:07:51 -07:00
Anthony J. Thibault
387d50c217
Added a flag to enable and disable lean.
...
This should help improve our idle and walk animations, because
animation on the "lean" joint was being lost, even when we did
not require procedural leaning.
2015-09-08 16:35:06 -07:00
Stephen Birarda
c670c9a0d5
fix for AnimNodeLoader use of Resource loaded
2015-09-08 15:31:37 -07:00
Andrew Meadows
4a40781e2f
remove some commented out cruft
2015-09-08 15:11:19 -07:00
Andrew Meadows
281e4f21fc
fix avatar bounding capsule calculations
2015-09-08 15:03:12 -07:00
Andrew Meadows
90fe54e6d6
remove cruft and minor cleanup
2015-09-08 15:03:12 -07:00
Anthony J. Thibault
6d5927c0c9
Now with less copies.
...
* AnimSkeleton now returns AnimPoses by const ref.
* AnimDebugDraw: uses references to Poses on the stack instead of copies
within inner loops.
* AnimDebugDraw: Removed unnecessary universal refs in range based for loops.
2015-09-08 10:51:23 -07:00
Christoph Haag
ddcee763ca
extend macros to take return value if necessary
2015-09-08 19:10:15 +02:00
Stephen Birarda
25aeda2e18
Merge branch 'master' of https://github.com/highfidelity/hifi into protocol
2015-09-08 08:40:51 -07:00
Christoph Haag
fa221fa7e3
In gcc5 nullptr can't be directly used as bool
...
See https://gcc.gnu.org/gcc-5/porting_to.html
"Converting std::nullptr_t to bool"
2015-09-08 10:07:06 +02:00
Anthony J. Thibault
bb5d061d78
linux and mac compile fixes.
...
Removed "friend MyAvatar" from Rig and JointState.
This was only there for debugging, but I accidentally committed it.
2015-09-04 16:17:35 -07:00
Anthony J. Thibault
69e463bbfd
AnimDebugDraw Improvements
...
* Now always works, regardless of whether or not Rig or AnimGraph animations
are enabled.
* Changed joint radius to 1 cm.
* Changed xyz axis length to 4 cm.
2015-09-04 16:01:05 -07:00
Howard Stearns
086afc47b1
Avatar animations on by default. (Using the now old animation machinery.)
...
Default robot avatar consistent with the animations.
Don't require all the bones to be present.
2015-09-04 14:24:37 -07:00
Stephen Birarda
ed19987b7d
resolve conflicts on merge with upstream/master
2015-09-04 12:31:46 -06:00
Anthony J. Thibault
3f258c89b4
Fix transition from AG+Rig to AG only.
2015-09-04 11:03:59 -07:00
Anthony J. Thibault
dcecd7b73a
Added hysteresis to the state machine for turning and moving states.
...
This should help a bit with the jerkiness, as state transitions
occur less often due to noise or the user straddling the boundary
between two states.
2015-09-03 19:13:39 -07:00
Anthony J. Thibault
85cb503152
Made Enable Anim Graph menu option dynamic.
...
It will load the anim graph when enabled and destroy
the anim graph when disabled.
2015-09-03 14:46:44 -07:00
Anthony J. Thibault
30264e9c3d
Added animation debug draw items to menu.
...
* Debug Draw Bind Pose - used to display the current avatar's bind pose
* Debug Draw Animation - used to display the current avatar's AnimGraph animation.
Currently does not work with old animation so it's only valid when Enable Anim Graph is true.
* Draw Mesh - used to hide or display the avatar mesh.
2015-09-02 21:04:29 -07:00
Anthony J. Thibault
471400e595
Fix for jerky behavior when positionDelta is zero.
...
This can occur with vsync disabled. Possibly due to two avatar updates occurring
within a single physics time-step.
2015-09-02 19:59:05 -07:00
Anthony J. Thibault
de31b92fd5
Merge branch 'master' into ajt/new-anim-system
2015-09-02 17:53:56 -07:00
Anthony J. Thibault
46b3a7fd23
Improved default avatar.json state machine.
...
Now triggers 7 states.
Idle, WalkFwd, WalkBwd, StrafeLeft, StrafeRight, TurnLeft & TurnRight.
As well as variable speed walking to match current velocity.
2015-09-02 17:28:06 -07:00
Howard Stearns
389e752b6e
Merge pull request #5695 from AndrewMeadows/dysprosium
...
avoid bad joints when computing avatar bounding capsule
2015-09-02 15:58:42 -07:00
Anthony J. Thibault
99586f259c
Renamed bindTransformIsValid to bindTransformFoundInCluster
2015-09-02 13:44:34 -07:00
Anthony J. Thibault
91fbbf7d4e
Updated copyright boiler plate.
2015-09-02 13:35:26 -07:00
Anthony J. Thibault
df26f18222
Fix for compilation errors on linux
2015-09-02 13:29:29 -07:00
Anthony J. Thibault
fea030b9a0
Compile and warning fixes for MacOSX.
2015-09-02 12:18:17 -07:00
Anthony J. Thibault
1ae22268ac
Added comment to AnimStateMachine header.
2015-09-02 11:04:52 -07:00
Seth Alves
3e11852845
Merge pull request #5685 from howard-stearns/standing-hmd-animations
...
Standing hmd animations
2015-09-02 10:57:45 -07:00
Anthony J. Thibault
d151474446
Merge branch 'master' into ajt/new-anim-system
2015-09-02 10:00:36 -07:00
Anthony J. Thibault
7b4cb8655c
First pass integration of new anim system into rig.
2015-09-01 17:57:01 -07:00
Andrew Meadows
4a7a384c65
avoid bad joints when computing bounding capsule
2015-09-01 14:12:14 -07:00
Stephen Birarda
33f6933544
Merge branch 'master' of https://github.com/highfidelity/hifi into protocol
2015-09-01 14:36:16 -06:00
Andrew Meadows
7410baedf0
merge highfidelity/master into andrew/copernicium
...
Conflicts:
interface/src/avatar/SkeletonModel.cpp
libraries/animation/src/Rig.cpp
libraries/animation/src/Rig.h
2015-09-01 11:08:01 -07:00
Anthony J. Thibault
2401e6cc4b
Merge branch 'master' into ajt/new-anim-system
2015-09-01 10:58:38 -07:00
Andrew Meadows
47c18fa18a
reduced gravity effect in IK
2015-09-01 09:51:14 -07:00
Andrew Meadows
0e5b357362
revert unintended change to "gravity" term in IK
2015-09-01 09:51:14 -07:00
Andrew Meadows
bdcc68ce36
fix bug: allow IK to iterate more than once
...
also changed name of parentTransform to be rootTransform
for more correctness
2015-09-01 09:51:14 -07:00
Andrew Meadows
bb63267e30
fix hand IK rotations or all models
2015-09-01 09:45:14 -07:00
Anthony J. Thibault
0d98ab3365
Normalize scale on AnimSkeleton bind pose.
2015-08-31 17:27:23 -07:00
Anthony J. Thibault
9786954585
Added support for onDone and onLoop triggers.
2015-08-31 12:13:05 -07:00
Howard Stearns
2dbfa5ce9f
Be more uniform in deciding animation movement, and incorporate HMD standing mode (which sets position, but not velocity).
2015-08-31 11:10:05 -07:00
Howard Stearns
a907c5757b
Do not reset animation frame when restarting while we're fading out.
...
Keeps it smooth if we're oscillating on some theshold between running and not.)
2015-08-31 11:09:28 -07:00
Anthony J. Thibault
77b857031b
Take timeScale into account during interps & setCurrentFrame()
2015-08-31 11:01:15 -07:00
Anthony J. Thibault
54aa0677f6
Merge branch 'master' into ajt/new-anim-system
2015-08-31 10:47:50 -07:00
Anthony J. Thibault
9d983e0614
Bug fix to AnimNode::setSkeletonModel and AnimNodeLoader.
...
Also updated avatar.json to test nested graphs under a SM.
2015-08-28 17:16:32 -07:00
Anthony J. Thibault
19e91bb392
Added basic interpolation support to AnimStateMachine
2015-08-27 21:26:31 -07:00
Anthony J. Thibault
3286a32afc
Initial version of AnimStateMachine.
...
No interpolation support, but basic avatar.json is working
with two states and two transitions between them.
2015-08-27 20:41:53 -07:00
Andrew Meadows
d3f06af892
remove PhysicsEntity class
2015-08-27 18:22:12 -07:00
Stephen Birarda
80cf7b6c76
resolve conflicts on merge with upstream/master
2015-08-27 14:50:04 -07:00
Howard Stearns
96c74ebbd5
Enable Rig Animations is now a developer menu item (rather than requiring javascript to set). Also turning it off resets you to bind pose and deliberately throws away old animations.
...
Default animations are the new ones for our standard T-pose. (Had been for the double-A pose fightbot.)
Rig state machine now does "backup", and doesn't apply strafe while turning.
2015-08-27 12:25:40 -07:00
Anthony J. Thibault
637e3b0a15
Added triggers to AnimVariantMap.
2015-08-27 10:41:01 -07:00
Anthony J. Thibault
a04f356857
Merge branch 'master' into ajt/new-anim-system
2015-08-27 09:32:53 -07:00
Anthony J. Thibault
b7a9b54628
Better AnimDebugDraw rendering
2015-08-26 16:42:08 -07:00
Ryan Huffman
aa7d8678e1
Merge branch 'protocol' of github.com:birarda/hifi into atp-server
2015-08-26 12:26:11 -07:00
Seth Alves
695ffa29c7
call setup_memory_debugger from common macros rather than from every CMakeLists.txt file
2015-08-26 11:09:59 -07:00
Anthony J. Thibault
46c1e008bc
Merge branch 'master' into ajt/new-anim-system
2015-08-26 10:37:39 -07:00
Anthony J. Thibault
0c02a338f2
Added support for setting Variants in the json file.
...
For example: the avatar.json file was updated to use the "sine" Variant
to drive the Overlay alpha parameter.
2015-08-25 20:57:01 -07:00
Anthony J. Thibault
4abf0cbd63
AnimVariantMap is used in eval, MyAvatar loads avatar.json via url
2015-08-25 20:28:17 -07:00
Brad Davis
d311e4f2ea
Fixing problems reported by static analysis tool
2015-08-25 19:18:55 -07:00
Anthony J. Thibault
496c706bba
Added AnimVariantMap argument to evaluate.
2015-08-25 11:59:24 -07:00
Anthony J. Thibault
62f86e6a46
Added AnimVariant, renamed AnimClipTests to AnimTests.
...
* Added test for AnimVariant.
2015-08-25 11:33:57 -07:00
Anthony J. Thibault
4bdb00bbc5
Added setCurrentFrame interface to AnimClip.
...
This will recurse the tree and call setCurrentFrameInternal on each node.
This method can be overriden, currently the only meaningful implementation is AnimClip.
2015-08-25 09:58:36 -07:00
Anthony J. Thibault
7a2ca047cb
Added network resource download support to AnimNodeLoader.
2015-08-24 19:00:12 -07:00
Anthony J. Thibault
5a73aef1f8
AnimSkeleton more accurate bind pose generation.
2015-08-24 16:19:16 -07:00
Anthony J. Thibault
fa5256eefd
Merge branch 'master' into ajt/new-anim-system
2015-08-24 14:32:28 -07:00
Anthony J. Thibault
80d3ae68c2
Removed redundant ends with ‘fbx’ check.
2015-08-21 22:11:53 -07:00
Anthony J. Thibault
b7009b4631
Fix for animation resources
...
The problem was that the invokeMethod between the AnimationReader thread
and the main thread was failing, because FBXGeometry* wasn't a registered meta type.
So, I ended up normalizing the AnimationReader class to be more like GeometryReader,
in that it uses singles and slots to communicate success and failure, rather then
invokeMethod.
2015-08-21 16:09:06 -07:00
Brad Davis
c3991dbb8c
Merge pull request #5622 from hyperlogic/ajt/network-geometry-refactor
...
ResourceCache, NetworkGeometry and Model refactoring and optimizations.
2015-08-20 23:57:16 -07:00
Anthony J. Thibault
1b3d7fabc8
ResourceCache, NetworkGeometry and Model refactoring and optimizations.
...
* Removed validation logic from Resource class, Qt does this internally and is more
standards compliant. This should result in more accurate caching and faster resource
fetching when cache is stale and validation fails.
* Added loaded and failed slots to Resource class, so it does not have to be polled.
* NetworkGeometry now uses multiple Resource objects to download
the fst/mapping file and the fbx/obj models.
* NetworkGeometry is no longer a subclass of Resource
* NetworkGeometry now has signals for success and failure, you no longer
have to poll it to determine when loading is complete (except for textures *sigh*)
Some functionality was removed
* NetworkGeometry no longer has a fallback
* NetworkGeometry no longer loads LODs or has lod logic.
* The number of FBXGeometry copies is greatly reduced.
* Model::setURL no supports fallback URL, delayLoad or retainCurrent option.
This can result in a pop when switching avatars, and there's no longer a default
if avatar loading fails.
2015-08-20 18:59:51 -07:00
Seth Alves
c25082d86f
use -fsanitize=address in all code rather than just the top-level links
2015-08-20 10:14:16 -07:00
Ryan Huffman
5884fcb17b
Merge branch 'ordered-sending' into atp-server
2015-08-19 12:23:31 -07:00
Ryan Huffman
51d4cf84da
Fix AnimationReader to work with new ResourceCache updates
2015-08-19 12:10:47 -07:00
Philip Rosedale
01108bdf6b
Merge pull request #5573 from howard-stearns/sync-eyes-and-vectors
...
Synchronize eye joint and debugging vectors
2015-08-17 16:56:01 -07:00
Howard Stearns
d28c555a79
Synchronize eye joint and debugging vectors when the other avatar is looking at me.
2015-08-14 16:47:34 -07:00
Andrew Meadows
488f6aa7d8
fix bug in ElbowConstraint::apply()
2015-08-12 13:34:23 -07:00
Howard Stearns
295d655eec
Merge pull request #5545 from AndrewMeadows/chlorine
...
rotation constraints in preparation for inverse kinematics
2015-08-11 09:19:16 -07:00
Andrew Meadows
8e82e48f76
remove more std::max/min favor of glm utilities
2015-08-11 08:17:54 -07:00
Andrew Meadows
a38c1c82d1
use glm::clamp() instead if std::max() and min()
2015-08-10 23:08:36 -07:00
Andrew Meadows
80b36f9f12
fix typo
2015-08-10 15:11:00 -07:00