Expand description
Image-based lighting (IBL) bake — the data-layer “environment → GPU” projection.
IblBaker runs once at startup (driven by the ibl_bake DataSystem)
and produces the static GPU resources image-based lighting samples:
- an environment cubemap (a procedural sky for now, an authored HDR later),
- a diffuse irradiance cube (cosine-convolved environment),
- and — added in a later increment — a prefiltered specular cube + the split-sum BRDF LUT (both stand-ins for now).
Because the bake is one-time and needs render passes, it records into a
standalone command encoder ([GraphicsDevice::create_command_encoder])
and submits it directly, outside the per-frame loop — no lane or agent
required. The resulting [IblGpuBindings] is stored behind interior
mutability (the baker is a shared resource) and consumed by the lit lanes
at group 3 via IblBaker::bindings.
Structs§
- Environment
Map - Selects the scene’s environment source for the IBL bake.
- IblBaker
- One-time IBL bake service. Registered as a shared resource at bootstrap and
driven by the
ibl_bakeDataSystem, which callsensure_bakedevery frame; the bake itself runs only on the first call.