Tuesday, October 16, 2012

Using Takes in Cheetah3D

I've been wanting to write a simple tutorial on the basics of using Takes in Cheetah3D for a while. Finally I think I have it. Let me know if you find it useful! :)

What are takes? Takes are like scenes of a movie. Each take can store animation keys (recorded positions and parameters) that make it possible to have different scenes from one single set of 3D objects in the same file. Here is how takes are described in the Cheetah3D help files:

The take manager is a very powerful tool when it come to creating independent animation takes or clips. For example if you have a big architectural model and you want to create several independent camera fly throughs of a building. Another area where takes are very important is in the creation of animated characters for 3D games. These characters can perform various movements like running, jumping, kicking and so on. With the take manager you can record each of these animation into its own take.

In order to access takes, you need to switch to the Takes Manager, which is located by default in its own tab right next to the Object browser tag (figure 1).

Figure 1. The Takes panel—seen here
in its own tage by default.
You should notice a few things here. First, if you double-click on a take name, you can enter a different name for it. Second, you can change the take's length (measured in seconds) by double-clicking on the number next to the take name in the Length column, and entering a number (decimals allowed). Third, you can create more than one take per file. In order to do so, Control-click (or Right-click) on the panel, and choose New Take in the pop-up menu that appears (figure 2).

Figure 2. Right-click (or Control-click) on the Takes manager
to bring up a pop-up menu. Choose New Take to add more
takes to the file.
Some more pieces of information are necessary before you can start using the Takes manager comfortably:
  1. Once you create a take, you can't change its stacking order in the Takes manager (new feature request here). If you need one take to appear before another within the Takes manager, plan accordingly.
  2. Also, in order to delete a take, just  highlight it by clicking on it in the Takes manager and hit the Delete key.
  3. In order to switch from one take to another, make sure to click on the checkmark-box to the left of the take name in the Takes manager. Just highlighting the name of a take does not activate it (figure 3).
  4. When a take is active, all animation keys you record stay with that take. This can cause a bit of trouble if you key one parameter in one take but not in another. Objects that have been keyed in one take but not in another will transfer over their settings from the last active take. For example, if you record the Visible in renderer option for an object in a specific scene, but forget to record the same parameter for it (at whatever setting) in another take, when you switch to the un-keyed scene, the object will show up or not depending on the last active take. I hope this is not too confusing :)
Figure 3. Scene 1 is the active take. It is 6 seconds long.
Scene 2 is highlighted—if you press the Delete key,
you'll remove it from the file.

With all this information, we are ready for the mini-tutorial. Open a new Cheetah3D file, create a box, and save the file. You should have something like figure 4 (my window is super-small).

Figure 4. A new Cheetah3D file with a box.

Click on the Takes manager tab and create two takes like I describe on figure 2. Give them any name and length (in seconds) you like. One of the two takes will be the active take—the one with the checkmark on.

Figure 5. Create two takes. You can copy my settings here, but it's not that
important if you do not.

Select the box and enter -5 in the X Position field on the Properties panel (figure 6). You'll notice that the box moves to the left—that's OK.

Figure 6. Enter -5 in the X Position field in the Properties panel.
We are still on take Scene 1 in my file.
The next thing we need to do is to make sure we can see the whole timeline. By the way, if you can't see the timeline, click on the clock icon in the Toolbar (figure 7).

Figure 7. Click on this icon in the Toolbar to display the Timeline.
To show the whole timeline, grab the grey bar right next to the frame number indicator in the Timeline and drag it to the right until it spans the whole available width (figure 8).

Figure 8. Drag the dark grey bar all the way to the right to cover the whole
lighter bar. In my example, this shows the whole 6 seconds available for Scene 2.

Now, we're going to record some keys. Make sure the Box is selected and that the frame selector is set to 0, and click on the red button to the left of the Timeline to record the position of the Box. Actually, we are recording other things as well, like its rotation and scale, but the only thing that's going to change is its position (figure 9).


Figure 9. Make sure the frame selector is set to the 0 position.
Click on the red button to record the position of the box.

With the box still selected, move the frame selector to the last frame of the take (180 in my example). Enter 5 in the Position field in the Properties panel. Do not worry if the box disappears from view—it's still there. Click on the record button to record the box's postion on this frame. You can play the animation (press the green arrow) and see the box move! Notice that each frame that contains recorded keys displays a blue line over it on the Timeline (figure 10).

Figure 10. Notice the blue markers on the Timeline that indicate recorded keys.
In my example, on frame 111 this is the interpolated position for the box.

The next thing we need to do is switch to a different take. Go to the Takes panel and checkmark it. The scene seems to not have changed at all. The box will still be in the same position. That's because, when there are no recorded keys for parameters that do have them in other takes, the settings get transferred over from the last active scene. Notice, however, that the recorded keys have gone away. More the frame selector on the Timeline to frame 0 and move, rotate, scale the box as you see fit. Click on the Record button to record that position, scale, or rotation. Move the frame selector to the last frame and go crazy again with the scale, position, and rotation for the box. Hit the Record button again. Play the animation now. The nice surprise is that, if you go back to take Scene 1, the animation on that take is still there. No need to duplicate files, objects. All your animations with a specific sets of objects can reside in one same file! Neat eh?

3 comments:

  1. Thanks for this nice tutorial!

    ReplyDelete
  2. You're welcome! I'm glad you liked it :)

    ReplyDelete
  3. Hello, I'm a 3D animation specialist. I'd like to share a little. It's best to have clear full-body posing in your phrases at the expense of smooth transitions, especially early on. Animation follows beats and phrases, each with its own purpose. For a scene in which a store clerk is helping a customer, one phrase might be him waving as the customer enters; the next might be him putting his hands in his pockets as he listens to the customer. thanks all!~ Nadia Brightman

    ReplyDelete