Skip to main content

Lightmapped prefabs

This tutorial uses an elevator cabin as an example. You will bake a source Blueprint instance, store its surface lighting and optional interior probes, then verify a second copy.

The same sequence works for room modules, vehicle interiors, and reusable scenery. The important limitation is that each copy carries the authored lighting. It does not calculate fresh GI for its new surroundings.

1 Build the Blueprint​

Create or open the Blueprint containing the cabin's floor, walls, ceiling, and other fixed meshes. Ensure the meshes have suitable lightmap UVs and resolution using the preparation steps in First bake.

In the Blueprint editor, add Spectral Lightmapped Prefab through Add Component. Compile and save the Blueprint.

Keep the source root and meshes you intend to bake Static. Do not start with a Movable source and expect Capture to invent missing lightmaps.

Checkpoint: the assembly is a Blueprint with the Spectral Lightmapped Prefab component, not just a collection of unrelated level actors.

2 Add optional lighting for passengers​

The cabin's lightmaps describe its surfaces. To give objects inside it a field they can sample, add Spectral Prefab Volume in the same Blueprint.

  1. Fit its box around the interior where passengers or movable objects will be.
  2. Leave Enabled on.
  3. Start with the default Voxel Size and inspect the markers using Visualize Probes.
  4. Reduce spacing only if the cabin's lighting variation needs it.
  5. Compile and save.

This component is authored inside the Blueprint. An ordinary level Spectral Probe Volume is not a substitute for an embedded prefab field.

You can omit the volume if only the prefab's baked surfaces are needed. Multiple fields are useful for separate regions, but also increase capture size.

3 Place and light a source​

Place one instance in an authoring level and give it a recognizable name, such as Elevator_CaptureSource. Check its root and mesh mobility again on the placed instance.

Arrange the lighting you want the cabin to carry. Keep the source surroundings intentional: an external colored wall or bright window can influence the captured result just as it influences an ordinary bake.

For an enclosed cabin that moves between differently lit floors, consider which illumination should remain fixed and which must come from runtime lights. The capture will not adjust itself when the elevator reaches a new landing.

4 Bake the source​

Load and show the source level, then run Spectral > Baker > Bake Lighting. Wait for rendering and denoising to complete.

Inspect the source's surfaces before capturing. If you included a Prefab Volume, inspect its baked field too. Repair UV problems or coverage gaps now rather than distributing a bad result to every copy.

Save the level and lighting build data.

Bake first, capture secondInfo

Bake Lighting calculates the lighting. Capture stores that existing result for the Blueprint's copies. Capture does not run a new bake, and saving a Blueprint alone does not capture lighting.

5 Capture from the placed source​

  1. Select Elevator_CaptureSource in the level.
  2. Select its Spectral Lightmapped Prefab component in Details.
  3. Under Prefab Bake & Capture, click Capture.
  4. Read the capture message.
  5. Check Shared Capture for surface bindings and, if used, probe fields.
  6. Check Last Capture to confirm the intended source supplied the result.
  7. Save the Blueprint and changed assets.

Capture is available on a placed editor instance, not the Blueprint template, during Play, or during an active build. A nonzero entry count confirms stored entries, not that the source was correctly prepared.

The capture is sharedWarning

Capturing replaces the lighting for copies of this Blueprint, including loaded copies and future instances. Keep a recoverable version before overwriting a capture used elsewhere. Capturing a different instance is not a way to give only that instance unique lighting.

6 Verify a second copy​

Place another instance away from the source. Leave Apply Captured Lighting enabled and compare its surfaces with the source.

For an elevator, use Unreal's normal root/component mobility setup to make the gameplay copy Movable. Spectral has no separate prefab movement switch. Check the mesh hierarchy so attached components can move with the root.

Run Play mode and exercise the elevator's existing movement logic. This tutorial prepares its lighting, not its movement Blueprint. Inspect the cabin surfaces, embedded field coverage, and any passenger test object throughout the motion.

Checkpoint: moving the cabin carries its stored lighting and included field. It should not need a fresh bake at each floor. A mismatch with the landing's lighting may be an authoring limitation, not a capture failure.

7 Choose static or movable reuse deliberately​

A captured Static copy reuses its surface lighting while still participating in the level's baked shadows and bounced light. Bake the surrounding level when those contributions change.

A captured Movable copy is excluded from the static build, so it does not leave a new static baked shadow behind as it moves. Runtime shadows remain a separate rendering concern.

Keep a suitable Static authoring source for future updates, even when the gameplay copies are Movable.

8 Update without losing track of the source​

After changing the internal mesh layout, UVs, lighting, or embedded field definitions:

  1. Return to the intended source and verify its Static setup.
  2. Bake again and inspect the result.
  3. Capture again from that source.
  4. Read the message and Last Capture.
  5. Save and retest a second copy.

Once manual capture is reliable, enable Auto Capture After Bake on the intended source if you want successful future builds to refresh the shared capture. It does not make every copy a source.

To temporarily stop one copy using the payload, disable Apply Captured Lighting. Clear Capture removes the shared payload and disables automatic capture, so it is not a per-instance troubleshooting toggle.

9 Check cost and common failures​

Refresh the Prefabs group in Memory and inspect Captured Data Cost on the component. These figures describe lighting, not the Blueprint's total asset or gameplay cost.

ProblemWhat to check
Capture unavailableSelect the placed instance; stop Play and wait for any bake to finish.
No baked lighting foundCheck Static source mobility, eligible mesh lightmaps, and successful bake completion.
Missing probe fieldsCheck that enabled Spectral Prefab Volume components are in the Blueprint and were baked.
Copies still show old lightingCheck the intended source, capture message, saved Blueprint, and Apply Captured Lighting.
Construction script replaces componentsReview bindings and the component's Apply Lighting function; layout changes can need a new bake and capture.

See the Lightmapped Prefab and Prefab Volume references for the individual controls.