Nodes/ComfyUI_PHRenderFormerWrapper/RenderFormer Lighting
ComfyUI Node

RenderFormer Lighting

Add a light that isn't pretending to be a light

By paulh4x·Created about a year ago·Updated about a year ago· 37
RenderFormer Lighting
    • LIGHTING
    emissive_rgb255, 255, 255
    emissive_strength5000
    light_pos_x0.000
    light_pos_y0.000
    light_pos_z2.100
    rot_x0.0
    rot_y0.0
    rot_z0.0
    scale2.50

    In most diffusion setups you fake lighting with prompts and hope. In this pack, you get actual light sources - or at least, actual emissive geometry that RenderFormer's transformer treats as light. The RenderFormerLighting node is how you create one of those sources, and it's one of the 15 nodes in paulh4x/ComfyUI_PHRenderFormerWrapper, the "100% vibecoded" wrapper around Microsoft's RenderFormer (SIGGRAPH 2025).

    How it works

    Under the hood, a "light" here is a small emissive mesh - the README's example uses a triangle with an emissive material. The node builds a transform (position, rotation, scale) plus a material whose emissive value is your RGB color multiplied by a strength, and outputs it as a LIGHTING object. Because the actual rendering is done by a neural model with global illumination, that emissive surface casts light onto everything around it - no ray tracing required.

    The inputs that matter

    • emissive_rgb - the light color as "R, G, B" from 0–255 (default 255, 255, 255, white). One caveat straight from the README: emission color is currently limited to white in practice, so don't fight it if your colored light doesn't behave like you expect.
    • emissive_strength - default 5000, range 0–100000. This is the intensity, and it's in physical-ish units - RenderFormer expects big numbers here. If your scene is pitch black, this is the first thing to check.
    • light_pos_x/y/z - position, default 0, 0, 2.1 (slightly in front of the origin, matching the example scene).
    • rot_x/y/z - rotation, −360 to 360.
    • scale - default 2.5. A bigger light surface spreads light differently, which gives you a soft/diffuse vs. hard falloff feel.

    The single output is LIGHTING, which you wire into the Scene Builder's required lighting input (or into RenderFormerLightingCombine if you want multiple sources).

    Building scenes with it

    The reference workflow uses one RenderFormerLighting straight into the Scene Builder. For anything richer, add more RenderFormerLighting nodes and merge them with RenderFormerLightingCombine - the pack supports up to 8 light sources combined. If you want the light to move or brighten over time, feed one of your lights into RenderFormerLightingTarget instead, which produces the LIGHTING_SEQUENCE for animation.

    Installing it

    # ComfyUI Manager: search "ComfyUI_PHRenderFormerWrapper"
    cd ComfyUI/custom_nodes/
    git clone https://github.com/paulh4x/ComfyUI_PHRenderFormerWrapper.git
    cd ComfyUI_PHRenderFormerWrapper
    git clone https://github.com/microsoft/renderformer.git renderformer
    pip install -r requirements.txt
    python -c "import imageio; imageio.plugins.freeimage.download()"
    

    Restart ComfyUI.

    Common issues

    • Render comes out black - emissive_strength is too low. Try the default 5000 first; values in the hundreds will read as "off."
    • Light doesn't reach where you think it should - the light is a physical surface, so position and scale matter. Point it at the scene and remember the geometry has to be facing your subject.
    • More than 8 lights - the Combine node tops out at eight inputs. The model limit is 8 lightsources, so that's a hard wall, not a bug.

    Simple node, huge effect: it's the difference between a flat prediction and a scene that reads as lit.

    CategoryPHRenderFormer

    Inputs (9)

    NameTypeDefaultDescription
    emissive_rgbSTRING255, 255, 255Emissive color (R, G, B) from 0-255
    emissive_strengthFLOAT50000–100000
    light_pos_xFLOAT0.000-10–10
    light_pos_yFLOAT0.000-10–10
    light_pos_zFLOAT2.100-10–10
    rot_xFLOAT0.0-360–360
    rot_yFLOAT0.0-360–360
    rot_zFLOAT0.0-360–360
    scaleFLOAT2.500.1–10

    Outputs (1)

    NameTypeDescription
    LIGHTINGLIGHTING