🐳Mask_Color_V2
The mask colorizer that actually tints your selection — with blend modes
- mask
- background_image
- image
If 🐳Mask_Color V1 colors the background of your mask, 🐳Mask_Color_V2 (Mask Color Replace Advanced) colors the part you actually care about: the white selection region. And it does it properly - hex color input, four blend modes, opacity, and feathering. This is the one you reach for when you want to tint exactly the area a mask selects and leave the rest alone, which is a surprisingly common move in compositing.
The classic uses: turn a mask's selected region into a solid green or blue matte for keying workflows. Tint a face mask a soft red to preview an edit region before inpainting. Build a colored overlay at partial opacity to check alignment against the source image. Because it can feather the mask and blend with an optional background image, it doubles as a quick mask-preview-and-polish tool.
How it works
The node takes your mask, inverts it internally so the white region becomes the "active" area, optionally feathers the mask with a Gaussian blur (feather), then paints a color layer over it using the chosen blend_mode:
- replace - the color directly replaces the background in the mask's white region (scaled by
opacity). - multiply - multiplies background × color, a darkening blend. Good for rich tinting.
- overlay - a contrast-boosting blend that respects the background's midtones.
- soft_light - a gentle, filmic tint that mostly preserves the underlying image.
The opacity (0–1) controls how strongly the color lands, and feather (0–50) softens the mask edge so the tint fades out instead of hard-cutting.
Inputs and output
mask- the MASK.color_hex- the tint color as a hex string like#FF0000(default#000000).blend_mode- replace / multiply / overlay / soft_light.- Optional
background_image- what the non-selected area keeps (otherwise a white canvas). Auto-resized to the mask size. - Optional
opacity(default 1.0) andfeather(default 0).
Output: image (IMAGE) - the mask-as-tinted-image, ready for a preview, a composite, or a keying node.
The V1/V2 trap
Remember the direction of travel: V1 colors the black region, V2 colors the white region. If your tint lands on the wrong half, you grabbed the wrong node - that's the single most common confusion with this pair. Also, the feather here uses scipy's Gaussian filter, so that's the one dependency this node actually leans on (it's in the pack's requirements.txt).
Install
Standard Pond Nodes install:
ComfyUI Manager → search "Pond Nodes" (comfy_Pond_Nodes)
or:
cd ComfyUI/custom_nodes
git clone https://github.com/Pondowner857/comfy_Pond_Nodes
cd comfy_Pond_Nodes
pip install -r requirements.txt
Restart after. Torch, numpy, and scipy cover it - no models to download. Pack footnote: the README documents a console-spam conflict with comfyui_HiDream-Sampler if both are installed.
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| mask | MASK | — | |
| color_hex | STRING | #000000 | — |
| blend_mode | COMBO | 4 options: replace, multiply, overlay, soft_light | |
| background_imageopt | IMAGE | — | |
| opacityopt | FLOAT | 1.000–1 | — |
| featheropt | INT | 00–50 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |