Generator node
Invert Image
Turns any incoming texture into its photographic negative in a single GPU pass. Amount blends continuously between the original and the full negative, so inversion can be animated by an LFO, an audio band, or an EEG signal, and an optional alpha inversion flips coverage so that transparent areas become solid. It is a universal 1:1 image filter — it accepts the Image output of any generator, including live sources like Camera Input, Video Player, and Liquid Simulation.
Inputs
| Port | Type | Default |
|---|---|---|
| ImageThe picture to invert. Connect any generator, camera, video or filter texture. | image | — |
| EnableOff passes the source through untouched. | bool | true |
| AmountBlends between the original and the full negative. Clamped to 0…1; cable an LFO here for breathing inversion. | float | 1.0 |
| Invert AlphaAlso flips coverage, so transparent areas become opaque and the silhouette turns inside out. Off keeps transparency as it was. | bool | false |
Outputs
| Port | Type |
|---|---|
| ImageThe picture to invert. Connect any generator, camera, video or filter texture. | image |
| Width | float |
| Height | float |
Live Preview
How It Works
Invert Image is a pass-through filter node: it takes an image on its Image input port, renders one fullscreen triangle over the upstream texture, and writes the result to its own offscreen texture, which it exposes on its Image output. Nothing is composited to screen here — the output still needs a Canvas node.
Because Grafit generator textures are stored premultiplied, a naïve 1 − rgb would brighten transparent regions into grey haze. The shader therefore does the mathematically correct thing per pixel:
- Un-premultiply —
rgb = a > 0.001 ? rgb / a : 0 - Invert and blend —
outRGB = mix(rgb, 1 − rgb, Amount) - Alpha —
a = Invert Alpha ? mix(a, 1 − a, Amount) : a - Re-premultiply — the returned color is
float4(outRGB × a, a)
So with Invert Alpha off, transparent pixels stay perfectly transparent and only visible color is negated. With Invert Alpha on, the coverage itself is inverted — what was solid becomes empty and what was empty becomes solid — which turns any shape into its own inverted stencil.
Amount is clamped to 0…1 and interpolates linearly:
Amount | Result |
|---|---|
| 0.0 | Original image, untouched |
| 0.5 | Fully desaturated-looking midpoint (each channel pulled halfway to 0.5) |
| 1.0 | Full photographic negative |
The node is flagged as always-dynamic and it keeps its source rendered even when that source isn't on a Canvas of its own — so you can chain a generator straight into Invert Image without also having to composite the original, and live inputs (camera, video, fluid sims) update every frame.
The Width and Height outputs pass the upstream generator's dimensions straight through (falling back to 2.0 × 2.0 if nothing is connected), so the filter is transparent to any downstream node that needs the source's footprint. When Enable is false, or when no image source is connected, no pass is drawn and the output texture is left cleared.
Parameters in Depth
| Port | Type | Default | Meaning |
|---|---|---|---|
Image | Image | — | The texture to invert. Connect the Image output of any generator (Circle 2D, Text as Image, Image, Camera Input, Video Player, Liquid Simulation, Particle System, …). Nothing connected = nothing rendered. |
Enable | Bool | true | Master switch. Off skips the pass entirely; the output stays cleared. |
Amount | Float | 1.0 | Blend between original (0) and full negative (1), clamped to 0…1. Cable-drivable for animated inversion. |
Invert Alpha | Bool | false | Also inverts the alpha channel, flipping opaque and transparent regions. Off (default) keeps the source's coverage intact. |
Interactions: Amount drives both the color and the alpha inversion, so with Invert Alpha on, a mid Amount gives a half-solid, half-transparent wash rather than a clean stencil — use Amount at 1.0 when you want a crisp inverted mask.
Use Cases
- Beat-synced negative flash —
Audio Beat Detection→Amountfor a strobing full-frame inversion on every kick. - Breathing color reversal —
LFO(0…1) →Amountacross a slow cycle so a video or camera feed melts in and out of negative. - Live camera negative —
Camera Input→ Invert Image →Canvasfor an instant X-ray/darkroom look on a performer. - Inverted stencil from a shape —
Circle 2D→ Invert Image withInvert Alphaon andAmount1.0, then feed the result into a Canvas node'sMaskinput to punch a hole instead of cutting a disc. - Negative text over footage —
Text as Image→ Invert Image → Canvas on a layer aboveVideo Player, so type reads against any background. - Fluid contrast pass —
Liquid Simulation→ Invert Image →Gaussian Blur→ Canvas (additive blend) for glowing inverse plumes. - EEG-driven mood switch —
FFT EEGband power →Remap(0…1) →Amountso the whole scene inverts as attention or relaxation rises.
Tips
- This is a filter, not a source: it needs both an upstream image on its
Imageinput and a downstream Canvas node to be seen. - The upstream generator does not need its own Canvas — Invert Image keeps its source rendered off-canvas automatically.
- Inversion is premultiplied-correct: leave
Invert Alphaoff and transparent regions stay clean, with no grey halo around antialiased edges. Amountat 0 still costs one fullscreen pass; useEnable(or bypass the node) when you want a genuinely free pass-through.- It is a single cheap fullscreen pass, so it stacks freely with other image filters — chain it with Image Adjustment, Gaussian Blur, Image Transform, Mask Grow, or Mask Outline in any order (order changes the look).
- The
Width/Heightoutputs mirror the source, so a Canvas node sized from this filter matches a Canvas sized from the original.
Open Invert Image in the interactive catalog →
Invert Image is one of 381 nodes in Grafit Pro.
Free download. Every feature for 7 days, no card. Then €99.99 once — or keep playing your projects as a Player.