Draw a path using Shape or Pen tool. Drawing a mask path is similar to drawing a shape path.
Learn more about creating a shape or mask by dragging with shape tools and creating a Bezier shape or mask using the Pen tool.
You can create shapes and masks with the Rectangle and Pen tool in After Effects. When you create a mask or shape layer, keep the following things in mind:
Shortcuts for the Shape tool is Q, and the Pen tool is G.
You can create one or more masks for each layer in a composition using any of the following methods:
Draw a path using Shape or Pen tool. Drawing a mask path is similar to drawing a shape path.
Learn more about creating a shape or mask by dragging with shape tools and creating a Bezier shape or mask using the Pen tool.
Specify the dimensions of the mask path numerically in the Mask Shape dialog box.
Learn how to create a rectangular or elliptical mask numerically.
Convert a shape path to a mask path by copying the shape’s path to the Mask Path property.
Convert a motion path to a mask path.
Learn more about creating a mask or shape from a motion path.
Trace color or alpha channel values to create a mask using the Auto-trace command.
Learn more about creating a mask from a channel with Auto-trace.
Paste a path copied from another layer or from Adobe Illustrator or Photoshop.
Learn more about copying a path from Illustrator or Photoshop.
Convert a text layer to one or more editable masks on a solid-color layer by using the Create Masks From Text command.
Learn more about creating shapes or masks from text characters.
Use captured shapes to create motion graphics.
Learn more about using captured shapes to create motion graphics.
Create the mask on a separate white solid layer, and use that solid layer as a track matte for the primary layer.
Use parenting to make the solid layer a child of the primary layer so that the mask moves with the primary layer as if applied directly. Because the solid layer is a child layer, it can also be animated independently of its parent.
You can use motion tracking to make the solid layer (and, therefore, the mask) follow moving objects in the primary layer. Learn about converting a layer into a track matte and parent and child layers.
The shape tools are the Rectangle , Rounded Rectangle , Ellipse , Polygon , and Star tools.
To activate and cycle through the shape tools, press Q.
A polygon is a star without an Inner Radius or Inner Roundness property. So, the name of the shape created for a polygon or a star is the same: polystar.
You can create a mask by dragging with a shape tool on a selected layer in the Composition or Layer panel.
To draw a mask on a shape layer, select the Tool Creates Mask button in the Tools panel with a shape tool active.
Select a layer in the Composition panel or display a layer in the Layer panel.
Select Layer > Mask > New Mask. A new mask appears in the Composition or Layer panel with its handles at the outer edges of the frame.
Select Layer > Mask > Mask Shape.
Select Reset To, choose Rectangle or Ellipse from the Shape menu, and specify the size and location of the bounding box for the mask.
You can convert the alpha, red, green, blue, or luminance channel of a layer to one or more masks by using the Auto-trace command. Auto-trace creates as many Bezier masks as necessary to outline the specified channel values in the layer. It also creates masks with the smallest number of vertices possible while conforming to the settings that you choose. You can modify a mask created with Auto-trace as you would any other mask, and you can link its path to other path types, such as shape paths on a shape layer, using expressions.
When you apply Auto-trace, affected layers are automatically set to Best Quality to ensure accurate results.
To reduce the number of masks created by Auto-trace, apply a keying effect to the layer to isolate your subject before applying Auto-trace.
In the Timeline panel, do one of the following:
Select one or more layers and choose Layer > Auto-trace.
Current Frame
Creates mask keyframes at only the current frame.
Work Area
Creates mask keyframes for frames within the work area.
Once done, select from any of the following options:
Invert: It inverts the input layer before searching for edges.
Blur: It blurs the original image before generating the tracing result. Use it to reduce small artifacts and to smooth jagged edges. Deselect this to closely trace details in a high-contrast image.
Tolerance: How far, in pixels, the traced path is allowed to deviate from the contours of the channel.
Threshold: Specifies, as a percentage, the value that a pixel’s channel must have for that pixel to be part of an edge. Pixels with channel values over the threshold are mapped to white and are opaque; pixels with values under the threshold are mapped to black and are transparent.
Minimum Area: Specifies the smallest feature in the original image that is traced. For example, a value of 4 removes features smaller than 2 pixels wide by 2 pixels high from the tracing result.
Corner Roundness: Specifies the roundness of the mask curve at vertices. Enter a higher value for smoother curves.
Apply To New Layer: Applies the mask to a new solid the same size as the selected layer. It's automatically selected for layers that have Collapse Transformations enabled.
Preview: Select to preview the mask results and the results of the various options of the Auto-trace command.
Select the destination for the new mask:
In the Tools panel, double-click the Rectangle , Rounded Rectangle , Ellipse , Polygon , or Star tool.
The Create Shapes From Text command extracts the outlines for each character, creates shapes from the outlines, and puts the shapes on a new shape layer. You can then use these shapes as you would any other shapes. It extracts the outlines for each character, creates masks from the outlines, and puts the masks on a new solid-color layer. You can then use these masks as you would any other masks.
You can copy position keyframes, anchor point keyframes, or an effect control point's position keyframes and paste those keyframes into a selected mask path or shape path. When you create mask paths or shape paths from motion paths, make sure that you copy keyframes from a single Position property only—don't copy the keyframes of any other property.
Draw a motion path with Motion Sketch (Enable the panel by selecting Windows > Motion Sketch) and then paste the path into a mask path or shape path.
When copying between a mask path to a motion path, keep in mind that the mask path’s values are expressed in the coordinate system of the layer (layer space), whereas the motion path’s values are expressed in the coordinate system of the composition (composition space). This difference causes the pasted path to be offset, requiring you to reposition the path after pasting it. Learn more about coordinate systems – composition space and layer space.
In the Timeline panel, select the name of the Position property or Anchor Point property from which you want to copy the motion path. This selects all keyframes. However, to select only some of the keyframes of a motion path, Shift+click them.
Select Edit > Copy.
To create a mask, select the layer on which to create the mask, and select Layer > Mask > New Mask.
In the Timeline panel, select the name of the Mask Path property for the mask into which to paste the keyframes from the motion path.
Select Edit > Paste.