Maya Tutorial pdf

Custom Search

Tuesday 26 July 2011

Animation Lesson 2: Introduction

With keyframe animation, you key an attribute value to a time in the Time Slider. You repeat this process
with different values at different times to animate the object.

When you must animate multiple objects or attributes that interrelate, setting keyframes can quickly
become a complex task. Set Driven Key is a technique for driving one object's or attribute's animation
from another attribute.

With driven keys, you relate an attribute value to the value of another attribute. You repeat this with
different values to create a dependent link between a pair of attributes. A change in the driver attribute
alters the value of the driven attribute. In this way the animation of the driven attribute doesn't need to
be manually set; it occurs automatically once the relationship between attributes has been established.
This makes setting up some types of animations much more efficient. For example, you can use driven
keys to make a door open when a character walks in front of it.

In this lesson, you will learn how to use Set Driven Key in order to animate a door rising upwards when a
ball approaches it.

In this lesson you learn how to:


 Link the object attribute behavior between two objects which will link the movement of one
keyframed object to another with no keyframes assigned.


 Use the Graph Editor to adjust the animation for the driven object.



Lesson setup

In the following steps, you set a playback range that's long enough to see the animation clearly. You
also create the ball and the door, and position them in the scene view in preparation for the animation.


1. Make sure you've done the steps in Animation Lessons: Preparing for the lessons.
2. Create a new scene.
3. Go to the start frame.
4. Create a polygonal cube and name it Door.
5. Scale and position it roughly as shown in the previous figure. Have the bottom edge of the door lie
roughly along the X-axis.
6. With the pointer in the perspective view, press 5 (for Shading > Smooth Shade All).
7. Create a small polygonal sphere and name it Ball. Scale and position it roughly as shown in the
prior figure. Have it sit roughly at 0, 1, 10 (X, Y, Z).

Use the default color for the door and the ball.


Using Set Driven Key to link attributes

The following steps link the door's movement to the ball's movement using Set Driven Key.

To link the door's movement to the ball's movement

1. Select the door and choose Animate > Set Driven Key > Set > .

The Set Driven Key window appears with the door in the Driven list.

2. Click translateY in the Driven list.
This is the attribute to be driven by the ball's movement.
3. Select the ball in the scene view.
4. In the Set Driven Key window, click the Load Driver button.
The ball appears in the Driver list.
5. In the Set Driven Key window, click translateZ in the Driver list.
This is the attribute that will drive the door's movement.
You can set a driven key only after you select an attribute in the Driver list and in the Driven list.
6. In the Set Driven Key window, click Key.
This sets a driven key relationship that links the current Translate Z value of the ball to the
current Translate Y value of the door. Whenever the ball's Translate Z is at this position, the
door's Translate Y will be at its current position.
The Time Slider is not involved in a driven key relationship and displays no red markers for keys.
7. Move the ball to the door's position and then move the door above the ball.





8. In the Set Driven Key window, click Key.

This sets another driven key that links the current Translate Z value of the ball to the Translate Y
value of the door.

9. Move the ball to the right of the door and then lower the door to its previous position as shown in
the following figure.


10.In the Set Driven Key window, click Key.

This sets another driven key that links the attributes.
You've set three driven keys that link the attribute values at different positions. Maya interpolates
the linked values to generate the values between the keys.
If you drag the ball toward the door from either side, the door rises smoothly.
Playing back the animation from the Time Slider doesn't move the ball or the door. Driven keys link
one attribute to another. They don't link attributes to times in the Time Slider. However, if you
were to animate the movement of the ball, the door would move based on the driven key
relationship that has been set.

No comments:

Post a Comment