Chapter 21: Moving Layers

Moving Layers

The Motion Book Tool offers three types of motion effects to move layers: Slide In, Slide Out, and the more general-purpose Move. Each motion effect defines a start location and end location for a layer, sets progression quality for the motion, and then moves the layer accordingly during playback. Because the effect types each have a different purpose, they define start location, end location, and progression quality in different ways.

Locations

A layer with an attached motion effect has three different locations to consider:

lIts origin, which is the original location specified in the layer box by its Left and Top margin values. This is the position you set when you first create a layer without effects.

lIts end location, which is the location of the layer when a motion effect ends.

lIts start location, which is the location of the layer when a motion effect starts. If the layer hasn’t been moved by another effect, the start location is the layer’s origin. If the layer has been moved previously, the start location is the end location of the previous effect. One exception: the Slide In effect, which determines its own start location as described later.

You don’t need to think much about these different locations for simple uses of the motion effects. But if you combine effects or set a sequence of Move effects, it’s important to know how each effect determines a layer’s start location, and what the layer’s end location is after each effect executes.

Using Slide In Effects

A Slide In effect is an easy way to make an entrance: it moves a layer from an invisible location off the canvas onto the canvas where the reader can view the layer. If you apply a Slide In effect to a child layer, it moves the child layer from an invisible location outside the parent layer into a visible location inside the parent layer, useful for sliding an object into a panel on a page.

The Slide In effect should be a layer’s only motion effect. If you precede or follow Slide In with a Move or Slide Out effect you may get unpredictable results. If you want a sequence of multiple moves that may include slides, it’s best to implement the moves and slides using a series of Move effects.

To Add a New Slide In Effect

1.Add a new Slide In effect just as you do any effect as described in “Adding an Effect to a Page” on page 56.

At one point in the process, a dialog box asks for Slide-In-specific information: “From which direction should the layer slide in?”

2.Choose any one of the four direction choices: from the left, right, top, or bottom of the canvas or parent layer.

Start and End Locations

Slide In is designed to be very simple: you don’t directly specify start and end locations for a Slide In effect—the effect determines them automatically once you specify the slide direction.

The end location is the layer’s origin.

The start location is the end location plus the width of the canvas if sliding left or right, or the end location plus the height of the canvas if sliding up or down.

If the layer you’re sliding is a child layer of a parent layer, then the slide in is calculated using the parent layer margins instead of the canvas: the start location is the end location plus the width or height of the parent layer.

The start location is guaranteed to locate the layer where the layer won’t be visible: off the canvas or (if it’s a child layer) outside the margins of the parent layer.

Layer Invisibility Before the Effect

To ensure that the Slide In effectively reveals its layer without showing the layer prematurely, the Motion Book Tool sets the target layer to be invisible before a Slide In effect, even if the layer has other applied effects before the Slide In. It’s best not to apply any other effects before a Slide In effect because you won’t see those effects.

Changing Start and End Locations

Change the start location of a layer in a Slide In effect by changing the layer’s origin. You can change the Left and Top margin values in the layer box controls, or you can drag the layer on the canvas to a new position.

If you drag the layer on the canvas, it’s best to drag the layer when the timeline cursor is either before or after the effect. In either of these locations the layer will be in its origin location so it’s easy to see how you’re setting the end location.

If you drag the layer when the timeline cursor is in the middle of the effect, the layer will be in transition from the start location to the end location. Your dragging offsets the origin by the amount you drag—it does not set a new mid-point location in the slide-in. For example, if you drag the layer midway through a slide-in up by 100 pixels and to the right by 100 pixels, the origin will move up and to the right by 100 pixels each.

Changing the Slide Direction

The Slide In effect box has one effect-specific control that you can set once the effect is in place: the “Slide in from” pull-down. Choose left, right, top, or bottom to change the direction of the slide in for the layer. The direction determines the start location of the effect which is calculated as described earlier.

Standard Effect Controls

You can set a Slide In effect’s name, offset, duration, target frame, and progression as described in “Working With Effect Controls” on page 139.

Making the duration shorter speeds up the motion of the slide, making the duration longer slows down the motion.

Set the effect progression in the Motion pull-down, which determines how the layer moves along a straight line from its start location to its end location.

Using Slide Out Effects

A Slide Out effect is a simple way to retire an object from the page: it slides the object off the canvas or a parent layer so that it’s no longer seen.

The Slide Out effect should be a layer’s only motion effect. If you precede or follow Slide Out with a Move or Slide In effect you may get unpredictable results. If you want a sequence of multiple moves that may include slides, it’s best to implement the moves and slides using a series of Move effects.

To Add a New Slide Out Effect

1.Add a new Slide Out effect just as you do any effect as described in “Adding an Effect to a Page” on page 56.

At one point in the process, a dialog box asks for Slide-Out-specific information: “To which direction should the layer slide out?”

2.Choose any one of the four direction choices: to the left, right, top, or bottom of the canvas or parent layer.

Start and End Locations

Slide Out, like Slide In, is designed to be very simple: you don’t directly specify start and end locations for a Slide Out effect—the effect determines them automatically once you specify the slide direction.

The start location is the layer’s origin.

The end location is the start location plus the width of the canvas if sliding left or right, or the end location plus the height of the canvas if sliding up or down.

If the layer you’re sliding is the child layer of a parent layer, then the slide out is calculated using the parent layer margins instead of the canvas: the start location is the end location plus the width or height of the parent layer.

The end location is guaranteed to locate the layer where the layer won’t be visible: off the canvas or (if it’s a child layer) outside the margins of the parent layer.

Layer Invisibility After the Effect

To ensure that the Slide Out effectively conceals its layer after sliding, the Motion Book Tool sets the target layer to be invisible after a Slide Out effect, even if the layer has other applied effects after the Slide Out. It’s best not to apply any other effects after a Slide Out effect because you won’t see those effects.

