The quickest and easiest way of animating an object along a path is by using the Set Path command and picking the curve to be used as the path. When you use this command, the animation is created for you. There’s no need to set keyframes—just set the start and end frames.
A percentage (perc) function curve is created with
your choice of spline (ease
|
Want to convert a path animation to translation? Plot the position of the path-animated object, then apply the result to the object or as an action in the animation mixer. See Plotting (Baking) Animation for more information. |
To animate an object along a path
1. Create a curve using any of the available tools in the Curve menu on the Model or Animate toolbars.
|
The parameterization of the curve has no effect on timing. |
2. Select the object you want to animate.
|
Make sure the selected object does not have compensation on when creating a path: this would key the offsets rather than path animation. For more information on compensation, see Creating Offsets between Constrained and Constraining Objects. |
3. Choose Create > Path > Set Path from the Animate toolbar.
4. In the dialog box that opens, enter the frame at which the object starts moving (Start Frame) and the frame at which the object reaches the end of the path (End Frame). By default, the object travels the full length of the path.
- If you want the object to move along the path at a constant speed, select Linear. Otherwise, the object will ease into and out of the animation.
- If you want the object’s X axis (by default) to stay aligned with the path’s slope, select Tangent. The constrained object’s axis is repositioned to point in the direction of the curve’s slope. As the object moves along the path, its X axis follows the curve’s slope. For more information on tangency constraints, see Tangency Constraints.
5. Click OK and pick the curve to use as the path. Keys are created at each end of the path, and the object’s intermediate position along the path is interpolated.
6. After you pick the path curve, the PathCns property editor opens, allowing you to manually adjust the settings.
The Path %age (percentage) slider is especially important for controlling how much of the curve is used as a constraining force on the selected object.
7. If you selected the Tangent option in the Apply Path dialog box, the Active option is selected on the Tangency page.
You can also set the X, Y, and Z values to define a vector along which the object’s center is aligned (the default is X). Set the appropriate slider to 1 to keep that axis tangent to the path.
• To modify the path timing, see Modifying the Path Timing; to modify the path curve itself, see Modifying the Path Curve or Trajectory.
• To remove the animation, see Removing Path or Trajectory Animation.
Example: Path through a City
This example shows you how to apply path animation to the camera and its interest.
Create a cityscape using cubes and a grid
1. Choose Get > Primitive > Polygon Mesh > Grid and Get > Primitive > Polygon Mesh > Cube to create objects for a cityscape.
2. Using Edit > Duplicate Multiple, create several copies of the cube. Scale them so that they are all different sizes and place them on the grid, using the illustration on the left as a reference.
Create a path for the camera and its interest
3. Choose Create > Curve > Sketch from the Model or Animate toolbar and draw a free form curve path that goes through the city.
Animate the camera along the path
4. Change the timeline’s End Frame to 300.
5. To select the camera, do one of the following:
- Open the explorer and select the camera.
or
- Click the camera in a viewport. If the camera
is hidden in a viewport, click the eye icon
in the viewport title bar and choose Cameras,
and then select the camera from the list.
6. Choose Create > Path > Set Path from the Animate toolbar. Use the default values for the start and end frames, select Linear, and click OK,
7. Pick the curve as the path.
8. Play back the animation. You will notice that the camera is following the path but the camera interest stays fixed.
Animate the camera’s point of interest on the path
9. Select the camera interest by clicking it in a viewport or the explorer.
10. Choose Create > Path > Set Path, and set the start and end frame values to –20 and 280. Pick the curve path.
11. Play back the animation. The camera interest is now traveling along the path slightly ahead of the camera.
SOFTIMAGE|XSI v.6.01