ImageBlender
Krita's 88 blend modes, now in your ComfyUI graph
- base_image
- blend_image
- mask
- IMAGE
The name tells you exactly what you get: ImageBlender takes two images and fuses them with a blend mode. No API, no model download, no key - every one of its 88 modes is a Krita-style pixel-math recipe ported to PyTorch. If you've ever wished your ComfyUI graph had the layer panel of a paint program, this is the closest you'll get without leaving the graph.
ComfyUI ships with ImageCompositeMasked, which pastes one image onto another at a position - that's compositing as a paste, not a blend. For the actual Photoshop/Krita verbs - screen, overlay, soft light, color dodge, difference - you'd normally reach for WAS Node Suite or hand-roll a math node. ImageBlender squeezes the whole Krita blend palette into a single dropdown, which makes it handy for the fiddly post-processing jobs: grading a render onto a background, adding light leaks with screen or linear dodge, darkening with multiply, or scrubbing difference to eyeball what changed between two passes.
How it works
Under the hood it's embarrassingly simple, and that's the appeal. Two IMAGE tensors in, one per-pixel formula out. The mode is a function pointer into a folder of roughly 90 torch implementations, most of them a few lines long - multiply is literally base * blend. Then strength lerps the result back toward the base image, and everything gets clamped to 0–1 before it hits the output. No sampling, no VAE, no precision worries; it runs directly on the tensors your previous nodes already produced.
The inputs that matter
- base_image and blend_image - both IMAGE, and here's where beginners get burned: they must be the same resolution. The node asserts it and throws if they're not, so put an ImageScale or ImageTransform in front of whichever one is smaller.
- blend_mode - the big dropdown: 88 choices grouped into arithmetic, binary, darken, HSI/HSL/HSV/HSY, lighten, mix, modulo, and negative. The default, "mix: normal", is the identity - it returns the blend image unchanged. Not a bug, just confusing the first time you see it.
- strength - 0 to 1, default 1. Lower it to soften a harsh mode instead of hunting for a gentler one.
- mask (optional) - restricts where the blend applies. One real gotcha: the mask has to be exactly the same pixel dimensions as the images, or the node quietly ignores it and only prints a warning in the console. Resize it to match before wiring it in.
The output is a single IMAGE at the same resolution as the inputs. Wire it into a PreviewImage or straight to SaveImage - or chain it into another ImageBlender if you're feeling like a color-grading session.
Installing it
No dependencies, no model files - just torch, which ComfyUI already has. Clone into custom_nodes and restart:
cd ComfyUI/custom_nodes
git clone https://github.com/vault-developer/comfyui-image-blender
Or, if you use comfy-cli: comfy node registry-install comfyui-image-blender. The README was written while ComfyUI Manager support was still a pending pull request; the pack is on the Comfy registry now, so Manager can usually find it, but the clone is bulletproof either way.
Troubleshooting
The shape assert is 90% of the failure cases - mismatched resolutions throw "Base and blend images must have the same shape." The other silent one is the mask: an ill-sized mask gets dropped with only a console warning, so if your blend is applying everywhere despite a mask, check the mask resolution first. The author calls it a "rough implementation" with 45 more modes planned, so expect a few rough edges and file an issue if you find one.
Honest take for most people: you'll actually live in maybe six of those 88 modes - screen, multiply, overlay, soft light, difference, color. But having the other 82 a dropdown away beats rebuilding them as math nodes every time.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| base_image | IMAGE | — | |
| blend_image | IMAGE | — | |
| strength | FLOAT | 1.000–1 | — |
| blend_mode | COMBO | mix: normal | 88 options: arithmetic: addition, arithmetic: divide, arithmetic: inverse subtract, arithmetic: multiply, arithmetic: subtract, binary: AND, +82 |
| maskopt | MASK | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |