Nodes/comfyui-mixlab-nodes/MaskList to Mask ♾️Mixlab
ComfyUI Node Runs on cloud

MaskList to Mask ♾️Mixlab

MaskList to Mask — Flattening Several Masks Into One

By MixLabPro·Created 3 years ago·Updated 2 months ago· 1,859
MaskList to Mask ♾️Mixlab
  • masks
  • MASK

The display name says it plainly: MaskList to Mask. Singular in, plural... well, the other way around - you feed it several masks and get exactly one back. That's the entire job, and it's a small node that solves a real, boring, recurring problem: a lot of ComfyUI operations naturally produce a batch or list of masks (per-detection segmentation, per-frame masks, one mask per layer from something like Mixlab's own NewLayer node), and plenty of downstream operations - a single compositing step, a single inpaint pass - want just one mask covering everything you care about, not a stack of them.

There's really only one input: masks, typed MASK. The schema doesn't explicitly mark it as a list, but the whole point of a node called "MaskList to Mask" is consuming a list-typed MASK output from something upstream - feed it a single mask and there's nothing meaningful for it to merge. The output is a single MASK, is_list: false, which is the flattened result: functionally a union of every mask you fed in, so anywhere any one of the source masks was "on," the merged result is "on" there too.

This pairs naturally with anything in the pack that produces masks per-item rather than one mask total. If you've built up a stack of regions with NewLayer (each layer optionally carries its own mask) and you eventually want one combined selection covering the whole composition rather than per-layer masks, MaskList to Mask is the node that gets you there. It's also a natural fit after any segmentation or detection step that hands back "one mask per detected thing" when what you actually need next is "everywhere any of those things were."

Because it has no configurable parameters at all - no threshold, no blend mode, nothing to tune - there isn't much to get wrong once it's wired up correctly. The one thing worth double-checking is exactly what tripped up JoinWithDelimiter's users too: make sure what's feeding masks is actually a list-producing output, not a single mask that happens to be MASK-typed. If you only ever pass in one mask, the "merge" is trivially just that mask again, which can look like the node did nothing when really there was nothing to combine.

Installing it follows the pack's usual route. Through ComfyUI Manager: search "comfyui-mixlab-nodes," install, restart. Manually:

cd ComfyUI/custom_nodes
git clone https://github.com/shadowcz007/comfyui-mixlab-nodes.git
cd comfyui-mixlab-nodes
install.bat

or pip3 install -r requirements.txt in a venv, or the portable-build pip invocation. Restart ComfyUI afterward. No model files, no external dependency specific to this node - it's pure mask math, so if it doesn't show up in the node search after installing, that points at a broader install problem with the pack (check the startup console for an import error) rather than anything about this node in particular.

Category♾️Mixlab/Mask

Inputs (1)

NameTypeDefaultDescription
masksMASK

Outputs (1)

NameTypeDescription
MASKMASK