“What I’m missing are some guidelines on how to make skeleton compatibility work.” No problem, I can recreate the exact issue you’re having with Manny and the UEFN Mannequin that we use in the Gameplay Animation Sample and walk you through each of your questions, as well as what steps you can take to get your animation playing as well as it can.
How can we tell it that the animation is authored for a different reference pose?
The only way you can tell this is by checking what skeleton is associated with the asset. In the context of code, this is the Skeleton property of an animation, where you can fetch the ref pose.
Specifying compatible skeletons?
When you specify that two skeletons are compatible, you are saying that two separate skeleton assets (closed animation source ecosystems) can share animations and animblueprints. This can be one-directional or bidirectional.
Specifying retarget sources? Again, this option seems to be only for matching skeletons?
This section has largely been deprecated in favour of the IK retargetting setup, but say you have masculine and feminine meshes that use the same skeleton asset as a base, but they have different ref poses. In this case, let’s say that the skeleton’s ref pose is the masculine body type. You can specify that the feminine body type is a retarget source. Then in the animation asset, there is a property called retarget source that, when changed to that body type, will use that ref pose to apply the animation against. In this way, you can author animations for the feminine body type and have them still play against its proportions properly while having the one source skeleton.
Translation retargeting in the skeleton asset, which options should we choose here? Should we change them for SkeletonA, B or both?
Generally, you would change these for Skeleton B if Skeleton A is the source for all of your animation work.
Given those, a strategy that I’ve taken when dealing with the translation retargetting as follows:
- I recommend turning on the “Non-Retargeted Animation” option in your skeletal mesh viewport. In the screenshot below, this has the translation retarget options set to skeleton, which means that only rotational data from the animation is coming through. You can see the extreme delta from the source animation to Manny.
[Image Removed]
- Because leaving anything set as animation means that it will play the animation based off the ref pose of the skeleton as is. Typically that means we leave the root bone or any positionally important bone as such. Attach bones, IK target bones. Those should probably stay as animation.
- For the most part, we want to use **animation scaled,**which takes into account the distance between this bone and its parent in its ref pose and scales the animation translation appropriately. Using this setting through the arms, you’ll get a delta like this. Notice that the pose differences are generally stable, and the distance between the arm and the torso is pretty good. It’s important to take into account your bind pose, if there are large differences in rotation, you can still have some issues.
[Image Removed]
- The fingers and twist bones will probably not be working well still, this indicates that both the translational and orientation deltas between the skeletons are pretty vast and are typical for hands. For the twist bones case on Manny, where you can match the translations, but the orientation differences are the main issue, I would recommend that you either adjust the orientation on the skeleton B to match skeleton A, or you will need to use something like a control rig twist setup. (The first image is with animation scaled, the second is what the normal pose should look like, but because we’ve modified the pose through the hierarchy, the retargeted orientations are going to be wrong)
[Image Removed]
- Then for the fingers, you need to go through each bone and choose an option that best fits against the animation your are trying to play. In the case of the example I’m using, I chose animation relative for the metacarpals, meaning we apply the rotation as an additive to whatever the translational position of the bind pose might be, this gets the knuckles roughly in the same position as the parent animation, and then from there I chose skeleton for each of the fingers**,** having the rotation data being applied with no translational offset from the parent bone. This choice is very dependent on the ref pose orientation, and if there are extreme differences, it will be off. It does mean that the animation data’s translation is not being taken into account at all though.
[Image Removed]
Hopefully, this helps guide you through the potential issues, and you’ll need to play with some of the options to see what works best. The main thing to note is that you are modifying the animation pose. Most likely, for things where you touch other characters or objects in the world, you will need to do some form of runtime IK adjustment, as now that the animations are playing more similarly to the source on your new mesh, it may not reach or overreach the correct point.
Dustin