Nodes/Sphere-Light-Render-ComfyUI/πŸ”† Sphere Light β€” Sun (Coordinates)
ComfyUI Node

πŸ”† Sphere Light β€” Sun (Coordinates)

Exact sunlight from exact coordinates β€” no city required

By eric-venti-seedsΒ·Created 2 months agoΒ·Updated 22 days agoΒ· 38
πŸ”† Sphere Light β€” Sun (Coordinates)
    • render
    β—„intensity1.5β–Ί
    β—„latitude0.0000β–Ί
    β—„longitude0.0000β–Ί
    β—„year2025β–Ί
    β—„month6β–Ί
    β—„day21β–Ί
    β—„hour12β–Ί
    β—„minute0β–Ί
    β—„heading0.00β–Ί
    β—„render_b64β–Ί

    Same idea as the Sun (City) node, but you skip the city name and type coordinates instead. Where City is the quick human-friendly option - Austin, TX - this one is for when you know the position: a place too small to make the bundled city list, an exact trailhead, or a spot whose GPS coordinates you pulled off a photo. Type latitude and longitude, set the date and time, and the sphere lights up the way the real sun did at that exact patch of Earth.

    It's the same pack as the other three sphere nodes: a reference-image renderer for the Sun-Direction LoRA on Flux 2 Klein, where lighting direction is the thing the model was trained to obey. All the rendering is done in your browser with Three.js and a NOAA solar-position calculator; the Python side just decodes the baked image. No API, no network lookup, works offline.

    Inputs that matter

    • latitude (-90 to 90) and longitude (-180 to 180) - degrees, negative means south/west. This is the node's whole reason to exist, and it's also where the one real trap lives: exactly 0, 0 is treated as "not set yet", so a spot on the equator in the Gulf of Guinea won't resolve. Nudge either value a hair (e.g. 0.0001, 0) and it works.
    • hour / minute - local time. The timezone isn't something you set; it's borrowed from the nearest city in the bundled list, DST handled automatically. Slightly surprising if you're in the middle of nowhere, but it's a reasonable default.
    • heading (0–360) - camera facing, clockwise from North, matching EXIF GPSImgDirection. The compass on the preview turns with it.
    • intensity (0.2–3, default 1.5) - light strength.
    • year / month / day - the date.

    One render output (IMAGE, 1024Γ—1024) feeds the Sun-Direction LoRA's reference input. The node also shows a status line with the nearest listed city, so you get a sanity check that your coordinates resolved to roughly the right place.

    The natural pairing: feed it from a photo

    This node's best trick is when you don't type coordinates at all. Wire the Photo (EXIF) node into it - latitude, longitude, heading, and capture time all come out of a real photo's metadata and drive the sphere. Suddenly you're not matching "somewhere at some time"; you're matching the exact light a photo was taken in. That's the workflow the pack's README leads with.

    Install

    ComfyUI Manager (search Sphere Light Render) or:

    cd ComfyUI/custom_nodes/
    git clone https://github.com/eric-venti-seeds/Sphere-Light-Render-ComfyUI.git
    

    Restart, then download the Sun-Direction LoRA from HuggingFace (Sun-Direction-Lora-Flux2Klein9B / ...Klein4B) - without it the sphere is just a pretty picture. No other dependencies to wrangle.

    Gotchas

    Two to keep in mind, both shared with the rest of the pack. Driven inputs need an open browser tab - the browser is what renders the sphere and bakes it into the workflow before each run, so a headless or API queue won't see newly driven values (use the widgets for those). And each node adds 100–400 KB of baked base64 image to your saved workflow JSON, which is normal here, not corruption. Watch the 0, 0 coordinate trap above and you're most of the way there.

    Categoryrender/3d

    Inputs (10)

    NameTypeDefaultDescription
    intensityFLOAT1.50.2–3Light strength.
    latitudeFLOAT0.0000-90–90Degrees north (negative = south).
    longitudeFLOAT0.0000-180–180Degrees east (negative = west).
    yearINT20251–9999β€”
    monthINT61–12β€”
    dayINT211–31β€”
    hourINT120–23Local time at the location (timezone borrowed from the nearest listed city).
    minuteINT00–59β€”
    headingFLOAT0.000–360Camera facing, degrees clockwise from North (matches EXIF GPSImgDirection).
    render_b64STRINGInternal: the browser-rendered sphere image (managed automatically).

    Outputs (1)

    NameTypeDescription
    renderIMAGEβ€”