beautypg.com

Alter shapes with path operations – Adobe After Effects User Manual

Page 343

background image

Even-odd fill rule

Nonzero winding fill rule

To the top

Merge Paths

Offset Paths

Fill rules for shapes

A fill operation works by painting color in the area defined as inside a path. Determining what is considered inside a path is easy when the path is
something simple, like a circle. However, when a path intersects itself, or when a compound path consists of paths enclosed by other paths,
determining what is considered inside is not as easy.

After Effects uses one of two rules to determine what is considered inside a path for the purpose of creating fills. Both rules count the number of
times that a straight line drawn from a point crosses the path on its way out of the area surrounded by a path. The nonzero winding fill rule
considers path direction; the even-odd fill rule does not.

After Effects and Illustrator use the nonzero winding fill rule as the default.

Self-intersecting path with Fill Rule set to Non-Zero Winding Fill Rule (left) compared with Even-Odd Fill Rule (right)

If a line drawn from a point in any direction crosses the path an odd number of times, then the point is inside; otherwise, the

point is outside.

The crossing count for a line is the total number of times that the line crosses a left-to-right portion of the path minus

the total number of times that the line crosses a right-to-left portion of the path. If a line drawn in any direction from the point has a crossing count
of zero, then the point is outside; otherwise, the point is inside.

A more intuitive way to think of the nonzero winding rule is to think of a path as a loop of string. A point is considered outside the path if you
can put your finger at that point and then pull the string away without it being caught, wrapped around your finger.

Because the nonzero winding fill rule takes path direction into account, using this fill rule and reversing the direction of one or more paths in a
compound path is useful for creating holes in compound paths.

To reverse the direction of a path, click the Reverse Path Direction On button for the path in the Timeline panel.

Alter shapes with path operations

Path operations are similar to effects. These live operations act nondestructively on a shape’s path to create a modified path that other shape
operations (such as fills and strokes) can apply to. The original path is not modified. Because path operations are live, you can modify or remove
them at any time. Path operations apply to all paths above them in the same group; as with all shape attributes, you can reorder path operations
by dragging, cutting, copying, and pasting in the Timeline panel.

1. In the Composition panel or Timeline panel, select the shape group into which to add the path operation.

2. Choose a path operation from the Add menu in the Tools panel or the Timeline panel:

Combines paths into a compound path. (See

Merge Paths options

.)

Expands or contracts a shape by offsetting the path from the original path. For a closed path, a positive Amount value

expands the shape; a negative Amount value contracts it. The Line Join property specifies the appearance of the path where offset path
segments come together. A bevel join is a squared-off connection. A miter join is a pointed connection. The miter limit determines the
conditions under which a beveled join is used instead of a miter join. If the miter limit is 4, then when the length of the point reaches four
times the stroke weight, a bevel join is used instead. A miter limit of 1 causes a bevel join.

339

This manual is related to the following products: