Baking
Baking the scene
Bake from the Render menu in RAPTOR's top bar.
Save the scene
File → Save in Unity
Bake
Choose Render → Bake lighting. Changed models are built first. The Render menu shows Baking with a percentage.
Keep the result
With Bakery, RAPTOR saves the scene at the end of the bake. Otherwise, save the scene to keep the lightmaps.
To cancel, press Cancel in Unity's Lighting window or Bakery's progress window. The ray-traced preview pauses during a bake.
After a bake, Unlit and Wireframe 3D views switch to Shaded. Moving or editing part of a baked model, or placing or moving one of its lights, makes its lightmap out of date until the next bake, and a Shaded view switches to Unlit. To turn this off, use Settings → General → Shading follows bake.
Lightmaps belong to the scene
A saved model does not carry its lightmaps. Bake again after loading a model into a scene.
Bake settings
Render → Bake settings opens these settings. The quality and the probes are saved for you only, the Custom settings for the project.
| Setting | Effect |
|---|---|
| Quality | Sets Draft, Final or Custom quality, by the names the project gave them. Custom is there while Show Custom is on. See Quality |
| Probes | Bakery only. How props and moving parts are lit: Volumes or Off |
| Bake lighting | Starts the bake |
The note under the button shows what the bake covers and how the last bake ended.
Quality
Higher quality uses larger lightmaps and more samples, and takes longer to bake. These are the values a new project starts with. Baking presets changes them for the project.
| Option | Effect |
|---|---|
| Draft | 32 texels per metre, maps up to 2048 px |
| Final | Twice the texel density, maps up to 4096 px, four times the samples |
| Custom | Uses the values you set |
The scene's lighting settings are restored after the bake. A scene without Lighting Settings gets one named RAPTOR Lighting.
Custom adds these settings:
| Setting | Effect |
|---|---|
| Texel density | Lightmap texels per metre, 2 to 1024 |
| Light samples | Samples for direct light and shadows, 1 to 1024 |
| GI samples | Samples for bounced light, 1 to 1024 |
| Bounces | How many times light bounces, 0 to 5 with Bakery, 0 to 16 with Unity. With Unity it also changes the scene's setting |
| Volume density | Light volume probes per metre, 0.25 to 16. Bakery only |
| Sample divider | Divides the samples for a faster test bake, 1 to 8 |
| Denoise | Removes noise from the lightmaps |
Lighting things that move
The baked light of a room reaches things that are not part of its lightmap, such as the player's character, Dynamic props, Moving parts and anything your game spawns, in Play mode and in a game build.
- Unity bake: every model gets a child named RAPTOR Light Probes, a grid of light probes about one every 2 metres, baked with the lightmaps. A model that already holds a Light Probe Group of your own keeps only yours.
- Bakery bake with Probes set to Volumes: each model's light volume lights them. This needs Bakery's URP shader package.
- To keep an object and everything under it out of the light volumes, add RAPTOR → Skip Light Volume to it.
Baking presets
Settings → Baking sets the presets for the whole project, so everyone who opens it gets the same ones. A project that never opens this page bakes with the values above.
| Setting | Effect |
|---|---|
| Show Custom | Puts Custom in the Render menu and opens its tab |
| Draft, Final, Custom | One tab per preset, named after it. Reset puts the tab's values back to the ones a new project starts with, and keeps the name |
| Name | The preset's name in the Render menu, the last bake's note and the Console. At most 12 letters. A name another preset already has shows In use and is not kept |
With Bakery, Draft and Final hold Lightmap size (x1, x2 or x4), Light samples, GI samples, Sample divider, Denoise, Volume density and Fast GPU. Without Bakery they hold the Progressive lightmapper's values: Texel density, Max lightmap size, Direct samples, Indirect samples, Environment samples and Denoise.
With Bakery, Custom also lists Bakery options: Bakery's full list of render settings, in the groups of Bakery's own window. A changed setting has a reset button, and Reset all clears them all. These only apply to a Custom bake, and every value goes back after it.
While Bakery's GPU test is needed, the page starts with Bakery needs setup, with Set up Bakery and Bake without it.
Sky and sun
The sky lights a bake only through faces with the Skybox material applied, under Special in Materials. Set the scene's sky in the Sky panel, and bake again after changing it.
- With no Skybox faces, the sky adds no light.
- With Skybox faces, the scene's skybox lights the level where it is open to the sky.
- For a sun, add a Directional Light set to Baked or Mixed.
When a bake does not start
The Render menu and the note in Bake settings show the reason:
| Message | Fix |
|---|---|
| No baker | See Troubleshooting |
| Save scene | Save the scene |
| Baked GI off | Turn on Baked Global Illumination in Unity's Lighting window |
| Bakery scene | See Troubleshooting |
| Bakery needs NVIDIA | Bake on a PC with an NVIDIA GPU, or choose Use Unity's lightmapper. See Unity or Bakery |
| Bakery needs setup | Choose Set up Bakery or Bake without it. See Unity or Bakery |
| Exit Play mode | Leave Play mode, then bake |
| Nothing to bake | Add a part that does not move. Bakery does not bake moving parts |
If a model fails to build, the bake stops and the Console names the model.
Bakery project settings
These settings are in Edit → Project Settings → RAPTOR → Bakery when Bakery is installed.
| Setting | Effect |
|---|---|
| Bakery | Shows OK, or Partial if RAPTOR cannot find everything it needs in your Bakery version |
| GPU | Shows NVIDIA or Not NVIDIA |
| Setup | Shows whether Bakery's GPU test has run on this GPU: Set up, Needs setup, Baking without setup or Not checked, with Set up Bakery and Bake without it |
| Baker | Shows Unity lightmapper while this PC bakes with Unity's lightmapper, with Use Bakery to take it back |
| Fast GPU | On, Auto or Off. On, Draft and Final use a tile sized for the GPU and the RTX mode that Bakery's GPU test recommends. Auto does that only on a GPU with hardware ray tracing. Off keeps Bakery's own settings |
| Lightmap group folder | Sets a folder of lightmap groups your project makes itself. New model names are checked against it. The folder must exist. RAPTOR's own groups are saved beside the scene |
| Settings guard | Stops a scene's Bakery settings from resetting |
| Auto sky | Adds the RAPTOR Sky when a model first gets Skybox faces |
Unity or Bakery
Bakery is a separate paid asset. RAPTOR works with or without it.
| Part | Without Bakery | With Bakery |
|---|---|---|
| Lights placed | Unity lights, set to Baked | Bakery lights |
| Baker | Unity's Progressive lightmapper | Bakery |
| Needs | A saved scene, with Baked Global Illumination on | An NVIDIA GPU, and Bakery 1.98 or newer (1.985 or newer on Unity 6.5 and later) |
| Sun and sky | A Directional Light you add | The RAPTOR Sky, added automatically |
Edit → Project Settings → RAPTOR → Lighting → Light backend shows which one is in use.
- Before the first Bakery bake, Bakery tests your GPU once per project. Until it has, the Render menu and Bake settings show Bakery needs setup and the bake waits. Set up Bakery runs Bakery's own test and results window. Bake without it skips the test for this GPU, after one question. A PC with another GPU is asked again.
- On a PC without an NVIDIA GPU, in a project that has Bakery, the Render menu and Bake settings show Bakery needs NVIDIA with Use Unity's lightmapper. This PC then bakes with Unity's lightmapper, and a PC with an NVIDIA GPU keeps baking with Bakery. The choice is kept for this PC only, never in the project's files. Use Bakery in Edit → Project Settings → RAPTOR → Bakery takes it back.