Skip to main content

Draw Mask

Draw Mask lets you paint the part of an image you want another Node to use. A mask is an image that marks those areas.

Connect an image to start painting. Studio saves each stroke as you finish it.

Draw Mask with a painted area over an illustrated sunset. Eleven numbered markers identify the painting surface, tools, controls, and mask thumbnail.

The light overlay marks the painted area. The thumbnail shows the mask without the source image; numbered markers identify the editor parts below.

Use the painting tools​

  1. Painting surface. Drag over the image to paint or erase. The overlay shows where you have painted.
  2. Brush. Select this tool to add areas to the mask.
  3. Eraser. Select this tool to remove areas from the mask.
  4. Show mask (M). Switch between the source image with its overlay and the mask alone.
  5. Invert mask preview (I). Reverse the thumbnail's light and dark areas for inspection. This leaves the output mask unchanged.
  6. Clear. Remove the entire mask and start again.
  7. Size. Drag the slider or enter a value to change the brush width.
  8. Hardness. Use a lower value for softer edges or a higher value for sharper edges.
  9. Color. Choose an overlay color that stands out against the source image. This changes the display only.
  10. Transparency. Adjust how much of the source image shows through the overlay. This changes the display only.
  11. Mask thumbnail. Check the painted coverage without the source image. White includes an area, black excludes it, and gray gives partial coverage.

Paint a mask​

  1. Add Draw Mask to your Graph.
  2. Connect an image from Image Input or another Node to Image.
  3. Select Brush in Draw Mask.
  4. Paint over the area you want to include.
  5. Select Show mask (M) to check the mask without the source image.

Apply the mask​

  1. Connect Draw Mask's Mask output to Mask on Mask Image.
  2. Connect the same source image to Image on Mask Image.
  3. Set Mask Image's Background to Transparent to hide the unpainted area.
  4. Select Mask Image.
  5. Select Run Selected.

If a Run reaches Draw Mask before a mask is ready, Studio waits for you to paint. Select Continue when the mask is ready to use it in the waiting Run.

Make a sunset cutout​

Image Input connects an illustrated landscape to Draw Mask and Mask Image. The painted area around the sun becomes a small cutout in Mask Image's simulated output preview.

Draw Mask used to make a sunset cutout with Mask Image (illustrative media and simulated output).

Inputs and outputs​

Inputs
Image Image
The image you want to paint over.
Outputs
Mask Image
A grayscale mask with the source image's width and height.

The mask belongs to the source image you painted over. When that source changes, paint a new mask before running connected Nodes. Studio cannot reuse the old mask because it no longer matches the current source.

  • Mask Image — keep the painted area and replace the rest with a background.
  • SAM3 Image — select an area with a text description.
  • Image Input — add a source image.