create_mask_solo
A quick shape-mask generator — circles, stars, crosses and more
- bg_image
- get_img_size
- image
- mask
- box2
Sometimes you just need a circle, a star, or a radial gradient as a mask - a spotlight vignette, a quick lighting effect, a graphic overlay - and hand-painting it in the mask editor is more effort than the shape deserves. create_mask_solo generates ten primitive shapes as both an image and a matching mask, with full control over position, scale, rotation, and blur.
What it is and why you'd reach for it
This is one of Apt_Preset's mask utility nodes, and it's the simplest kind of mask generator in the pack: pick a shape, set its size and position, get an image plus a mask back. Circle and radial are the obvious choices for lighting-style vignettes or spotlight effects; star and cross for graphic overlays; rectangle, square, semicircle, quarter-circle, ellipse, and triangle round out the set for straightforward geometric masking without touching the mask editor at all.
How it works
shape picks from ten options. wide and height set the canvas size - worth flagging explicitly: the width field is genuinely named wide, not width, in this node's schema, so don't go hunting for a field called "width" that isn't there. coord_center chooses whether positioning is relative to a default origin or the image's actual center (image_center), and X_offset/Y_offset nudge the shape from there. scale (0.1–10) resizes the shape, rotation (0–360°) spins it, opacity (0–1) controls how solid it renders, and blur_radius (0–1000) softens the edge - useful for a natural-looking vignette instead of a hard-edged cutout. background_color and shape_color are separate pickers for the canvas fill and the shape's own color.
The two optional image inputs are genuinely useful shortcuts: get_img_size lets you match the canvas dimensions to an existing image instead of typing wide/height by hand, and bg_image lets you draw the shape on top of an actual image instead of a flat background_color fill.
Inputs and outputs that matter
shape(required, 10 options) - circle, square, rectangle, semicircle, quarter_circle, ellipse, triangle, cross, star, radial.wide/height(required) - canvas size (note:wide, notwidth).scale,rotation,opacity,blur_radius- shape transform and edge softness.bg_image/get_img_size(optional) - draw onto an existing image, or match its dimensions.
Outputs: image (the rendered shape on its background), mask (the same shape as a mask, ready to composite or feed a masked KSampler), and box2 - a bounding box for the shape, useful if you need its extent for downstream crop or placement math.
Installing it
Through ComfyUI Manager: search ComfyUI-Apt_Preset, install, restart. Manually:
cd ComfyUI/custom_nodes
git clone https://github.com/cardenluo/ComfyUI-Apt_Preset.git
Run install.bat on Windows for dependencies; on Linux/Mac install the requirements yourself. No model downloads needed - this is procedural shape rendering.
Common issues
If you're editing the node's fields directly (say, hand-building a workflow JSON) and can't find a width key, remember it's wide here - an easy typo trap since every other size-related node in this pack uses width.
If your shape looks softer or harder-edged than expected, blur_radius and opacity interact - a low opacity with zero blur still gives you a hard edge, just a fainter one; if you want an actual soft vignette, raise blur_radius rather than relying on opacity alone.
As with the rest of ComfyUI-Apt_Preset: it's a large, actively-updated pack, and at least one user has reported an IMPORT FAILED error at ComfyUI startup after installing it. Check the console log if this node doesn't appear after install.
Inputs (14)
| Name | Type | Default | Description |
|---|---|---|---|
| wide | INT | 5120–5000 | — |
| height | INT | 5120–5000 | — |
| shape | COMBO | circle | 10 options: circle, square, rectangle, semicircle, quarter_circle, ellipse, +4 |
| coord_center | COMBO | default | 2 options: default, image_center |
| X_offset | INT | 0-10000–10000 | — |
| Y_offset | INT | 0-10000–10000 | — |
| scale | FLOAT | 1.00.1–10 | — |
| rotation | INT | 00–360 | — |
| opacity | FLOAT | 1.00–1 | — |
| blur_radius | INT | 00–1000 | — |
| background_color | COMBO | white | 8 options: white, black, red, green, blue, yellow, +2 |
| shape_color | COMBO | black | 8 options: white, black, red, green, blue, yellow, +2 |
| bg_imageopt | IMAGE | — | |
| get_img_sizeopt | IMAGE | — |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |
| mask | MASK | — |
| box2 | BOX2 | — |