3ds Max 9 Bible
Now that you've learned how to assign controllers, let's look at the available controllers. Max includes a vast assortment of controllers, and you can add more controllers as plug-ins.
Earlier in the chapter, I mentioned six specific controller types. These types define the type of data that the controller works with. This section covers the various controllers according to the types of tracks with which they work.
Note | Looking at the function curves for a controller provides a good idea of how you can control it, so many of the figures that follow show the various function curves for the different controllers. |
Each of these controllers has a unique icon to represent it in the Track View. This makes them easy to identify.
Transform controllers
Multi-track transform controllers work with the Position, Rotation, and Scale tracks all at the same time. You access them by selecting the Transform track in the Motion panel and then clicking the Assign Controller button, or by choosing the Animation
Note | Each of the available constraints is listed again in the appropriate controller submenu. |
Position/Rotation/Scale Transform controller
The PRS Parameters rollout, shown in Figure 32.8, lets you create and delete keys for Position, Rotation, and Scale transforms. The Position, Rotation, and Scale buttons control the fields that appear in the Key Info rollouts positioned below the PRS Parameters rollout.
Script controller
CROSS-REF | For more information on MAXScript, see Chapter 49, "Automating with MAXScript." |
XRef controller
If you have a defined motion used by an object in another file that you want to access, you can use the XRef controller. This controller can only be assigned to the Transform track. When this controller is assigned, a file dialog box opens where you can select the XRef file; then in the Merge Object dialog box, you can select a specific object that has the controller and motion you want to use.
NEW FEATURE | The XRef controller is a new feature in 3ds Max 9. |
CROSS-REF | XRefs are covered in detail in Chapter 3, "Working with Files and XRefs." |
Position track controllers
Position track controller types include some of the common default controllers and can be assigned to the Position track. They typically work with three unique values representing the X-, Y-, and Z-axes. These controllers can be assigned from the Animation
Audio controller
The Real Time Control drop-down list lets you specify a device to control the system. To control the sound input, you can specify a Sample Threshold and Oversampling rate. You can also set Base Point and Target Point values for each axis. The Channel options let you specify which channel to use: Left, Right, or Mix.
Bézier controller
The Bézier controller parameters are displayed in the Motion panel under two rollouts: Key Info (Basic) and Key Info (Advanced).
At the top of the Key Info (Basic) rollout are two arrows and a field that shows the key number. The arrows let you move between the Previous and Next keys. Each vertex shown in the function curve represents a key. The Time field displays the frame number where the key is located. The Time Lock button next to the Time field can be set to prevent the key from being dragged in Track View. The value fields show the values for the selected track; the number of fields changes depending on the type of track that is selected.
At the bottom of the Key Info (Basic) rollout are two flyout buttons for specifying the In and Out curves for the key. The arrows to the sides of these buttons move between the various In/Out curve types. The curve types include Smooth, Linear, Step, Slow, Fast, Custom, and Tangent Copy.
CROSS-REF | Chapter 33, "Working with Function Curves in the Track View," describes these various In/Out curve types. |
The In and Out values in the Key Info (Advanced) rollout are enabled only when the Custom curve type is selected. These fields let you define the rate applied to each axis of the curve. The Lock button changes the two values by equal and opposite amounts. The Normalize Time button averages the positions of all keys. The Constant Velocity option interpolates the key between its neighboring keys to provide smoother motion.
Linear controller
The Linear controller doesn't include any parameters and can be applied to time or values. Figure 32.11 shows the curves from the previous example after the Linear controller is assigned-all curves have been replaced with straight lines.
Motion Clip Slave controller
The Motion Clip Slave controller lets the object's transform be controlled by a linked motion clip that is loaded and defined in the Motion Mixer.
CROSS-REF | The Motion Mixer and using Motion Clips are covered in Chapter 34, "Combining Animations in the Motion Mixer." |
Noise controller
You also have an option to enable Fractal Noise with a Roughness setting.
The Ramp in and Ramp out values determine the length of time before or until the noise can reach full value. The Characteristic Graph gives a visual look at the noise over the range. Figure 32.13 shows the Noise controller assigned to the Position track. If you need to change any Noise properties, right-click the Noise track and select Properties from the pop-up menu.
Motion Capture controller
After you assign the Motion Capture controller to a track, right-click the track and select Properties from the pop-up menu to open the Motion Capture panel, shown in Figure 32.14. This dialog box lets you select the devices to use to control the motion of the track values. Options include Keyboard, Mouse, Joystick, and MIDI devices.
For the Keyboard control, the Keyboard Input Device rollout appears, as shown in Figure 32.15. The Assign button lets you select a keyboard key to track. The other settings control the Envelope Graph, which defines how quickly key presses are tracked.
The Motion Capture dialog box defines only which device controls which values. The actual capturing of data is accomplished using the Motion Capture utility. Selecting the Motion Capture utility in the Utility panel displays the Motion Capture rollout. This rollout includes buttons to Start, Stop, and Test the data-capturing process.
Before you can use the Start, Stop, and Test buttons, you need to select the tracks to capture from the Tracks list. The Record Range section lets you set the Preroll, In, and Out values, which are the frame numbers to include. You can also set the number of Samples Per Frame. The Reduce Keys option removes any unnecessary keys, if enabled.
Tutorial: Drawing with a pencil with the Motion Capture controller
Some motions, such as drawing with a pencil, are natural motions for our hands, but they become very difficult when you're trying to animate using keyframes. This tutorial uses the Motion Capture controller and utility to animate the natural motion of drawing with a pencil.
To animate a pencil drawing on paper, follow these steps:
-
Open the
Drawing with a pencil.max file from the Chap 32 directory on the DVD.This file has a pencil object positioned on a piece of paper.
-
Select the pencil object, open the Motion panel, and select the Position track for the pencil object. Then click the Assign Controller button, and double-click the Position Motion Capture selection.
The Motion Capture dialog box opens.
-
Click the X Position button, and double-click the Mouse Input Device selection. Then click the Y Position button, and double-click the Mouse Input Device selection again. In the Mouse Input Device rollout, select the Vertical option. This sets the X Position to the Horizontal Mouse movement and the Y Position to the Vertical Mouse movement. Close the Motion Capture dialog box.
-
Open the Utilities panel, and click the Motion Capture button. In the Motion Capture rollout, select the Position track, and get the mouse ready to move. Then click the Start button in the Record Controls section, and move the mouse as if you were drawing with the mouse. The pencil object moves in the viewport along with your mouse movements.
The Motion Capture utility creates a key for each frame. It quits capturing the motion when it reaches frame 100.
-
Click the Play Animation button (or press the / key) to see the results.
Figure 32.16 shows the scene after the Motion Capture controller has computed all the frames.
Quaternion (TCB) controller
The parameters for this controller are displayed in a single Key Info rollout. Like the Bézier controller rollouts, the Quarternion (TCB) controller rollout includes arrows and Key, Time, and Value fields. It also includes a graph of the TCB values; the red plus sign represents the current key's position, while the rest of the graph shows the regular increments of time as black plus signs. Changing the Tension, Continuity, and Bias values in the fields below the graph changes its shape. Right-clicking the track and selecting Properties from the pop-up menu opens the TCB graph dialog box, shown in Figure 32.17.
The Tension value controls the amount of curvature: High Tension values produce a straight line leading into and away from the key, and low Tension values produce a round curve. The Continuity value controls how continuous, or smooth, the curve is around the key: The default value of 25 produces the smoothest curves, whereas high and low Continuity values produce sharp peaks from the top or bottom. The Bias value controls how the curve comes into and leaves the key point, with high Bias values causing a bump to the right of the key and low Bias values causing a bump to the left.
The Ease To and Ease From values control how quickly the key is approached or left.
Note | Enabling the trajectory path by clicking the Trajectory button in the Motion panel lets you see the changes to the path as they are made in the Key Info rollout. |
Figure 32.18 shows three TCB curves assigned to the Position track of an object.
Reaction controller
CROSS-REF | Don't confuse the Reaction controller with the reactor plug-in, which computes motion based on physical dynamics. The reactor plug-in is covered in Chapter 37, "Simulating Physics-Based Motion with reactor." |
After the Reaction controller is assigned to a track, you can define the reactions using the Reaction Manager dialog box, shown in Figure 32.19. Selecting and right-clicking the track with this controller assigned and selecting Properties from the pop-up menu opens this dialog box. You can also open the Reaction Manager dialog box using the Animation
The Reaction Manager is made up of two lists and a graph of function curves. The top list holds all the object values that are involved in reactions. These are listed in a hierarchy with the master object listed above the slave object. A single master object can control several slave parameters.
The buttons above the Reactions list let you add new masters, slaves, and selected objects to the list. The cursor changes after you click any of these buttons, allowing you to click an object in the viewport and select a value from a pop-up menu.
For the slave objects selected in the Reactions list, you can set states using the buttons above the States list. To set a state, click the Create Mode button, drag the Time Slider to appropriate frame, and change the slave object's value. Then click the Add State button to create the target object state. Several unique states can be defined for each slave object.
State values can be changed by accessing the Edit Mode button or by editing the curves displayed at the bottom of the Reaction Manager dialog box.
Tutorial: Rotating gears with the Reaction controller
Many mechanical devices use gears, and animating these gears can be tricky because every adjacent gear rotates in the opposite direction. Animating by linking the gears together causes one gear to rotate around the other one. You can achieve this motion by animating the rotation of every gear individually, or you can use the Reaction controller to make the gears work like they are supposed to-which is what we do in this tutorial.
To rotate gears using the Reaction controller, follow these steps:
-
Open the
Reaction rotating gears.max file from the Chap 32 directory on the DVD.This file contains some gears created using the Ringwave primitive. The lower gear is animated rotating about its center.
-
Select the upper gear, open the Motion panel, and click the Rotation track. Then click the Assign Controller button located in the Assign Controller rollout, and select Rotation Reaction from the dialog box that appears.
The Reaction Manager dialog box opens.
-
In the Reactions list of the Reaction Manager, select the Unassigned item, right-click, and choose Replace Master from the pop-up menu to enter pick mode. Then click the lower gear object in the viewport, and choose Transform
Rotation from the pop-up menu that appears.This adds both gears to the Reaction Manager with Gear2/Rotation being the master and Gear1/ Rotation being the slave.
-
Drag the Time Slider to frame 100 (or press the End key), select the upper gear, choose the Select and Rotation tool, and click the Create Mode button in the Reaction Manager. Rotate the upper gear about its Z-axis 180 degrees counterclockwise. Then click the Create State button to create a new state. Then click the Create Mode button again to disable it.
This creates another reaction called State02 in the list.
-
Click the Play Animation button (or press the / key) to see the gears move together.
Figure 32.20 shows the two gears and the Reaction Manager dialog box. The second gear rotates in the opposite direction of the first gear.
Spring controller
In the Spring Dynamics rollout, you can change the Mass and Drag values. Higher mass values result in greater secondary motion as the object is moved, and the Drag value controls how quickly the bouncing motion stops. You can add multiple springs, each with its own Tension and Damping values to be applied Relative or Absolute.
The Forces, Limits, and Precision rollout lets you add forces that affect the spring motion. The Add button lets you identify these forces, which are typically Space Warps, and you can limit the effect to specific axes.
Tutorial: Wagging a tail with the Spring controller
One of the best uses of the Spring controller is to gain the secondary motion associated with an existing motion. For example, if a character moves, then an appendage such as a tail can easily follow if you apply a Spring controller to it.
To wag a row of spheres using the Spring controller, follow these steps:
-
Open the
Dog wagging tail.max file from the Chap 32 directory on the DVD.This file contains a linked row of spheres with the head sphere animated rotating back and forth.
-
Select the smallest sphere, and choose the Animation
Position Controllers Spring menu command. This moves the sphere to its parent. Choose the Select and Move button (or press the W key), and return the sphere to its original position. -
Repeat Step 2 for the remaining spheres, moving from smallest to largest.
-
Click the Play Animation button (or press the / key) to see the resulting motion.
Figure 32.22 shows a frame of the final motion. Notice that the spheres aren't lined up exactly. The smallest sphere is moving the greatest distance because all the springs are adding their effect.
Position XYZ controller
The Rotation tracks use a variety of controllers, many of them common to the Position track. This section lists the controllers that can be used only with the Rotation track.
Rotation and Scale track controllers
The Rotation and Scale track controller types include some of the common default controllers and can be assigned to the Rotation and Scale tracks. They typically work with three unique values representing the X-, Y-, and Z-axes. These controllers can be assigned from the Animation
Euler XYZ Rotation controller
The main difference is that Euler rotation gives you access to the function curves. Using these curves, you can smoothly define the rotation motion of the object.
Note | Euler XYZ Rotation values are in radians instead of degrees. Radians are much smaller values than degrees. A full revolution is 360 degrees or 2 times Pi radians, so one degree equals about 0.0174 radians. |
The Euler Parameters rollout lets you choose the Axis Order, which is the order in which the axes are calculated. You can also choose which axis to work with.
Smooth Rotation controller
Scale XYZ controller
The Scale XYZ Parameters rollout lets you select which axis to work with. This controller works the same way as the other position and rotation XYZ controllers.
Parameter controllers
Other controllers are used to affect the animated changes of parameters whether they are float, point3, or other parameter types. Many of these controllers combine several controllers into one, such as the List and Block controllers. Others include separate interfaces, such as the Waveform controller for defining the controller's functions.
Most of these special-purpose controllers can be assigned only by using the Track View window. The Motion panel contains only the tracks for transformations.
Boolean controller
Limit controller
The upper limit is the maximum value to which the controller can be set, and the lower limit is the minimum value that the controller uses. Controller values may exceed the upper and lower limit values, but the object's motion stops at the limit values when the Limit controller is enabled. The Smoothing Buffer value provides a range that gradually alters the value as it approaches the limit value.
After a Limit controller is applied to an object, you can quickly change its upper and lower limit values by right-clicking the object in the Track View and accessing the Limit Controller option in the quadmenu.
Tip | You can disable all limits at once using the Animation |
List controller
When the List controller is applied, the default track appears as a subtrack along with another subtrack labeled Available. By selecting the Available subtrack and clicking the Assign Controller button, you can assign additional controllers to the current track.
All subtrack controllers are included in the List rollout of the Motion panel. You also can access this list by right-clicking the track and selecting Properties from the pop-up menu. The order of the list is important because it defines which controllers are computed first.
The Set Active button lets you specify which controller you can interactively control in the viewport; the active controller is marked with an arrow, which is displayed to the left of the name. You also can cut and paste controllers from and to the list. Because you can use the same controller type multiple times, you can distinguish each one by entering a name in the Name field.
On/Off controller
Note | You can also add a Visibility track by changing the Visibility value in the Object Properties dialog box. |
Waveform controller
When you select a waveform in the list, you can give it a name and edit its shape using the buttons and values. Preset waveform shapes include Sine, Square, Triangle, Sawtooth, and Half Sine. You can also invert and flip these shapes.
The Period value defines the number of frames required to complete one full pattern. The Amplitude value sets the height of the wave, and the Phase value determines its location at the start of the cycle. The Duty Cycle value is used only for the square wave to define how long it stays enabled.
You can use the Vertical Bias options to set the values range for the waveform. Options include Centered, which sets the center of the waveform at 0; Auto > 0, which causes all values to be positive; Auto < 0, which causes all values to be negative; and Manual, which lets you set a value for the center of the waveform.
The Effect option determines how different waveforms in the list are combined. They can be added, multiplied, clamped above, or clamped below. The Add option simply adds the waveform values together, and the Multiply option multiplies the separate values. The Clamp Above and Clamp Below options force the values of one curve to its maximum or minimum while not exceeding the values of the other curve. The Characteristic Graph shows the selected waveform, the output, or the final resulting curve. Figure 32.26 shows the Characteristic Graph for each Effect option when a sine wave and a square wave are combined.
Color RGB controller
The Color RGB controller splits a track with color information into its component RGB tracks. You can use this controller to apply a different controller to each color component and also to animate any color swatch in Max.
Figure 32.27 shows the function curves for the Color RGB controller assigned to the Diffuse Color track under the Material #1 track, including subtracks for Red, Green, and Blue. The figure shows the Bézier controller applied to the Red track, the Noise controller that is assigned to the Green track, and the Waveform controller with a triangle wave applied to the Blue track.
Cubic Morph controller
You can assign the Cubic Morph controller to a morph compound object. You can find the track for this object under the Objects track. A subtrack of the morph object is the Morph track, which holds the morph keys.
The Cubic Morph controller uses Tension, Continuity, and Bias values to control how targets blend with one another. You can access these TCB values in the Key Info dialog box by right-clicking any morph key or by right-clicking the Morph track and selecting Properties from the pop-up menu.
Note | You can also access the TCB values by right-clicking the keys in the Track Bar. |
Barycentric Morph controller
The Barycentric Morph controller is automatically applied when a morph compound object is created. Keys are created for this controller based on the morph targets set in the Modify panel under the Current Targets rollout for the morph compound object. You can edit these keys using the Barycentric controller Key Info dialog box, which you can open by right-clicking a morph key in the Track View or in the Track Bar.
The main difference between the Cubic Morph controller and the Barycentric Morph controller is that the latter can have weights applied to the various morph keys.
The Barycentric Morph controller Key Info dialog box includes a list of morph targets. If a target is selected, its Percentage value sets the influence of the target. The Time value is the frame where this key is located. The TCB values and displayed curve control the Tension, Continuity, and Bias parameters for this controller. The Constrain to 100% option causes all weights to equal 100 percent; changing one value changes the other values proportionally if this option is selected.
Block controller
To add a Block controller, select the Available track under the Block Control track under the Global Tracks track, and click the Assign Controller button. From the Assign Constant Controller dialog box that opens, select Master Block (Master Block is the only selection) and click OK. Right-click the Master Block track and select Properties to open the Master Block Parameters dialog box, shown in Figure 32.28.
In the Master Block Parameters dialog box, you can add a track to the Block controller with the Add button. All tracks added are displayed in the list on the left. You can give each track a name by using the Name field. You can also use the Add Selected button to add any selected tracks. The Replace button lets you select a new controller to replace the currently selected track. The Load and Save buttons enable you to load or save blocks as separate files.
The Add button opens the Track View Pick dialog box, shown in Figure 32.29. This dialog box displays all valid tracks in a darker color to make them easier to see, while graying out invalid tracks.
Select the tracks that you want to include, and click the OK button. The Block Parameters dialog box opens, shown in Figure 32.30, in which you can name the block, specify Start and End frames, and choose a color. Click OK when you've finished with this dialog box.
Back in the Master Block Parameters dialog box, click the Load button to open a file dialog box where you can load a saved block of animation parameters. The saved block files have the .BLK extension. After the parameters have loaded, the Attach Controls dialog box opens, as shown in Figure 32.31. This dialog box includes two panes. The Incoming Controls pane on the left lists all motions in the saved block. By clicking the Add button, you can add tracks from the current scene, to which you can copy the saved block motions.
Because the saved motions in the Incoming Controls pane will match up with the Copy to entries in the right pane, the Add Null button adds a space in place of a specific track if you don't want a motion to be copied. The Match by Node button matches tracks by means of the Track View Pick dialog box.
IK controller
The IK controller works on a bones system for controlling the bone objects of an IK system. The IK controller includes many different rollouts for defining joint constraints and other parameters.
CROSS-REF | Find out more about the IK controller in Chapter 39, "Understanding Rigging and Working with Bones." |
Master Point controller
Right-clicking a green master key opens the Master Track Key Info dialog box, shown in Figure 32.32. This dialog box shows the Key number with arrows for selecting the previous or next key, a Time field that displays the current frame number, and a list of all the vertices. Selecting a vertex from the list displays its parameters at the bottom of the dialog box.
Figure 32.33 shows the Master Point controller that was automatically assigned when a selection of vertex subobjects was moved with the Auto Key button enabled. A separate track is created for each vertex.