Faragiri
English

Choose a language 2

Learn Masks and mattes After Effects

The four mask modes, what feather and expansion each do to an edge, and the rule that decides between a path and a matte. Worked on a title sequence in Tartu.

6Sections
4Min read
4Depth

Recommended Before This

0 / 2

A mask is a path that lives on the layer it cuts. A track matte is a different layer, sitting directly above, whose alpha or brightness decides what shows through. The choice between them is not stylistic: a shape you can draw belongs in a mask, and a shape that already exists as an image belongs in a matte, and using the wrong one turns a ten minute job into an afternoon.

Priit builds a title sequence for a chamber choir in Tartu: a photograph revealed through the shape of a doorway, type wiping on behind a moving arm, and a logo appearing through a smear of ink.

The four mask modes, and the one that gets forgotten

Add shows what is inside the path. Subtract shows everything except it. Intersect shows only what is inside both this mask and the ones above it, and Difference shows the parts covered by an odd number of masks, which is how a ring is made from two circles without any of them being subtracted.

Top-down evaluation

The four mask modes and why list order decides the cut

Each mask acts on the combined result of the masks stacked above it in the layer list.

  1. AddShows everything inside the path; two Add masks combine into a single unionunion
  2. SubtractHides its interior, cutting a hole out of whatever Add masks sit above itpunch
  3. IntersectKeeps only the region inside both this mask and the masks above itoverlap
  4. DifferenceShows areas covered by an odd number of masks, turning two circles into a ringodd count

A mask that appears to do nothing is almost always sitting in the wrong order relative to the masks above it.

Live Web Audio Synth, 3-Band EQ & Compressor Lab

Synthesize live audio, sculpt 3-band EQ & compression, and watch the 60fps FFT spectrum.

Order matters, because each mode acts on the result of the masks above it in the list. Two masks both set to Add is a union; the second set to Subtract punches the first. A mask that appears to do nothing is almost always in the wrong position in that list.

Feather, expansion, and the difference nobody explains

Feather softens the edge symmetrically about the path, so a 20 pixel feather takes 10 pixels inside and 10 outside. Expansion moves the edge itself outward or inward without softening it, which is how a hard edge is choked in by two pixels to remove a bright fringe.

Edge geometry

How expansion shifts the cut before feather softens it

Feather spreads symmetrically across the path, while expansion moves the edge inward first so background fringe stays outside.

  1. Subject inside the pathInward expansionChokes the hard boundary inward by two pixels to drop any bright background fringe
  2. 02Symmetrical featherSplits softness evenly across the moved edge, 10 pixels in and 10 out for a 20 pixel feather
  3. 03Outside plate pixelsExcluded from the soft transition instead of bleeding into the cut

Choke inward by two pixels and feather by three so a hand-drawn mask sits cleanly against a photograph.

The pair is what makes a hand-drawn mask sit against a photograph: expand inward by two, feather by three, and the cut stops looking like a cut. Feather alone on an unexpanded mask leaves the original edge in the middle of the soft band, and that band contains whatever was outside the shape.

Mattes, and the layer that is switched off

A track matte uses the layer immediately above, and that layer is switched off in the composition, which is the thing that confuses everybody the first time: it is invisible and it is still doing all the work.

Hidden driver layer

Choosing Alpha matte or Luma matte on the layer above

A track matte turns off the visibility of the upper layer while reading either its transparency or its brightness.

What channel on the hidden upper layer carries the shape?
  • Transparency already exists
    Alpha matteUses the upper layer's alpha channel to cut the layer below
    • Upper layer stays switched off automatically
    • Opaque areas reveal the layer underneath
    • Use inverted alpha instead of redrawing artwork
  • Brightness defines the shape
    Luma matteWhite shows and black hides without drawing a single path
    • Ideal for filmed ink on white paper
    • Preserves natural texture and soft edges
    • Invert the matte if black and white are flipped

Remember that the matte layer sits directly above and remains invisible while doing all the cutting.

Alpha matte uses the upper layer's transparency, so a shape with an alpha channel cuts the layer below it. Luma matte uses its brightness, so white shows and black hides, which is how a smear of ink photographed on white paper becomes a reveal without anybody drawing a path. Both have an inverted version, and inverting the matte is more often the answer than redrawing the artwork.

Which one for which job

The doorway is a mask: a path with six points, drawn in a minute, animated if the camera moves. The arm is a matte, because an arm is not a shape anybody wants to draw for ninety frames; the arm comes from a rotoscoped layer or from a luma pass. The ink is a matte, because the ink already exists as a filmed element with its own edges and softness, and no drawn path would have that edge.

One title sequence, three reveals

A drawn path and a borrowed image, on the rows that decide

No row is marked, because the doorway wants the left column on all six and the ink wants the right column on all six.

A maskA path on the layer it cuts
A track matteA layer above, switched off, doing the work
Where it livesOn the layerOn the layer above it
Made ofPoints you placeAn image that already exists
Edge qualityFeather and expansion, both uniformWhatever the source image has
A shape with six cornersA minuteNeeds artwork made first
An arm across ninety framesAn afternoonRoto or a luma pass
Ink spreading on paperCannot be reproducedFour seconds

The last three rows are one question asked three times: does an image of this shape already exist. It is faster to answer than any of the six is to attempt.

The general rule falls out of it: if drawing the shape by hand is faster than producing an image of the shape, use a mask. Otherwise use a matte.

Two things worth using in 2026

Roto Brush, which segments a moving subject from its background over a range of frames and propagates the selection, replaced rotoscoping an arm frame by frame, which is an afternoon for ninety frames. It is included, and its honest limit is the edge: it produces a good matte in seconds and a matte with a chattering edge, so the pass afterwards is about stabilising the edge rather than about finding the subject.

Built-in automation

Two matte and mask tools worth using in 2026

Both are included in the application and draw a clear boundary between rigid surfaces and moving subjects.

2026 cutout and tracking tools
  • Roto BrushSegments a moving arm in seconds, then requires an edge-stabilising pass to calm chatter
  • Mask reference trackingLocks a drawn mask to a planar track on flat surfaces, but fails on anything that bends

Choose by whether the shape bends or stays planar

Let planar tracking carry rigid geometry and save Roto Brush for organic motion where paths fail.

Mask reference tracking is the smaller and more reliable one: attach a mask to a planar track and it follows a surface that is moving in the plate. It replaced keyframing a six point path across a moving shot, and it is included wherever a planar tracker is. It works on flat surfaces and fails on anything that bends, which is exactly the boundary between the two techniques on this page.

The mistake, made on the ink

Priit drew a mask around the ink smear, frame by frame, for forty frames, because the ink was a shape and a shape is a mask. The ink is a filmed element on white paper with soft, spreading edges and small satellites of spray, none of which a hand path reproduces, and the result is a hard edged blob that moves like ink and does not look like it. Dropping the same clip in as a luma matte took four seconds, kept every soft edge and every speck, and threw away four hours. The question was never what shape the ink is. It was whether an image of the shape already existed.

Four hours vs four seconds

Why hand-masking filmed ink fails before the first frame

Treating an existing filmed texture as a drawing problem wastes hours and destroys the edge quality.

Always ask whether an image of the shape already exists before placing your first mask point.

The order in which a mask, an effect and a transform are applied to the same layer is the standard tool for motion and compositing, and the panel where the mask path becomes an animated property is animating a property, and the graph editor. Cutting a subject out of a plate frame by frame, when no matte can be generated, is cutting a subject out frame by frame. And making the cut-out element sit inside the plate afterwards is layers, light wrap and making it belong.

Alongside this

Above this