Parenting


Parented objects react differently than objects that are grouped. Parented objects have a child-parent relationship. In real life, when a child is holding a parent's hand, the child must go wherever the parent goes (at least in theory). The same is true in 3Dan object that is parented to another object has to follow the other object around (Figure 6.20). This is a direct connection, unlike grouping. When you parent one object to another, no extra node is created. This means the child uses the parent for all its information and treats the parent as its new world space.

Figure 6.20. The sphere on the left is parented to the sphere on the right. The sphere on the left will inherit any transformations performed on the sphere on the right.


Parenting is very important in setting up skeletons for characters because human bone structure follows a natural parenting chain. Your arm starts at your shoulder blade and continues down, connecting your shoulder to your upper arm to your lower arm to your wrist to your palm to your fingers. When the parts are parented together, a relationship is created that forces the fingers to follow the rest of the arm. In this case, the parent is the upper arm, and its child is the lower arm. The lower arm is the parent of the wrist, which itself is the parent of the palm. Whenever the upper arm is moved, all the children beneath it move, creating the whole arm movement (Figure 6.21).

Figure 6.21. The fingers are children of the palm, and the palm is a child of the lower arm. When the upper arm is rotated, all the joints and surfaces below the parent joint follow.


The overall relationship of the parts of the skeleton is called a hierarchy (Figure 6.22). A hierarchy determines which objects control other objects. The order of the hierarchy is important to both selecting and translating.

Figure 6.22. An entire hierarchy is formed by parenting one bone to another until they're all connected.


When you're parenting two objects together, the order in which you select the objects is very important. The second object you select becomes a parent of the first object selected. Once it's parented, the child follows the parent's translations.

To parent two objects together:

1.

Select the object you want to become the child by clicking it.

2.

Select the object you want to become the parent by -clicking it (Figure 6.23).

Figure 6.23. click additional objects to add them to the selection.


3.

Choose Edit > Parent, or press .

The second selected object becomes a parent of the first object (Figure 6.24).

Figure 6.24. The cube is the parent of the cylinder, as shown in the Hypergraph by a connecting line.


Tip

  • Because no additional node is added when objects are parented, the pivot point of the parent is used as the center point for controlling the entire hierarchy.

  • If you select more than two objects, all selected objects become children of the last object selected.

  • You can parent one object to another by using the middle mouse button to drag the child onto the parent in the Hypergraph and Outliner.


To unparent objects:

1.

Select each of the children you want to unparent.

2.

Choose Edit > Unparent to unparent the object, or press (Figure 6.25).

Figure 6.25. Select Edit > Unparent to separate two or more parented surfaces.


The object is pulled out of the hierarchy, so that it now acts separately from the parented hierarchy.

Tip

  • You can also use the middle mouse button to drag the object out of the hierarchy in the Hypergraph and the Outliner, disconnecting the selected object from the rest of the hierarchy.





Maya 7 for Windows and Macintosh(c) Visual Quickstart Guide
Maya 7 for Windows & Macintosh
ISBN: 0321348990
EAN: 2147483647
Year: 2006
Pages: 185

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net