Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Documentation on rig indices

Discussion in 'Animation' started by Nathanieljla, Oct 27, 2020.

  1. Nathanieljla

    Nathanieljla

    Joined:
    Apr 18, 2014
    Posts:
    97
    Does anyone know of any blog or post that details how the content of a file is indexed for the purposes of a rig. I want the nitty-gritty, explicit details.

    Example A:
    rigA has 50 animation exported.
    rigB has some bones added. These additional bones are only needed for variant animations. If you understand how the indexing works there's a chance those bones might be able to be added in a way that extends the index values and not re-orders anything. This means the 50 previous animations can still play on rigB even if they don't have the extra bones.

    Example B:
    It seems like the indexing is not limited to just the skinned joints, but anything in the file. Including the skinned mesh (seems odd).
    RigA contain body_mesh (idx:0), weapon_mesh(idx:1), skeleton_hier(idx:2).
    RigB contains body_mesh(idx:0), skeleton_hier(idx:1).

    Does this mean the animation won't process because skeleton_hier is index 1 instead of 2?

    If that's the case, there should be some best practices in place, such as always organize your skeleton hier to be listed first. Turn off sort hierarchy by name. etc. etc.

    It's hard to confidently make rig changes and know you won't break anything without knowing how the underlying system creates the indices. Another example. Is there a difference between generic and humanoid rigs?