Creating Eye Controls
The eye's "look at" controls were set up simply with two joints for each
eye. RPK IK handles were point- and pole vectorÂconstrained to a locator
that is a child of the "look at" control.
The next exercise takes you through this process. Start with a new scene
and create two spheres, evenly placed as your eyeball objects.
Exercise 17.11 Eye Setup
Begin by creating the joints for the eyes.
Create two joints for each eye.
The crucial aspect of where these joints get placed is that the parent
joint (the one that will control the rotations of the eye) has its
location in the exact same location of the eye geometry's pivot. Therefore,
it is also extremely important that the eye be capable of rotating
around its own pivot without visibly intersecting any of the face's
external geometry. In other words, make sure the eyes can look around
correctly by simply rotating around. If the eyes are perfect spheres
and are carefully placed inside the head, and if the head is modeled
correctly around the eyes, centering the pivot of the eyes should
work just fine.
An easy way to make sure your parent joint is in the exact same place
as your eyeball joint is to turn on handles for the node that should
rotate the eyes. You can do this by selecting the joint and going
to Display, Component Display, Selection Handles. Then use the v key
to point-snap the joint directly on top of the location during creation
and layout of the joint.
Create two locators, and place each locator directly in front of
Name the joints and the two children locators appropriately according
to which eye they are in front of: leftEyeJoints and leftEyeAim.
Next, create an IK handle from the parent joint to the end joint
at the end of the eye.
Now select the "look at" locator first and the IK handle second;
click Constrain, Point to point-constrain the IK handle onto the locator.
With the same selection active, click Constrain, Pole Vector to pole
vectorÂ constrain the IK handle to the same target.
Select the eyeball geometry group. Shift+select the parent eyeball
joint, and hit p to parent the eyeball geometry to the joint (see
Parenting the eyeball to the eyeball joint hierarchy.
You can now hook up some parented control boxes to make the eyes look
around. You can add an additional parent to the aim locator that is point-constrained
to the location of the eyes. An animator can use this to have FK-style
rotations and then actually translate the locator to have the IK style
look at control as well.
This technique involves several really cool things. First, you will not
get flipping because you will have control over the IK handle's rotate
plane much better than a mere aim constrain could provide. Second, you
can actually bind those joints that are rotating the eyes to the face
geometry. When you weight the character, you will want to carefully distribute
the weighting of the eye joints just around the lids of the character,
somewhere between .2 and .4, so that the fleshy area around the eyes actually
deforms subtlety enough when his eyes look around.
The Hair of the Jerk
For the hair of The Jerk, the overlapping action rig setup was used (loaded
straight from the finished example file from Chapter 13, "Making Advanced
Connections"). This was simply imported from the completed file from Chapter
13, chapter13_OverlappingAction_finished.mb, and then was translated,
rotated, and scaled into place using the TRANS_ROTATE_SCALE_MATRIX node.
Then the mainAttachNode was constrained to the end of the head hierarchy
to attach it to the main skeleton. See Chapter 13 for a detailed step-by-step
tutorial on how to create this dynamically driven floppy IK setup.
Note - If you do not want the dynamics mode of this rig during
actual animation testing, you can turn the dynamicFlopOnOff and addMoreFlopiness
attributes found on the FloppyChainContoller locator node to 0 until
the actual playblasted animation occurs. Then you can begin testing
how high you want to set these attributes. Note that because this portion
of the rig is using soft body particle dynamics, it is necessary to
start the animation at least 10 to 15 frames earlier so that the dynamics
get a chance to calculate their initial position correctly.
Smooth Binding Proxy Geometry
The characters were modeled using subdivision surfaces in Maya, but when
it came to production, we chose to convert our properly modeled sub-d
meshes into medium-resolution polygon meshes for the purposes of our rendering
pipeline going out to Mental Ray. We were also fortunate enough to not
need to deal with the hassle of binding Maya's sub-d surfaces or doing
any deformations on sub-d geometry at all because we had a pure polygon
conversion before skinning occurred. I strongly recommend doing things
this way, unless there is a strong reason to not to. The level of simplification
on a geometric level becomes a real time saver and improves the quality
of your final result.
This might not be the case for some productions using Maya, though. Because
subdivision surfaces are going for a full-blown implementation in Maya,
I have included the workflow that is involved with rigging a character
that is actually built from Maya's native subdiv mesh node. The following
exercise was not necessarily used for our production, but it is an important
step to take if you are planning to skin a subdivision mesh in Maya.
The basic premise for the workflow is this: We do not want to bind the
Maya subdivision surface itself to the joint's skinCluster because it
will be much too slow to deform or to paint weights onto. The difficulty
of working with the model is truly overwhelming when compared with simply
binding the polygon control mesh shape node. You will bind only the joints
that need to deform the character by implicitly selecting them and then
selecting the polygon control mesh shape node, instead of binding directly
the subdivision surface.
Exercise 17.12 How to Bind a Subdiv Mesh's Polygon Proxy Control Mesh
This exercise was written to work with any character as a general workflow
tutorial. Therefore, it is not file-specific. You will simply need to
start with a scene that contains any Maya subdivision surface geometry
and some joints to bound the geometry onto.
Go to your current 3D view panel. Under the Show menu, turn off everything
except joints. This makes it easier to see and select only joints.
Carefully select only the joints that are important for the character
This means that anywhere there are overlapping or point-constrained
joints, select only the single joint that should be causing the deformations.
Never select two joints that are overlapping (double joints). You
also usually don't need to select the tips of the joint hierarchies.
Keep the Hypergraph open to make sure you are selecting only the joints
you need. The fewer joints you select, the fewer you will have to
paint weights for later.
When you have made sure your selection is correct, save a quick-select
set by going to Create, Sets, Quick Select Set. Call your new set
bindJoints. This is just a way of saving a selection so that you can
go back and select it again later.
Now select the subdivision character and open the Hypergraph window.
To select the polygon control mesh, you must be in Scene Hierarchy
mode of the Hypergraph. Turn on Options, Display, Shape Nodes by making
sure there is a check box next to it in the menu window.
Next, you should see two shape nodes. One is a subdiv shape that
is being fed its data by a polyToSubdiv node (which you can see if
you select it and click Graph, Input and Output Connections). Below
it is another shape node, which is a polygon mesh shape. The polygon
mesh shape node is your poly control cage (as seen in Figure 17.67).
You can select the polygon proxy control mesh of your native Maya
subdivision geometry by viewing the shape nodes, as previously stated.
Or, you can find it in the tangled node network that shows up in the
Input/Output Connections view of the Hypergraph. Or, you can use a
quick MEL command by selecting it in the View window and executing
the following line in the Script Editor window:
select Ãr 'listRelatives -c -type mesh';
Note - If your subdiv surface is not in polyProxy mode,
you will need to switch it to this mode before any of this will
appear. Select your surface and go to Subdiv Surfaces, Polygon Proxy
Viewing geometry shapes with the Hypergraph.
With the polygon shape node visible in the Hypergraph, select your
bind joint selection set by going to Edit, Quick Select Sets, bindJoints.
Hold down the Shift key and select the polygon shape node in the
Go to the options for Skin, Bind Skin, Smooth Bind Options Box, change
the Bind To options to Selected Joints, and hit the Bind Skin button.
Before you can paint weights, you must assign a shader to the poly
proxy mesh. Select the poly proxy control mesh again. Open the multilister,
right-click the initialShadingGroup, and choose Edit, Assign.
Under your current 3D view, go to the Show menu and turn off Subdiv
Surfaces. This makes it easier to deform your character and visibly
see what is going on.