Skip to content

Mask Paint

Node icon
Mask

Paint masks freehand with a brush. Quick and intuitive for organic selections.

Mask Paint lets you paint a mask directly by hand. The Brush tool paints white (adds to mask), and the Eraser paints black (removes from mask). Brush size, hardness, and opacity are all adjustable.

Mask Paint accepts two optional inputs: an image (for dimensions, overlay display, and alpha extraction) and a mask (for direct mask combination). When either input is connected, a combine mode selector appears. Connect the mask pin directly to combine with another mask node’s output (labeled “Input Mask”), or connect just an image to combine with its alpha channel (labeled “Input Alpha”). Combine modes include Replace (default), Union (add together), Subtract (remove from input), Intersect (keep overlap), and Difference. Without any input, you start with a blank canvas. The global invert toggle flips the entire output.

Pins

ImageImage
InputOptional
MaskMask
InputOptional
MaskMask
Output

Output

Width (px)Integer
Default: 1024 Range: 1–8192

Output mask width (locked when image input is connected)

Height (px)Integer
Default: 1024 Range: 1–8192

Output mask height (locked when image input is connected)

Strokes

ToolChoice
Default: 0 Range: Brush / Eraser

Active editing tool (Brush adds, Eraser subtracts)

Brush SizeNumber
Default: 20.0 Range: 1.0–500.0

Brush diameter in pixels

Brush HardnessNumber
Default: 1.00 Range: 0.00–1.00

Edge hardness (0 = soft falloff, 1 = hard edge)

Brush OpacityNumber
Default: 1.00 Range: 0.00–1.00

Stroke opacity per dab

StrokesData
Default: []

Stroke list (recorded via the canvas manipulator)

Global

OverlayToggle
Default: true

Show the mask as a tinted overlay on the input

Combine ModeChoice
Default: Replace

How painted strokes combine with the input alpha or mask

  • ReplacePainted strokes replace the input mask entirely.
  • UnionAdd painted regions to the input mask — white wherever either is white.
  • SubtractRemove painted regions from the input mask.
  • IntersectKeep only the overlap between painted strokes and the input mask.
  • DifferenceKeep non-overlapping areas between painted strokes and the input mask.
InvertToggle
Default: false

Invert the entire mask output

  • Use a soft brush (low hardness) for gradual, feathered selections.
  • Reduce opacity to build up mask density gradually with multiple strokes.
  • Paint on top of an AI-generated mask to fix edges that need manual correction.
  • Use Union mode to add painted regions to an existing mask, or Subtract to carve out areas from it.
  • Connect a mask input directly to combine with another mask node’s output, or connect an image to work with its alpha channel.