Ceiling Mask Regions
Force any non-zero mask pixel to full white, no parameters needed
- masks
- MASKS
The simplest node in this whole pack - no parameters at all, just a mask in and a mask out. "Ceiling" is the tell: Ceiling Mask Regions pushes every non-zero pixel in your mask up to full white. If any part of a pixel is masked at all, this node treats it as fully masked, turning a soft, gradient, or partial mask into a hard binary one in one step.
How it works
Where SaltMaskAdaptiveThresholdingRegion needs you to tune a block size and a constant to decide the cutoff, this node skips the decision entirely - anything above zero becomes maximum. It's a one-click "just make this solid" operation rather than a tunable threshold, which is either exactly what you need or a much blunter tool than the job calls for, depending on whether you actually wanted to preserve any of the soft gradation.
The inputs and outputs that matter
masks(required, MASK) - the only input, and there's nothing optional to configure.
Output is MASKS, hard-binarized: every previously non-zero pixel is now full white.
How to install it
ComfyUI Manager: search SaltAI-Open-Resources or SaltAI, install, restart. Manual:
cd ComfyUI/custom_nodes
git clone https://github.com/get-salt-AI/SaltAI
then restart. No dependency worth mentioning - the simplest possible mask op.
Common issues & troubleshooting
Mask comes out fully solid when you expected a soft edge. That's this node working exactly as designed, not a bug - it has one job and it's not gentle about it. If you actually needed soft edges preserved (say, for a feathered blend), route around this node entirely: go straight from your segmentation model's raw output, or reach for SaltMaskClipHardeningFilter instead, which sharpens a mask without fully flattening it.
Used it where you needed a threshold instead. If your mask has genuine noise or a gradient that shouldn't all count as foreground, ceiling is the wrong tool - anything above zero becomes fully masked, including faint noise you probably didn't want included. Reach for SaltMaskAdaptiveThresholdingRegion when you need an actual cutoff decision rather than an all-or-nothing one.
Used it as a "clean up my mask" step and it made things worse. If your input mask had stray faint pixels scattered around the frame (not just at the subject's edge), ceiling promotes every one of them to full white too. Clean up noise first - a bilateral filter or contour extraction pass - then ceiling if you still want a hard binary result afterward.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| masks | MASK | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| MASKS | MASK | — |