Body Autorig System







Before starting,

I would like to thank Niels Dervieux, Rigging Supervisor at Stim Studio,  who developped the autorigging system at Stim, which heavilly inspired me  for my  work.  I would also like to thank him for all the knowledge and wisdom he brought to me, and the possibility to explain his autorig logic here.

I would also thank Jean-Paul-Tossings, Founder and Technical Director at Polder Animation , who taught me matrices via his YouTube channel, the system with the guides is heavilly inspired from his work : https://www.youtube.com/@JeanPaulTossings/videos





For my graduation movie at ESMA, we decided to have a movie with multiple humanoid characters (One main character, and 17 “crowd” characters), and try to aim the same quality as a studio such as Illumination Studios .
As the production time is quite short, I decided to develop autorig systems for facial and body rigging in order to speed-up the process and spend more time on the deformations and retakes. The facial autorig was made after my body autorig, where I faced many challenges and learned by doing mistakes. So I basically took the entire setup and reshaped it in order to fit the facial rigging workflow.


This page will be talking about the body autorigging system, but if you want to learn more about the workflow used for the facial rigging, you can go here.


The autorigging system at Stim was a “procedural” way of rigging, where the autorig has many “tasks” to run (such as guides, controllers, rig etc...), in order to build the rig.
I loved this system, because it has a lot of advantages such as :

- keeping everything organized in the pipeline
- keeping all the data in .json files (so easy tweakable by the user)
- never work directly in the rig scene, so the work is never lost
- huge room for retakes
- the setup is straightforward, so really easy to understand

These advantages motivated me to reproduce this system for the production of our movie.





Summary :







The UI

For the UI, the goal was to create the simplest UI possible, and be able to dock the UI to the maya window, in order to save some space in the viewport and still be able to use the autorig. As I am a huge fan of The Matrix  (only the first two movies) I decided to do a The Matrix themed UI, that will also symbolize the fact that all my rigging setup is done with matrices. The UI was done with Python  3.11 and PySide6, and the styling was done in CSS.




The Tasks



    The tasks vary a bit from the facial autorig and the body autorig, but the logic stays the same.
    The user drag and drops a task, in the Tasks field, and then organizes them in order of build the rig.
    If needed, the user can also enable/disable the tasks, in order to run only specific tasks, and keep all the tasks in the ui.




    List of Body Autorig Tasks :




Import

The first task is the import task, when dropped in the field , the usage of this task is to import something in the scene from the selected path, it could be a character model, a scene, etc...
It has a checkbox “Use NS” with a lineEdit used to input a custom namespace name, that will import the file with the custom namespace, for specific actions (mostly scriptwise).
On build, it imports the file inputted in the lineEdit


Rig

This task is used to build the rig. It has 2 lineEdits, the first one is used to create the rig hierarchy and save it, and the second one is used to save the guides position of every object ending with *_guide in the scene.
On build, it import the different modules, does the connexions and places the guides from the data in the .json files.


Controllers



The Controllers task is used to save every controller shape form that ends with *_ctrl suffix in a .json file. It saves shape data as well as attributes such as lineWidth, color etc...
On build, the Controllers task is creating the saved shape with its geometry data, and replacing the shape by name, with the correct color width etc..


Script



The script task is maybe one of the most important tasks, the task has 2 lineEdits, the first one is there to give the path to a .py file, in order to run a specific definition from it. The second one is used to run the specific def.
On build, it runs the given def from the given python script.


Deformers

The deformers task is used to save the Skinning data from the scene. It saves mesh data, ngSkinTools layers, and skinCluster weights.
On build, it applies all the data in vertex order to the meshes.


Volume Joints

The volume joints task is used to create and save the volume joints available in the scene.
The task has 2 lineEdits, one that saves the joints on which the volume joints will be applied, and the second one that saves the different attributes of the volume joints such as the start angle etc...
On build, it creates the volume joints system for each joint in the .json file, and applies the saved settings.


Setup



