Using Stencils
Stencils allow you to use one layer as a matte for another. Transformations to the stencil layer affect the way the front layer and back layer are composited.
The stencil's effect on the front layer changes depending on the relative position of the stencil with respect to the front layer. So, if you rotate the stencil layer 90 degrees, the composite will change to reflect the transformations applied to the stencil layer.
To apply a stencil to a layer:
- Load a front layer, a back layer, and a matte layer.
- In the Workspace panel, stack the layers so the front layer is on top of the back layer. The matte layer can be anywhere in the stack.
- In the Workspace panel, select the front layer.
- In the Composite Controls panel, click Surface.
For 2D composites, this feature is in the Layer controls.
- Under the Stencil Layer heading, select Matte from the Stencil Layer list.
Note: You can also click the Pick button and then click the matte layer in the active viewport.
- Do one of the following:
- Click Alpha to apply the matte layer's alpha channel to the front layer.
Note: You can only use this option if the matte layer contains an alpha channel.
- Click Luma to create a matte from the luminance values of the matte layer. Use this option when the matte layer is an 8-bit grayscale clip.
- Click Invert to either create a matte from inverted luminance values of the matte layer or invert the matte itself. The following illustration shows the effects of an inverted luma stencil.
Note: Stencil layers are automatically hidden from view because their Invisible to Rays and Invisible to Camera settings are turned on when you apply the stencil. You do not need to turn the matte layer's visibility icon off before applying the stencil.