🔧 Mask From RGB/CMY/BW
essentials/mask
MaskFromRGBCMYBW+Example
JSON Example
{
"class_type": "MaskFromRGBCMYBW+",
"inputs": {
"image": [
"node_id",
0
],
"threshold_r": 0.15,
"threshold_g": 0.15,
"threshold_b": 0.15
}
}This example shows required inputs only. Connection values like ["node_id", 0] should reference actual node IDs from your workflow.
Inputs
| Name | Type | Status | Constraints | Default |
|---|---|---|---|---|
image | IMAGE | required | - | - |
threshold_r | FLOAT | required | min: 0, max: 1, step: 0.01 | 0.15 |
threshold_g | FLOAT | required | min: 0, max: 1, step: 0.01 | 0.15 |
threshold_b | FLOAT | required | min: 0, max: 1, step: 0.01 | 0.15 |
Outputs
| Index | Name | Type | Is List | Connection Reference |
|---|---|---|---|---|
0 | red | MASK | No | ["{node_id}", 0] |
1 | green | MASK | No | ["{node_id}", 1] |
2 | blue | MASK | No | ["{node_id}", 2] |
3 | cyan | MASK | No | ["{node_id}", 3] |
4 | magenta | MASK | No | ["{node_id}", 4] |
5 | yellow | MASK | No | ["{node_id}", 5] |
6 | black | MASK | No | ["{node_id}", 6] |
7 | white | MASK | No | ["{node_id}", 7] |
How to connect to these outputs
To connect another node's input to an output from this node, use the connection reference format:
["node_id", output_index]Where node_id is the ID of this MaskFromRGBCMYBW+ node in your workflow, and output_index is the index from the table above.
Example
If this node has ID "5" in your workflow:
red (MASK):["5", 0]green (MASK):["5", 1]blue (MASK):["5", 2]
Was this page helpful?