This task has only one lineEdit, that saves all the attributes and its values from all the groups that ends with *_SETUP in a .json file.
On build, it just bring back the saved values in the correct attributes.


Tweakers

This last task, creates tweakers on the selected meshes. It has 2 lineEdits, the first one is used to open the tweakers UI, and save the tweakers setup (I will show it a bit later).
The second one is used to save the weights of the tweakers joints in a .json file.
On build, it creates the tweakers from the data saved before.





The workflow



As I did for the facial autorig, I will explain a bit the workflow when using the autorig.

  • Importing the character geometry Import task
  • Building the rig in the rig UI regarding the modules needed for the character Rig task
  • Run common script to organize well the scene etc.. Script task
  • Placing the different guides
  • Resizing the shapes of the controllers
  • Saving the data of guides position and controllers shapes Controllers task / Rig task
  • Bind skinning the mesh, and executing the skinning 
  • Saving the skinning data Deformers task
  • Tweaking the SETUP groups, and saving the attributes SETUP task
  • Executing the cleanup script in order to publish the rig when its done Script task
  • Build the rig

That was the workflow used for the graduation movie, by experimeting it, as for the facial autorig, I found some limitations and rooms for improvement ! In order to simplify everything and work faster.








The modules




For the modules, I decided to do ALL the modules of the autorig by hand, so every module has its maya scene, that I import with the rig task, and that have interactive guides placement/rig setup updating in live.
That gave me the flexibility of not spending all my time scripting the modules by hand, and fixing visually all the issues directly in the scenes when occured.
The only modules that are done in script, are the chain modules, because I needed to set the number of joints I want in the chain.

Another objective for me was to do the entire rig in matrices, because it gives more elegant and optimized rigs, and it widens my rigging knowledge. So no maya constraints. No parent groups.

For now, these are the modules available in the autorig :

Global modules :

 
  • Root
  • Main
  • Foot
  • Advanced Foot
  • Fk chain (in script)
  • Hybrid chain  (in script)
  • Ik chain (in script)
  • Collar
  • Point
  • Belt (in script)
  • Mouth Shadow
  • Car


Biped modules :

  • Spine
  • Limb
  • Advanced Limb
  • Clavicle
  • Head
  • Hand

Quadruped modules (sill in WIP):


  • Quadruped Spine
  • Quadruped Advanced Limb
  • Quadruped Clavicle


Advanced Limb module (works for both arm and leg)
Hand module
Spine module
Car module


This is the Rig UI, which is responsible for build and connect the rig.



Connexionwise, each module has “output” groups and “outputGuide” groups, that are wired into other modules “input” and “inputGuide” groups. So the user can place the guides in live, witout moving the setup at all.

All the modules share the exact same logic of connexions, and naming, so scriptwise I don’t need to rewrite script each time I create a new module.
Depending the modules, the user can add spaces, in order for the animator to switch space if needed. The user only need to provide the output group name of the specific space, in order for the autorig to understand which module to connect.

As I developped my autorig and my modules, I encountered many issues and limits of the current setups. In the future I want to improve all the modules by upgrading their setups and optimizing them even more. Something I could drastically improve are the foot and hand modules, where I want to give all the possible options for the animator, so he does not need to stick with one setup only. I also need to improve the look of the modules by changing the guide locators by something more friendly for the user. It will not impact rig performance as the guides are deleted at rig cleanup.


Still in construction... Come back later to see more !






During this project I learned so much, firstly on the technical side. Where creating modules with matrix setups only really widened my knowledge in rigging, and gave me some interesting problem solving.
I learned a lot on the artistic side too, a rig can not be good if the deformations are poor, so it’s really important to find a good balance between a really technical rig, and a well deformable rig useful for the animators. The challenge was to nail correct deformations, in a short amount of time.
It also taught me to anticipate and planify everything at start, in order to save some time later. When working procedurally like that, you learn to anticipate every step of the process, and that’s a really cool exercise that you can transfer in every departement of the pipeline.
I already want to start a new project, in order to improve and simplify everything I learned.

I hope that you found something useful here, and wish you a good day ! ☀️