Invert Image
A straight negative, one input, one output
- image
- IMAGE
Exactly what it sounds like: every pixel value gets flipped, black becomes white, white becomes black, colors swap to their complements - the classic photo-negative effect. No parameters, no configuration, just an IMAGE in and an IMAGE out. There isn't much mechanism to explain beyond that: it's a per-pixel 1 - value operation, the same math a "negative" filter has used since darkroom days.
It's the kind of node you don't need often, but is genuinely handy when you do. A few real uses: flipping the polarity of something you're treating as a mask-in-image-form (white-means-selected becomes black-means-selected, or vice versa, when a downstream node expects the opposite convention); building a quick visual diff or highlight effect; or just as a debug step to make subtle low-contrast detail suddenly pop, since inversion can make faint gradients or artifacts much easier to spot by eye.
One thing worth checking before you reach for this: some more recent ComfyUI core builds ship their own native invert node. If yours does, that'll behave the same way with one less custom-node dependency in your graph - worth a quick look in your node search before installing a whole pack for a single-purpose effect like this.
It's worth being clear on what this node isn't, too. It works on IMAGE tensors, not ComfyUI's dedicated MASK type - so if you're trying to invert a mask specifically, look for a mask-invert node built for that type rather than reaching for this one. This one is for pictures you want inverted as pictures: converting a mask to an image first, running it through here, and converting back is a roundabout way to get the same result a proper mask-invert node gives you more directly.
Inputs and outputs
- image - the only input, an
IMAGE.
Output is a single IMAGE, inverted.
Installing ComfyUI-LogicUtils
ComfyUI Manager: Install Custom Nodes → search "ComfyUI-LogicUtils" → install → restart. Or manually:
cd ComfyUI/custom_nodes
git clone https://github.com/aria1th/ComfyUI-LogicUtils
Restart ComfyUI. No dependencies, no models - it's a one-line tensor operation.
Worth knowing
LogicUtils is aria1th's (AngelBottomless's) side collection of utility nodes - the same handle behind Illustrious XL, though this pack is a separate, much smaller project. It's a genuine grab-bag: this simple image filter sits in the same repo as Danbooru taggers, a primality checker, and a JSON debugger, with nothing tying them together beyond "things the author wanted while building workflows." The README itself admits there's essentially no documentation, and public pushes stopped in January 2026 - but a single-purpose node like this one has no real surface area to break, so that's not much of a concern here. If it inverts correctly on install, it'll keep inverting correctly indefinitely.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |