🎈LG Relight Basic
The no-popup relight node that actually batches
- image
- normals
- IMAGE
Most "relight" nodes in ComfyUI open a window in your face when you run them. LG Relight Basic is the one that doesn't. It's the headless, pure-math member of the LAOGOU Relight family: you feed it an image and a normal map, set a light direction with a few sliders, and it returns a relit image without ever stopping to ask you anything. That makes it the version you'd actually wire into a batch job, an API, or a workflow you run at 2am while you sleep.
It comes from the same pack as the fancier interactive nodes (LG Relight, LG Relight Ultra) by the Chinese node author LAOGOU-666. Those open a three.js editor so you can drag a light around with your mouse. Basic is the same underlying lighting math with the editor stripped out - deterministic, reproducible, and fast.
How it works
The math is a cheap but honest 3D lighting approximation. Your normal map (a color image where each pixel's RGB encodes which direction that surface faces) gets remapped from 0–1 to −1..1 vectors. Your x, y, z sliders define the light direction, also normalized to a unit vector. The dot product of normal and light gives a per-pixel diffuse brightness, which drives the shadow and highlight masks that multiply the original image. Highlight and shadow colors then tint those regions. Nothing is generated, nothing is hallucinated - it's the same light-transport idea IC-Light leans on, just computed directly instead of learned.
The inputs that matter
You only ever touch a handful of these:
x,y,z- where the light sits.x/ydefault to0.5(centered);zdefaults to1, meaning head-on toward the viewer. Pushznegative and the light comes from behind.brightness- a simple overall gain (0–3, default 1).shadow_range/shadow_strengthandhighlight_range/highlight_strength- how wide and how strong the dark and bright sides of the light get. Leave them at 1 until the direction looks right.highlight_color/shadow_color- hex strings like#FFFFFFand#000000. Want a warm sunset side and a cool shadow? This is where.
Output is a single IMAGE - the relit version, same size as the input. The node resizes the normals to match the image, so mismatched resolutions won't blow up on you.
Installing it
Same story as the whole pack - no model downloads, no requirements.txt, nothing heavy:
ComfyUI Manager → Install Custom Nodes → search "Comfyui-LG_Relight"
Or by hand:
cd ComfyUI/custom_nodes
git clone https://github.com/LAOGOU-666/Comfyui-LG_Relight
Restart ComfyUI after installing, and hard-refresh the browser tab. That's it - the whole pack is one Python file plus a bit of frontend, and it only needs torch, numpy and PIL, which ComfyUI already has.
Where people get burned
The classic mistake is feeding it a normal map that doesn't match the image - a normal map from a different crop, or a depth map by mistake. The relight will come back looking flat and wrong, and the node will happily take the blame. Also remember the normals convention: if your shadows land on the wrong side of your subject, flip x (mirror it around 0.5) rather than re-exporting everything. And since it's a single light, the author's own README says the effect is limited on its own - it's meant to sit in a chain with something like IC-Light for the heavy lifting. For one node that never asks you a question, that's a fair trade.
Inputs (12)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | — | |
| normals | IMAGE | — | |
| x | FLOAT | 0.5000–1 | — |
| y | FLOAT | 0.5000–1 | — |
| z | FLOAT | 1.000-1–1 | — |
| brightness | FLOAT | 1.0000–3 | — |
| shadow_range | FLOAT | 1.0000–2 | — |
| shadow_strength | FLOAT | 1.0000–2 | — |
| highlight_range | FLOAT | 1.0000–2 | — |
| highlight_strength | FLOAT | 1.0000–2 | — |
| highlight_color | STRING | #FFFFFF | — |
| shadow_color | STRING | #000000 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |