Auto Keyframe
Another way to set keyframes is by enabling Auto Keyframe, which you do by clicking the key icon in the lower right of the Maya workspace. When this key is enabled (highlighted red), Maya automatically sets keyframes on channels that change from one frame to another. To see it in action we will re-create the box example using auto keyframes.
- In a new Maya scene, create a polygon cube by choosing Create -ยป Polygon Primitives * Cube.
- Be sure your start frame is set to 1 and your end frame is 300.
- Enable Auto Keyframe by clicking the key icon in the lower right of the Maya workspace (see Figure 2.34). It is enabled when it's highlighted red.
- Figure 2.34 Click the Auto Keyframe button to let Maya automatically generate keyframes.
- Although Auto Keyframe is on, we still have to tell Maya to keyframe initial channels. Set the Current Time Indicator to frame 1. With the cube selected, LM click the TranslateX channel, and then Ctrl+LM click the TranslateZ channel so that both are highlighted. RM hold in the Channel Box and choose Key Selected.
- Scrub to frame 300. In the TranslateX channel of the cube, enter the value of 10. If you play back the Timeline, notice that Maya automatically created a keyframe for you in the TranslateX channel at frame 300.
- Since the TranslateZ value did not change from 0, Maya did not set a keyframe for it. Although we could explicitly set a keyframe of 0 for TranslateZ at frame 300, we'll wait and let Maya automatically create it later.
- Scrub to frame 150. In the TranslateZ channel of the cube, enter the value of 5. If you play back the Timeline, the box should move in an arc to frame 150 and then continue in a straight line to frame 300.
- To make the box move in an arc for the whole Timeline, scrub to frame 300 and set the TranslateZ value to 0. Since TranslateZ was modified in an earlier frame (frame 150), Maya will now automatically set a key for 0 at frame 300.
- At frame 300, set the RotateY channel for the box to 360. Notice the RotateY channel remains highlighted white since there are no existing keyframes to compare it to. Manually set a keyframe on RotateY and scrub to frame 1. Change RotateY to 0. Maya should automatically create a key here for RotateY. If you play back the animation, the box will spin around once as it moves from frame 1 to 300.
Post a comment