Renderer · const

GI_SOURCE_SCREEN

Three levels, and the architecture is the fallback rather than any one of them.

Explained in Hello world.

const GI_SOURCE_SCREEN = 0
import { GI_SOURCE_SCREEN } from '@driftengine/core';

In depth

ROADMAP.md refused screen-space global illumination, and this does not reverse that refusal — it satisfies the requirement the refusal was about. Screen space is exact wherever the screen has the answer and has no answer where it does not, which as a terminal technique means inventing one from whatever happened to be in frame. Here it is an accelerator with something behind it: a world-space distance field whose error is bounded by its own resolution, and behind that a probe volume which is never wrong and only ever coarse.

The last level cannot fail, and that is the load-bearing sentence. A ray with no answer leaves a shader nothing to write but what the buffer held, which is the previous frame and reads as a flicker. A probe volume is an interpolation between measurements — no ray to escape, no frame to leave — and visibleProbes falls back to the nearest probe even when every visibility weight has crushed to zero. So there are exactly three cases.

And the levels blend rather than switch. Every boundary between them moves with the camera: the frame's edge does by definition, and the cascades are centred on the camera so their faces do too. A hard switch at a boundary that moves is a seam that sweeps across the picture whenever the camera turns, which is worse than either level's own error — an error that is wrong everywhere reads as a coarse solution, and one that changes abruptly along a surface reads as a crack.