Visit ComfyUI Online for ready-to-use ComfyUI environment
Generate masks from list of values for precise control over appearance and behavior, ideal for AI artists.
The MaskFromList+ node is designed to generate a mask from a list of values, providing a flexible way to create masks based on specific numerical inputs. This node is particularly useful for AI artists who need to create custom masks for their projects. By allowing both integer and floating-point values, as well as string inputs that can be converted to numerical values, MaskFromList+ offers a versatile approach to mask creation. The node ensures that all values are clamped between 0.0 and 1.0, making it easy to work with normalized data. The primary goal of this node is to simplify the process of generating masks from a list of values, enabling more precise control over the mask's appearance and behavior.
The width
parameter specifies the width of the mask to be generated. It determines the horizontal dimension of the mask and accepts integer values. The default value is 32, with a minimum of 0 and a maximum defined by MAX_RESOLUTION
. The step size for this parameter is 8. Adjusting the width allows you to control the mask's size to fit your specific needs.
The height
parameter defines the height of the mask to be generated. It sets the vertical dimension of the mask and accepts integer values. The default value is 32, with a minimum of 0 and a maximum defined by MAX_RESOLUTION
. The step size for this parameter is 8. Modifying the height enables you to tailor the mask's size to match your requirements.
The values
parameter allows you to input a list of numerical values (either integers or floats) that will be used to create the mask. The default value is 0.0, with a minimum of 0.0 and a maximum of 1.0. This parameter is optional and provides a direct way to specify the mask's values.
The str_values
parameter accepts a string of comma-separated numerical values that will be converted to floats and used to generate the mask. The default value is an empty string, and it supports multiline input. This parameter is optional and offers an alternative method to input the mask's values, especially useful for quickly entering multiple values.
The MASK
output parameter represents the generated mask based on the input values. This mask is a tensor with values clamped between 0.0 and 1.0, ensuring it is normalized and ready for further processing or application. The mask's dimensions are determined by the specified width and height, and it can be used in various AI art projects to control different aspects of the artwork.
values
parameter to input a list of numerical values directly.str_values
parameter to quickly input them as a comma-separated string.values
nor str_values
are provided or both are empty.values
or str_values
parameter to generate the mask.values
parameter is not a list or a single numerical value.values
parameter is either a list of numerical values or a single numerical value.values
or str_values
parameter is outside the range of 0.0 to 1.0.© Copyright 2024 RunComfy. All Rights Reserved.