Nodes/ComfyUI-Leputen-Utils/Extract Fine Details
ComfyUI Node

Extract Fine Details

Pull fine detail out of a normal map so you can reuse it

By lilquail·Created 9 months ago·Updated 9 months ago· 1
Extract Fine Details
  • normal_map
  • IMAGE
detail_scale2.0
strength1.00

Here's a workflow problem you'll hit the moment you start re-baking textures: you've got a normal map with gorgeous fine detail, you need to re-bake the base, and you don't want to lose the scratches. Extract Fine Details separates the high-frequency detail from a normal map using a high-pass filter, so you can save the fine stuff, work on the base, and re-layer the detail on top with the pack's Add Normals node.

It's the "separate the signal" step in a detail-preservation pipeline, and it's also handy for a simpler trick: exaggerating texture detail by extracting it and re-adding it at higher strength.

How it works

It's a classic unsharp-mask-style high-pass: the node blurs the normal map by detail_scale pixels, then subtracts the blur from the original, leaving only the differences - the fine details. detail_scale is effectively the blur radius that sets the boundary between "detail" and "base":

  • Small values (0.1–2) catch only the very finest texture.
  • Large values (up to 50) sweep up progressively bigger features.

strength (0–4, default 1) scales what's extracted: 0 gives a flat normal, 1 reproduces the original detail intensity, >1 exaggerates it. The output is renormalized so it stays a valid normal map.

Inputs and outputs

Required: normal_map and detail_scale (default 2). Optional: strength (default 1).

Output is a single IMAGE normal map containing the extracted detail, ready to feed into Add Normals (detail_normal) or a saver.

Install

Ships in ComfyUI-Leputen-Utils:

cd ComfyUI/custom_nodes
git clone https://github.com/lilquail/ComfyUI-Leputen-Utils

Restart ComfyUI, find it under Leputen-Utils → NormalMap. Pure tensor math, no extra dependencies beyond the pack's own, works on any platform.

Troubleshooting

  • The classic two-knob balance - detail_scale and strength interact. If you extract with a big detail_scale, you'll pull mid-frequency shading too, and re-adding it can double-light the base. Keep the scale small (2–6) unless you deliberately want larger features.
  • Result looks flat - the high-pass output is centered around mid-gray and is the detail, not the full surface. That's correct; don't be alarmed that it doesn't look like a normal map. Blend it onto a real base with Add Normals.
  • Exaggerating noise - high strength amplifies whatever the source has. On a noisy map you'll get sparkly results; clean the source first.
  • Input must be a normal map - feed it an albedo and you're high-passing color, which produces meaningless "normals". Convert first.

One workflow worth knowing: re-bake your base, then Add Normals with the extracted detail at detail_strength ~0.5–1 to bring the surface back. That's the whole reason this node exists, and it beats trying to preserve detail by re-baking onto the old texture.

CategoryLeputen-Utils/NormalMap

Inputs (3)

NameTypeDefaultDescription
normal_mapIMAGEThe input normal map from which to extract fine details.
detail_scaleFLOAT2.00.1–50Blur radius for high-pass filter. Lower values extract finer details, higher values extract larger features.
strengthoptFLOAT1.000–4Intensity of extracted details. 0 = flat normal, 1 = original intensity, >1 = exaggerated.

Outputs (1)

NameTypeDescription
IMAGEIMAGE