IO_EasyMark
Paint a mask straight inside the node, split by color
- 原图
- 合成图
- 总mask
- 黑mask
- 白mask
- 红mask
- 绿mask
- 蓝mask
- 灰mask
Most "draw a mask" setups in ComfyUI make you load an image somewhere, open a separate mask editor, and wire the result back in. IO_EasyMark skips that round trip - it's a paint canvas that lives inside the node itself, and it can hand you back not one mask but seven, split by the color you painted with.
What it's for
Think of it as a quick multi-region annotator. You load a picture into the node, grab the brush, and paint over the parts you care about - say red over a face you want to swap, blue over a background you want to replace, black to mark "leave alone." Instead of forcing you to build one mask at a time, IO_EasyMark reads the whole painted canvas back out and gives you a separate mask per color plus a combined "everything you touched" mask. That's genuinely useful when a workflow needs to treat different regions differently - one color feeds an inpaint branch, another feeds a different LoRA pass, and so on - without you drawing, saving, and reloading a mask for each one.
Inputs and outputs
There are only three widgets, and you'll rarely touch two of them directly:
image_base64- the source image, stored as base64 text. In practice this gets filled in by the node's own widget when you load a picture into the canvas, not something you type by hand.brush_data- the recorded strokes, again written by the widget as you paint.brush_size(1–100, default 4) - the one you'll actually adjust: how fat the pen tip is.
The payoff is on the output side - nine of them: the original image, a composite (image + your marks baked in), a "total" mask covering everything you painted, and then one mask each for black, white, red, green, blue, and gray strokes. Only paint in the colors you plan to use; any color you never touch comes back as an empty mask, and downstream nodes need to tolerate that gracefully.
How to install it
Through ComfyUI Manager, search ComfyUI-Apt_Preset and install. Manually:
cd ComfyUI/custom_nodes
git clone https://github.com/cardenluo/ComfyUI-Apt_Preset.git
Then, per the README, run install.bat to pull in the pack's Python dependencies. That file is Windows-only - on Linux, macOS, or a headless box, open it in a text editor and run the pip install lines it contains by hand instead. Restart ComfyUI afterward.
Common issues & troubleshooting
IMPORT FAILED on startup. This pack shows up in the wild with at least one reported case of ComfyUI-Apt_Preset failing to import cleanly on a stock install - the usual cause for that class of failure is skipping the dependency install step above (or running it on a platform install.bat doesn't cover). If the console flags this node pack red, check the console log for the actual missing-package name before reinstalling blind.
Custom canvas widgets are exactly what breaks first on a frontend upgrade. ComfyUI's ongoing "Nodes 2.0" rewrite has already broken a number of packs that draw their own UI inside a node (custom node authors got a direct shout-out from Comfy Org for the migration pain it caused). If the paint canvas doesn't render or won't accept strokes after updating ComfyUI, that's the first thing to suspect - try the legacy canvas mode before assuming the node itself is broken.
Nothing came out for a color you expected. That's not a bug, it's the design: a color mask is empty unless you actually painted with that color. If a downstream node errors on an empty MASK, either paint at least one stroke of that color or route around the unused outputs.
This is a personal-project node pack rather than one of the ecosystem's heavily-discussed staples, so there's not much public troubleshooting lore to draw on beyond the above - if you hit something stranger, the GitHub issues page is the more useful stop than Reddit.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| brush_data | STRING | — | |
| brush_size | INT | 41–100 | — |
| image_base64 | STRING | — |
Outputs (9)
| Name | Type | Description |
|---|---|---|
| 原图 | IMAGE | — |
| 合成图 | IMAGE | — |
| 总mask | MASK | — |
| 黑mask | MASK | — |
| 白mask | MASK | — |
| 红mask | MASK | — |
| 绿mask | MASK | — |
| 蓝mask | MASK | — |
| 灰mask | MASK | — |