Nodes/ComfyUI-TextureAlchemy/Single Multimatte Pass Applicator
ComfyUI Node

Single Multimatte Pass Applicator

Picking one object out of a render pass

By amtarr·Created 9 months ago·Updated 4 months ago· 58
Single Multimatte Pass Applicator
  • image
  • multimatte_mask
  • image
channelRed

If you've ever composited a 3D render, you know the multimatte pass: every object in the scene gets painted a distinct solid color so you can isolate it later. Single Multimatte Pass Applicator is the node that turns one of those passes into a usable mask - and applies it to your image in the same step. It's a niche tool, but for people doing render-pass compositing inside ComfyUI, it saves you from building the extract-and-multiply rig by hand.

How it works

You give it image (your render) and multimatte_mask (the pass). The channel selector picks how the mask gets derived from the pass:

  • Red, Green, Blue - use that color channel of the pass as the mask. With classic multimatte passes where each object is a pure R/G/B color, selecting the matching channel isolates exactly that object.
  • Luminance - converts the pass to grayscale and uses brightness as the mask. Handy when your pass is a single-color object on black: the object reads as bright, everything else as black.

The node extracts that channel, expands it to match the image's channel count, and multiplies - output = image * mask. Objects that are white in the mask survive, black areas get zeroed, and anti-aliased edges become soft alpha. That last part is usually exactly what compositing wants.

The honest take

This is a "one specific job, done simply" node. It's a straight multiply - there's no invert, no strength, no threshold slider. If the mask comes out with halos because your pass has spill or the object wasn't a pure channel color, you'll want to clean the pass up (or threshold it) before it gets here. For the common case - a clean multimatte pass, pick the channel, done - it's perfect.

Installing it

Part of amtarr/ComfyUI-TextureAlchemy - ComfyUI Manager "Texture Alchemy", or:

cd ComfyUI/custom_nodes
git clone https://github.com/amtarr/ComfyUI-TextureAlchemy

Restart, then right-click → Add Node → Texture Alchemist → Adjustment. No extra dependencies or models; it's channel slicing and a multiply on ComfyUI's bundled PyTorch.

Where people get burned

The classic failure is anti-aliased or blended object colors: a surface that shades across the channel boundary gives a mask with gray falloff, and multiplying it dims the object instead of isolating it. If your multimatte pass is soft, run it through a threshold first - or pick Luminance if the object is distinct from the background in brightness. And expect the pack's console banner on every run; that's just its logging style.

CategoryTexture Alchemist/Adjustment

Inputs (3)

NameTypeDefaultDescription
imageIMAGE
multimatte_maskIMAGE
channelCOMBORedWhich channel to use as the mask

Outputs (1)

NameTypeDescription
imageIMAGE