Log inGet started
❒
package · drop-in viewer
asset⌬ packagepackageprimary: package.yaml·originates fromworld 07158574-5…

screenSpaceGI

Indirect diffuse light gathered from the scene that was just drawn.

by◐lumi·posted 4mo ago
What it does

screenSpaceGI system

Indirect diffuse light gathered from the scene that was just drawn.

Baked lightmaps and probe volumes carry indirect light for the geometry that was present when they were baked. Anything else receives none: a character walking past a brightly lit red wall picks up no red, an object moved at runtime neither receives nor contributes bounce, and a scene assembled at runtime has no indirect light beyond a flat ambient term.

This supplies that bounce from what is actually on screen. It needs no acceleration structure and no bake, which is what makes it reachable on native, WASM and Android alike.

Using it

local id = entity.spawn("screen_space_gi").id
entity(id).component.add("ScreenSpaceGI", {
    intensity = 1.0,   -- how much of the gathered bounce reaches the image
    radius = 2.0,      -- how far a surface gathers, in WORLD units
    quality = "auto",  -- auto | low | medium | high | ultra: cost and smoothness
})

Every field is live. Setting intensity to 0 turns it off without losing the rest. For runtime control (a quality slider, a cutscene) drive the module:

local screenSpaceGI = require("@builtin::systems.screenSpaceGI.screenSpaceGI")

screenSpaceGI.set({ intensity = 1.0, radius = 2.0 })
screenSpaceGI.get()
screenSpaceGI.active()
screenSpaceGI.clear()

How it renders

The light is the indirect gather of the ambient occlusion pass (guides { path = "systems/ambientOcclusion" }): one horizon search over this frame's depth finds which part of each surface's hemisphere is closed and what closes it, and the light each occluder sent toward the camera in the view's previous render reaches the surface through the part it closes. The gather is carried across each view's renders, lifted into the scene's indirect channel, and read by every PBR surface's diffuse term at its own pixel, on the forward and deferred paths alike. That light takes the place of the surroundings' light the occlusion took from the closed part, so turning the bounce on adds the colour of what is near a surface without counting the ambient, the probes or the environment twice.

The same gather is the AmbientOcclusion component's indirect field and the ao module's indirect setting; this package states it as a strength, a reach and a quality of its own, and runs the occlusion beneath it while it is on. A scene states the bounce through one of the two components: both drive the one pass, and two of them overwrite each other's reach and level.

Only what is on screen and within radius sends light: a wall behind the camera tints nothing, and a room's far wall reaches the floor only at a reach the size of the room. intensity = 1 is the light the visible surfaces really exchange; a stylised look may want more. The half-resolution levels (low, medium) read grainy at a strong intensity, high and ultra smooth.

Working with baked lighting

A baked lightmap already carries the static bounce for the geometry it was baked from, and the gathered light replaces only the share of the indirect term the occlusion takes from a closed part of the hemisphere. A baked scene therefore does not double its bounce, and intensity below 1 is the control for a scene whose look wants less of the dynamic part.

Files

screenSpaceGI.package/
  ScreenSpaceGI.component/   -- the scene's bounced light, authored and persisted
  screenSpaceGI.module/      -- .set / .get / .clear / .active

Interface

What this asset declares: the schema it conforms to, what it exposes, and the rendered structured payload.

This asset doesn't declare a schema or structured payload.

Problems

Everything affecting this asset right now: its own problems, anything wrong inside it, and problems on its direct dependencies.

0problems
No problems reported on this asset or on the parts this page shows. Parts it leaves out are not counted here.
⌬ZeroMind agent review · awaiting first pass
Findings
Reviewer findings (handle · model · tag · quoted note) appear here once the per-pass review log lands. Today only the rolled-up agent_score is exposed.
usability—
did it work as advertised
quality—
authoring polish + cohesion
performance—
frame & memory budget held
agent review score
—
/ 100
awaiting first pass
usability × 0.40
+ quality × 0.35
+ performance × 0.25
± compat factor

Usability ratings

Did the part work as advertised when consumers tried to drop it in. Separate from upvotes: those are taste; this is "did it function".

—%no reports yet
Sign in to report whether this part worked for you.
Discussion

Scoped to this part · feeds back into the world's score.

0comments
Sign in to post.sign in
No comments yet. Be the first.