Nodes/SDVN_Comfy_node/πŸ§… Overlay Two Images
ComfyUI Node

πŸ§… Overlay Two Images

Alpha-blend two images with one opacity slider

By StableDiffusionVNΒ·Created 2 years agoΒ·Updated about a month agoΒ· 118
πŸ§… Overlay Two Images
  • image1
  • image2
  • output_image
β—„opacity0.50β–Ί

The simplest node in this pack's image-processing set: two images in, one opacity slider, one blended image out. It's a straight alpha composite - image2 fades in over image1 by however much you dial the opacity up - and that's the whole job.

What you'd actually use it for

Blending two images is one of those operations that's basic on paper and useful constantly in practice. Comparing two generations side by side by ghosting one over the other to spot exactly where they diverge. Compositing a texture or overlay effect onto a base render. Building a simple before/after ghost image for a comparison post. Feeding two related frames together as a quick visual diff before deciding which one to keep. None of that needs anything fancier than "blend A and B by some percentage," which is exactly what this node is for - it's a utility, not a creative tool, and it's honest about that.

The inputs and outputs that matter

  • image1 - the base image.
  • image2 - the image that gets blended over it.
  • opacity - a 0–1 float, default 0.5. At 0 you get pure image1; at 1, pure image2; in between, a linear blend of the two.

One output, output_image - the composited result.

Installing it

ComfyUI Manager: search SDVN_Comfy_node, install, restart. Or:

cd ComfyUI/custom_nodes
git clone https://github.com/StableDiffusionVN/SDVN_Comfy_node

Then pip install -r custom_nodes/SDVN_Comfy_node/requirements.txt from your ComfyUI root, and restart. No models, no downloads - this is a plain image-math node.

Where people get burned

Mismatched image dimensions. Blending assumes the two images line up pixel-for-pixel; feed it a 512Γ—512 and a 1024Γ—1024 and you're relying on whatever the node does internally to reconcile that (resize, crop, or error), which isn't something you want to discover mid-workflow. Match your image sizes going in - an Upscale Image or Crop By Ratio node from this same pack is the easy fix if they don't.

Confusing this with masked compositing. This node has no mask input - it's a uniform, whole-image blend at one opacity, not a region-specific overlay. If what you actually want is "paste image2 onto image1 only where a mask says so," that's a different tool (the pack's Overlay Mask Color Image node is adjacent but built for visualizing masks with color, not for masked image compositing specifically).

Opacity is linear, not perceptual. A 0.5 opacity blend doesn't necessarily look like "an even 50/50 mix" to your eye if the two images differ a lot in brightness or contrast - it's a straight numeric interpolation. If the result looks off-balance, nudge the opacity rather than assuming something's broken.

CategoryπŸ“‚ SDVN/🎨 Image Processing

Inputs (3)

NameTypeDefaultDescription
image1IMAGEβ€”
image2IMAGEβ€”
opacityFLOAT0.500–1β€”

Outputs (1)

NameTypeDescription
output_imageIMAGEβ€”