LookAt Constraint

The LookAt constraint controls an object’s orientation so that it’s always looking at another object or objects. It locks an object’s rotation so that one of its axes points toward the target object, or the weighted average of target positions. The LookAt axis points toward the target, while the Upnode axis defines which axis points upward. If the two coincide, a flipping behavior can result. This is similar to pointing a target camera straight up.

LookAt constraints enable the antenna dishes to track the satellite.

An example of a LookAt constraint’s use would be to constrain the eyeballs of a character to a Point helper. The eyes then always aim at the Point helper. Animate the helper object and the eyes follow. Even if you rotate the character’s head, the eyes maintain their lock on the Point helper.

Multiple Targets and Weighting

A constrained object can be influenced by several target objects. When using multiple targets, each target has a Weight value that defines the extent to which it influences the constrained object, relative to other targets.

Using Weight values is meaningful (and available) only with multiple targets. A value of 0 means the target has no influence. Any value greater than 0 causes the target to influence the constrained object relative to other targets' Weight settings. For example, a target with a Weight value of 80 has twice the influence of a target with a Weight value of 40.

Procedures

To assign a LookAt constraint:

  1. Select the object you want to constrain. This is the object that will be always looking at its target.
  2. Choose Animation menu Constraints LookAt Constraint.

    A rubber-band line extends from the constrained object to the mouse cursor.

  3. Click the target object.

To access the LookAt constraint’s parameters through the Motion panel:

  1. Select the LookAt Constrained object.
  2. On the Motion panel PRS Parameters rollout, click the Rotation button.

    The LookAt constraint parameters are located under the LookAt Constraint rollout.

To edit weight values:

  1. Select the constrained object.
  2. On the Motion panel PRS Parameters rollout, click the Rotation button.

    The LookAt constraint parameters are located under the LookAt Constraint rollout.

  3. Click a target in the list.
  4. Use the Weight spinner or enter a numerical value to adjust the weight value.

To animate weight values:

  1. Select the constrained object.
  2. On the Motion panel PRS Parameters rollout, click the Rotation button.

    The LookAt constraint parameters are located under the LookAt Constraint rollout.

  3. Click a target from the list.
  4. Turn on (Auto Key).
  5. Use the Weight spinner or enter a numerical value to adjust the weight value.

Interface

Once you assign a LookAt constraint, you can access its properties on the LookAt Constraint rollout on the Motion panel. On this rollout, you can add or delete targets, assign weighting, assign and animate target weight values, and adjust other related parameters.

Note: When you assign a LookAt constraint via the Animation menu, 3ds Max assigns a Rotation List controller to your object. In the list on the Rotation List rollout, you will find LookAt Constraint, which is the constraint you assigned. To view the LookAt Constraint rollout, double-click the LookAt Constraint entry in the list.
Add LookAt Target
Use to add new targets that influence the constrained object.
Delete LookAt Target
Use to remove target objects that influence the constrained object.
[target list]
Shows the targes and their weights.
Weight
Use to assign and animate weight values for each target. Available only when multiple targets are used.
Keep Initial Offset
Maintains the constrained object’s original orientation as an offset to its constrained orientation.
Viewline Length
Defines the length of the main viewline drawn from the pivot of the constrained object to the pivot of its target (or the average, in case of multiple targets). A negative value draws the line from the constrained object in the opposite direction of the target or targets.

With a single target, the length of the viewline is determined by the distance between the constrained object and the target, as well as the Viewline Length setting. However, if Viewline Length Absolute is on, the distance between the two has no effect on the length.

The color of the viewline is defined by the Target Line element in the Gizmos category of the Colors panel in the Customize Customize User Interface dialog.

Note: When multiple targets are assigned, additional viewlines drawn from the constrained object to each target object inherit the color of the respective targets. If Viewline Length Absolute is on, the length of each target-specific line is determined by its target's Weight setting and the Viewline Length value. If Viewline Length Absolute is off, the length of each line is determined by the distance between the constrained object and the respective target, as well as the Viewline Length value. An additional (main) viewline, whose length and color are determined as specified above, indicates the actual, calculated orientation.
Viewline Length Absolute
When on, 3ds Max uses only the Viewline Length setting for the length of the main viewline; the distance between the constrained object and the target(s) has no effect.
Set Orientation
Lets you define the offset orientation of the constrained object manually. When on, you can use the Rotation tool to set the constrained object’s orientation. This orientation is then maintained as the constrained object looks at its target.
Reset Orientation
Sets the orientation of the constrained object back to the default. This is useful if you want to reset the constrained object’s orientation after having set the orientation manually.

Select LookAt Axis group

Use to define the axis that looks at the target. The X,Y,Z checkboxes reflect the constrained object's local coordinate system. The Flip checkbox reverses the directions of the local axes.

Select Upnode group

The default Upnode is the World. Turn off World to manually select an object that defines the Upnode plane. This plane is drawn from the constrained object to the Upnode object. If the LookAt Axis and the Upnode axis coincide, the constrained object will flip. Animating the position of the upnode object will move the upnode plane.

Upnode Control group

Lets you quickly flip between LookAt Upnode Control and Axis Alignment.

  • LookAt When chosen, the Upnode matches the LookAt target.
  • Axis Alignment When chosen, the Upnode Aligns to the object axis. Choose which axis (X, Y or Z) in the Source/Upnode Alignment group directly below Upnode Control.

Source/Upnode Alignment group

Source Axis
Chooses the constrained object’s axis that is to be aligned to the Upnode Axis. The Source Axis reflects the constrained object’s Local Axis. The Source Axis and LookAt Axis work together therefore the Axis used to define the LookAt Axis will be unavailable.
Aligned to Upnode Axis
Chooses the Upnode axis that the selected Source Axis aligns to. Note that the selected Source axis may or may not be able to completely align to the Upnode Axis.