Adjusting update time/order of runtime rigging

Hello,

We have an existing codebase where we are using FinalIK to adjust, for example, foot positioning for climbing up or down inclines and declines (FinalIK Grounder and Full Body Biped IK). We also have some extra bones in our skeleton to assist with skinning around, for example, the hips. One problem we run into with getting these to look correct is that these extra bones don’t know anything about the IK adjustments which have been made, which makes it difficult to maintain volume during an instance where the leg/knee is lifted up to step up a hill or onto an obstacle.

The Animation Rigging preview package offers some options that would seem to work well for this - for example, setting up a position constraint between the upper leg or knee and the hip bones in question, to allow them to be adjusted based on the position of said bone. However, I’m running into one fundamental problem: FinalIK is updated in LateUpdate, while (as far as I can tell) the rig constraints are updated in Update. So the constraint is updated before FinalIK adjusts the bones, so the constraint does not actually take FinalIK into account either.

Completely removing FinalIK and replacing all of its functionality with the IK options provided in the Animation Rigging package is likely unfeasible (or at least out of scope for our current cycle). The only reasonable approach I’ve come up with is to introduce some extra transforms that cache the FinalIK-adjusted bone positions each frame, and then setting those as the source bones in the rig constraints. This will generally work, although will always be lagged by one frame behind the actual final rendered pose of the character, so it’s not ideal.

Is there any way currently, or any plan in the future, to allow any amount of control as to when during the update lifecycle the rig constraints actually update? This would be extremely helpful in making use of Animation Rigging alongside other IK solutions.

Thanks,
Rob

Hi,

Animation Rigging is implemented in Animation C# Jobs. it is evaluated in the animation loop using its own PlayableGraph. While that brings in improved performance as post-processing rigs are evaluated in threads, it also means we cannot interact with other scripts. Therefore, it is by design, and will not change.

I already answered this question before. You can look at this thread for more details:

1 Like