Changing Start and End Locations

Change the start location of a layer in a Slide Out effect by changing the layer’s origin. You can change the Left and Top margin values in the layer box controls, or you can drag the layer on the canvas to a new position.

If you drag the layer on the canvas, it’s best to drag the layer when the timeline cursor is either before or after the effect. In either of these locations the layer will be in its origin location so it’s easy to see how you’re setting the start location.

If you drag the layer when the timeline cursor is in the middle of the effect, the layer will be in transition from the start location to the end location. Your dragging offsets the origin by the amount you drag—it does not set a new mid-point location in the slide-in. For example, if you drag the layer midway through a slide-out up by 100 pixels and to the right by 100 pixels, the origin will move up and to the right by 100 pixels each.

Changing the Slide Direction

The Slide Out effect box has one effect-specific control that you can set once the effect is in place: the “Slide out to” pull-down. Choose left, right, top, or bottom to change the direction of the slide out for the layer. The direction determines the end location of the effect which is calculated as described earlier.

Standard Effect Controls

You can set a Slide Out effect’s name, offset, duration, target frame, and progression as described in “Working With Effect Controls” on page 139.

Making the duration shorter speeds up the motion of the slide, making the duration longer slows down the motion.

Set the effect progression in the Motion pull-down, which determines how the layer moves along a straight line from its start location to its end location.

Using Move Effects

A Move effect is a general-purpose motion effect that gives you more control than the slide effects, which are shortcuts for a common movement. A Move effect lets you set both the start and end points and it controls progression along both vertical and horizontal axes. You can create a sequence of Move effects to move a single layer in different directions at different times and speeds.

Adding a New Move Effect

Add a new Move effect just as you do any effect as described in “Adding an Effect to a Page” on page 56. You don’t need to set any effect-specific values during creation; you set the effect once it’s in place using controls in the effect box.

Start and End Locations

A Move effect by default does not move a layer at all because its Horizontal and Vertical move values in the effect box are set to 0. You can specify a Horizontal value to move the layer that many pixels to the right, or a Vertical value to move the layer that many pixels down, or both to move diagonally. A positive value moves right or down, a negative value moves left or up.

A Move effect’s start location is the layer’s origin or, if there’s a previous Move effect, the end location of the previous effect.

A Move effect’s end location is the start location plus the Horizontal move and Vertical move values. If, for example, a layer has a start location of left margin 200 and top margin 100 (200, 100 for short) and the Horizontal move value is 50 and the Vertical move value -75, then the end location will be 200+50, 100-75 for a resulting end location of 250, 25. The movement from start to end moves diagonally up and to the right.

If you create a series of Move effects linked to a single layer, each effect adds its Horizontal and Vertical move values to the previous end location, so the final end location is the origin location plus the sum of all move values.

Changing Start and End Locations

If you have a single Move effect tied to a layer, change the Move effect’s start location by changing the layer’s origin. You can do that by setting the Left and Top margin values in the layer’s layer box or by using the canvas as described later.

If you have a sequence of two or more Move effects tied to the same layer, changing the layer’s origin specifies the start location for the first Move effect. Each Move effect after that is set by the previous Move effect’s end location, so shifting the origin on the canvas will shift all subsequent Move effects by the same amount.

If you change the move values for any Move effect in a sequence of Move effects, you change the end location for the Move effect. That in turn shifts the start point of all subsequent Move effects by the same amount, so changing move values for one Move effect shifts all later layer moves by the same amount.

Changing Start and End Locations on the Canvas

If you’d like to change a Move effect’s start and end locations by dragging its layer on the canvas, specify which location you want to change by placing the cursor on the timeline.

To Set a New Start Location By Dragging the Layer

1.Put the timeline cursor at or before the beginning of the Move effect bar.

If another Move effect precedes this one for the layer, the cursor must be after end of the previous Move effect. You can’t drag a layer when the cursor is in the middle of an effect.

2.Drag the layer to a new start position.

If this is the first Move effect applied to the layer, the layer box top and left margin values change to show the new start position as the layer’s origin.

If another Move effect precedes this Move effect for the layer, the drag doesn’t affect the layer’s origin, but instead sets the end location of the previous Move effect, which resets the Horizontal and Vertical move values of the previous Move effect.

To Set a New End Location By Dragging the Layer

1.Put the timeline cursor at or after the end of the Move effect bar.

If there is another Move effect applied to the layer after this effect, the cursor must be before the start of the next effect. You can’t drag a layer when the cursor is in the middle of an effect.

2.Drag the layer to a new end position.

The Move effect’s Horizontal and Vertical move values change to reflect the new end location. Note that if there’s another Move effect following this one, this new end location is the start location for the next effect as described earlier.

Changing Progression Quality (Easing)

Like other effects, the Move effect offers control of progression. But unlike other effects, the Move effect offers two progression controls instead of one: Vertical easing and Horizontal easing. Each of these pull-downs offers the standard progression settings described in “Changing Effect Progression (Movement or Easing)” on page 141.

Vertical easing affects motion along the vertical axis of the effect; it has no effect on horizontal motion. Horizontal easing does just the opposite: affects horizontal motion and not vertical motion. There’s no reason to use both settings unless the Move effect moves diagonally and has both a vertical and horizontal component.

The best way to figure out how the two easing settings work on diagonal motion is experimentation. You might find, for example, that setting Horizontal easing to Quartic at start and Vertical easing to Quartic at end turns a diagonal move into a curved move.

Standard Effect Controls

You can set a Move effect’s name, offset, duration, and target frame as described in “Working With Effect Controls” on page 139.

Making the duration shorter speeds up motion, making it longer slows down motion.