Joint Orientation
by Brian Immel
Joint Orientation |
Why is Joint Orientation Important
- Makes it difficult to manage animation curves and set driven keys
- May bend joints in unexpected ways
Remember the Branches?
Each branch can have its own direction unique to that branch.
It doesn’t really matter too much if one branch has another orientation direction than another branch. Some purists will stay that it is and to a point they are right. But for now, just remember the KISS rule (Keep It Simple, Stupid).
It is important to make all the joints of one branch have the same joint orientation!
Remember when we mirrored some branches? You might have noticed by now that the leg and arms branches are completely opposite of one another.

How to orientate joints
![]()
1. Select the root joint.
2. Click the Select by Component Type button in the Status Line.
3. Turn on the selection mask called Miscellaneous (looks like the question mark). This will show every single joint’s orientation because we selected the root joint.
4. Scan each branch and look to see which joints have what orientation. Look to see which direction the axis have the majority of facing directions (i.e. Z forward, X to the right or X down, Y to the left, etc.). Refer to Figure 12 to see an example of a Spine that is out of alignment and one that has good alignment.

5. Select the joint that is not facing with the crowd, and rotate in the direction in needs to face. But you will find yourself a new problem. When you rotate this joint, you will notice that the rotation attributes in the Channel Box do not update, nor will they. We are changing the component information of the selected axis. “So how do we rotate these joints to be in perfect alignment with the other joints of this branch?” Keeping in mind that everything you perform in Maya is a scripted function or tool, you can see your commands being echoed in the Script Editor.

Making orientating joints easier via MEL
>
1. The upper section of the Script Editor is the history section and the lower section in the Input Field.
2. Highlight and copy the script that looks something like this:
i. Rotate –r –os –41.227934 0 0;
3. This script tells Maya to rotate the selected joint on the X axis –41.227934degrees.
4. Analysizing what is going on in this script
- Rotate = the command to perform (rotation).
- r = make the joint center position relative to the joint’s parent.
- –os = orientation float (X Y Z). 0 –41.2279340 = what to rotate and how much. The first number is used to change the X rotation, the second number is used to change the Y rotation and the last number is used to change the Z rotation.
- ; = end of command (terminator symbol).
- Now that we know what the script stands for, copy the script into the Input field below the history section.
- RotX
- RotY
- RotZ

6. Change the orientation numbers to all zeros (0 0 0).
7. Next we want to make buttons out this script in the Input Field and have the ability to rotate the orientation axis on degree increments. Change the first 0 to 90. Highlight the entire script and MMB-drag this script to the open space in the Shelf. We just created a button that will rotate the orientation axis of any selected joint 90 degrees on X.
8.Change all the numbers back to 0 0 0.
9. Change the second zero to 90. Highlight the entire script and MMB-drag this script to the open space in the Shelf. This button will rotate Y 90 degrees of the selected orientation axis.
10. Change all the numbers back to 0 0 0.
11. Finally, change the third zero to 90. Highlight the entire script and MMB-drag this script to the open space in the Shelf. This button will rotate the orientation axis 90 on Z.
12. Close the Script Editor.
13. Open up the Shelf Editor and name each of these new buttons with the following names:

14. I use short names because of the space allowed in the icon naming area. If you like, you can make custom icons for these fellas.
