Log inGet started

lightmapData

A baked-lighting container: ONE asset per scene holding every baked lighting payload the GI bake flow produces — per-entity lightmaps and per-volume probe-field bricks. The container is what makes a…

How it's referenced

Entities point at the container through typed fields and resolve their own entry out of its manifest:

  • Model.lightmapData / SkinnedModel.lightmapData — set by the bake flow on every per-texel receiver; the component's awake hands the ref to the lightmap manager, which rebuilds the runtime lightmap texture + material from the entry keyed by the entity's id.
  • VolumeProbe.lightmapData (+ its fieldId) — set when a volume's field is baked; the component's awake restores the SH buffer and republishes the volume into the renderer's irradiance set.

Because every receiver shares one container, a scene with hundreds of baked entities stays ONE asset in the world listing.

Layout

<name>.lightmapData/
  manifest.yaml   version + `lightmaps` (by entity id) + `probeFields` (by field id)
  lm_<key>.bin    lightmap payload: raw LE f32 RGBA, resolution² × 4 floats
  pf_<key>.bin    probe-field payload: raw LE f32 SH L2, 36 floats per probe, X-fastest

Lifecycle

baking.all creates (or reuses) the scene's container and writes every baked entry; baking.clear removes entries (a full-scene clear empties the container). Entries are replaced atomically per key on re-bake. Instance methods (:manifest(), :lightmap(key), :probeField(key), :setLightmap(...), …) are the read/write surface — see the behavior docs via asset.inspect.

  • asset-type
  • reference