Texture Equalizer
The node that strips baked-in lighting off your textures
- image
- image
- average_color
If your texture pipeline starts from photos - and most real ones do - your albedo has baked-in lighting you didn't ask for. Shadows from the shooting setup, a bright window on one side, vignetting in the corners. When that texture becomes a PBR material, those lighting gradients render as fake shading that fights your scene's lights. Texture Equalizer is the fix: it flattens uneven lighting while leaving the actual surface detail intact.
It's the single most useful node in this pack for anyone doing photogrammetry-adjacent or scanned material work. You run it on the albedo before the seamless step, and suddenly your material behaves like a flat, neutral surface instead of a photograph with a shadow baked across it.
How it works
This is the classic Photoshop "equalize texture" technique (it's a direct port of Tolas' old tutorial), done in torch:
- Extract the image's average color - simulating Photoshop's Average Blur.
- Gaussian-blur the image and subtract it to get a high-pass version, which isolates fine detail and removes broad lighting gradients.
- Blend the average color with the inverted high-pass using a blend mode. overlay is the Photoshop standard and the default; soft_light is gentler; linear_light is the aggressive hammer.
- Optionally keep the original hue/saturation so only brightness changes (the
preserve_colortoggle). strengthfades the whole effect from 0 (no change) to 2 (exaggerated).
The average_color output is exactly what it sounds like - the flat average color, emitted as a full-size image. It's a debugging aid: if your output looks wrong, check that this value looks like the dominant color of your texture.
The dials that matter
- radius (1–500, default 100) - the high-pass radius. Lower = the effect respects smaller gradients, higher = more aggressive flattening. 50–150 is the working range; start at 100.
- strength (0–2, default 1) - overall effect. 0.5–0.7 for subtle cleanup.
- preserve_color - ON for albedo (you want the paint, not a recolored photo). OFF for height and roughness maps, where hue is meaningless.
- method - overlay, soft_light, or linear_light.
Outputs: image (equalized) and average_color.
Installing it
Texture Equalizer is part of ComfyUI-TextureAlchemy. In ComfyUI Manager search "Texture Alchemy", install, restart. Manual:
cd ComfyUI/custom_nodes
git clone https://github.com/amtarr/ComfyUI-TextureAlchemy
# restart ComfyUI
No extra dependencies, no models - pure PyTorch. Found under Add Node → Texture Alchemist → Texture. The README's "copy the ComfyUI_PBR_MaterialProcessor folder" instruction is a pre-rebrand leftover; ignore it.
Where people get burned
Output too dark or black is the classic complaint. The usual causes: linear_light pushed values past the ends of the range, or the radius was so high the high-pass swallowed the detail. The author's own troubleshooting says it plainly: switch to overlay, drop radius to 30–70, drop strength to 0.5–0.7, and check the average_color output to confirm the extraction wasn't garbage in the first place. Also: run the equalizer before you make the texture seamless - flattening first, then tiling, gives you a much cleaner seam than the reverse order.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | — | |
| radius | FLOAT | 1001–500 | High pass radius - controls detail preservation (50-150 typical) |
| strength | FLOAT | 1.000–2 | Effect strength (1.0 = full correction, 0.0 = no change) |
| preserve_color | BOOLEAN | true | Preserve original color hue (recommended for albedo) |
| method | COMBO | overlay | Blend method: overlay (Photoshop standard), soft_light (subtle), linear_light (strong) |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |
| average_color | IMAGE | — |