Convert Image to Mask
Documentation
- Class name:
ImageToMask
- Category:
mask
- Output node:
False
The ImageToMask node is designed to convert an image into a mask based on a specified color channel. It allows for the extraction of mask layers corresponding to the red, green, blue, or alpha channels of an image, facilitating operations that require channel-specific masking or processing.
Input types
Parameter | Comfy dtype | Description |
---|---|---|
image | IMAGE | The 'image' parameter represents the input image from which a mask will be generated based on the specified color channel. It plays a crucial role in determining the content and characteristics of the resulting mask. |
channel | COMBO[STRING] | The 'channel' parameter specifies which color channel (red, green, blue, or alpha) of the input image should be used to generate the mask. This choice directly influences the mask's appearance and which parts of the image are highlighted or masked out. |
Output types
Parameter | Comfy dtype | Description |
---|---|---|
mask | MASK | The output 'mask' is a binary or grayscale representation of the specified color channel from the input image, useful for further image processing or masking operations. |