|
|
Example: Animate text position with expressions
This example uses the textIndex and textTotal attributes
with the wiggle expression to animate a line of
text.
- Create a new composition.
- Create a new text layer.
- Expand the text layer in the Timeline panel to view the
text properties. Add a Position animator group from the Animate
menu.
- Delete the default Range selector, Range Selector 1.
- Add an Expression selector by selecting the Add menu,
then choosing Selector > Expression. Expand the Expression
selector to reveal its options.
- Expand the Amount property to reveal the expression.
The following expression appears by default:
selectorValue * textIndex/textTotal
- Replace the default expression with the following expression:
seedRandom(textIndex);
amount=linear(time, 0, 5, 200*textIndex/textTotal, 0);
wiggle(1, amount);
The linear method
is used in this example to ramp down the maximum wiggle amount over
time.
- Set the vertical position value. The greater the value,
the more the characters wiggle.
- Preview your composition.
|