ComfyUI > Nodes > WAS Node Suite > Image Blend by Mask

ComfyUI Node: Image Blend by Mask

Class Name

Image Blend by Mask

Category
WAS Suite/Image
Author
WASasquatch (Account age: 4688days)
Extension
WAS Node Suite
Latest Updated
2024-08-25
Github Stars
1.07K

How to Install WAS Node Suite

Install this extension via the ComfyUI Manager by searching for WAS Node Suite
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter WAS Node Suite in the search bar
After installation, click the Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • High-speed GPU machines
  • 200+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 50+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

Image Blend by Mask Description

Seamlessly blend two images using a mask and blend percentage for controlled composition and smooth transitions.

Image Blend by Mask:

The Image Blend by Mask node is designed to seamlessly blend two images together using a specified mask and blend percentage. This node allows you to create complex and visually appealing compositions by controlling how much of each image is visible in the final output. The mask image determines which parts of the two input images are blended, while the blend percentage allows you to fine-tune the intensity of the blend. This node is particularly useful for creating smooth transitions and combining elements from different images in a controlled manner, making it an essential tool for AI artists looking to enhance their creative projects.

Image Blend by Mask Input Parameters:

image_a

This parameter represents the first input image that you want to blend. It serves as one of the two primary images in the blending process. The quality and resolution of this image will directly impact the final output.

image_b

This parameter represents the second input image that you want to blend with the first image. Like image_a, the quality and resolution of this image are crucial for achieving the desired blending effect.

mask

The mask parameter is an image that dictates which parts of image_a and image_b are visible in the final blend. The mask image is converted to grayscale, where white areas represent full visibility of image_a, black areas represent full visibility of image_b, and gray areas represent a mix of both images. This allows for precise control over the blending regions.

blend_percentage

This parameter controls the intensity of the blend between the two images. It is a floating-point value ranging from 0.0 to 1.0, with a default value of 0.5. A value of 0.0 means that only image_a will be visible, while a value of 1.0 means that only image_b will be visible. Intermediate values create a mix of both images, with the blend percentage determining the proportion of each image in the final output.

Image Blend by Mask Output Parameters:

IMAGE

The output parameter is the final blended image, which is the result of combining image_a and image_b according to the specified mask and blend percentage. This image will reflect the smooth transitions and controlled blending dictated by the input parameters, providing a visually cohesive result.

Image Blend by Mask Usage Tips:

  • Experiment with different mask images to achieve various blending effects. Simple gradient masks can create smooth transitions, while more complex masks can produce intricate compositions.
  • Adjust the blend_percentage to fine-tune the visibility of each input image. Small changes in this parameter can significantly impact the final output, so take the time to find the perfect balance for your project.
  • Ensure that the resolution and quality of image_a, image_b, and the mask are consistent to avoid any unwanted artifacts or mismatches in the final blended image.

Image Blend by Mask Common Errors and Solutions:

"Image size mismatch"

  • Explanation: This error occurs when the input images (image_a, image_b, and mask) do not have the same dimensions.
  • Solution: Ensure that all input images are of the same size before using the node. You can resize the images using an image editing tool or a preprocessing node.

"Invalid blend percentage"

  • Explanation: This error occurs when the blend_percentage value is outside the allowed range of 0.0 to 1.0.
  • Solution: Adjust the blend_percentage value to be within the range of 0.0 to 1.0. The default value is 0.5, which provides an equal blend of both images.

"Unsupported image format"

  • Explanation: This error occurs when the input images are in an unsupported format.
  • Solution: Convert the input images to a supported format, such as PNG or JPEG, before using the node. This can be done using an image editing tool or a preprocessing node.

Image Blend by Mask Related Nodes

Go back to the extension to check out more related nodes.
WAS Node Suite
RunComfy

© Copyright 2024 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals.