Feature #131
closedsave/copy character animations
0%
Description
Character has a number of AnimationGroups, each contains a number of TargetedAnimations.
Each TargetedAnimation contains an Animation and a target, and the target is a TransformNode associated to a Bone.
Avatar class contains names all known bones in bonesProcessed array, and Skeleton class has getBoneIndexByName method.
That's not sufficient information to map these to Avatar.body structure, e.g. recognize that a specific animation targets right leg.
But once that's in place, a partial animation group from any character can be applied to any other character.
Bones that aren't recognized won't be animated, but we need to see how it looks like.
It's easier of course when a rig is known, e.g. ready player me avatars have the same rig, so animations can be easily applied to any character, and in full, without any skeleton analysis. But there's no animations for these avatars available.
They do support mixamo animations: https://docs.readyplayer.me/ready-player-me/integration-guides/unreal-engine-4/mixamo-animations
So there's two use cases: skeleton matches exactly, or does not.
Thus, whatever we save, has to include original Bone/TransformNode name, and optional identified bone info.
Avatar.processAnimations() method is starting point, currently used only in avatar-test.html.