Visit ComfyUI Online for ready-to-use ComfyUI environment
Merge images with addition or multiplication, ensuring valid pixel range for creative blending effects in image processing.
The FrequencyCombine
node is designed to merge two images by performing either an addition or multiplication operation on their pixel values. This node is particularly useful in image processing tasks where you want to blend or combine images in a controlled manner. By allowing you to choose between addition and multiplication, it provides flexibility in how the images are combined, enabling creative effects and enhancements. The node ensures that the resulting image maintains pixel values within a valid range, preventing any overflow or underflow issues. This capability is essential for artists and designers who wish to experiment with image blending techniques without delving into complex coding or mathematical operations.
image1
is the first image input for the combination process. It serves as one of the two primary sources of pixel data that will be merged using the specified operation. The dimensions of this image are crucial as they determine the target size for any necessary resizing of the second image. This parameter does not have specific minimum or maximum values, but it should be a valid image tensor with dimensions in the format [B, H, W, C], where B is the batch size, H is the height, W is the width, and C is the number of channels.
image2
is the second image input that will be combined with image1
. Like image1
, it should be a valid image tensor with dimensions [B, H, W, C]. If image2
has slightly different dimensions from image1
, it will be resized to match image1
to ensure a seamless combination. This resizing is automatically handled by the node if the size difference is within a 3-pixel threshold.
The operation
parameter determines the method used to combine the two images. It offers two options: "add" and "multiply". When "add" is selected, the pixel values of image1
and image2
are summed, and the result is clamped to ensure values remain within the [0, 1] range. When "multiply" is chosen, the pixel values are multiplied, naturally keeping the result within the valid range. This parameter allows you to control the blending effect, with "add" typically resulting in a brighter image and "multiply" often producing a more complex interaction of colors and intensities.
The result
is the output image obtained after combining image1
and image2
using the specified operation. This image retains the dimensions of image1
and contains the blended pixel values resulting from either the addition or multiplication process. The output is a single image tensor with values clamped to the [0, 1] range, ensuring it is suitable for further processing or display. This output is crucial for visualizing the effects of the combination and for use in subsequent image processing tasks.
{h1}
x{w1}
, Image2: {h2}
x{w2}
RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals. RunComfy also provides AI Playground, enabling artists to harness the latest AI tools to create incredible art.