Skip to main content

A Beginner's Guide To Using Bakery

If you open the Bakery window, it'll change your lighting settings so that Unity won't try to automatically overwrite the lightmaps it bakes. Because Bakery is seperate from Unity's lighting system, you'll need to take note of the following:

  • Don't use the "Generate Lighting" button in the Lighting window, or Unity will overwrite the Bakery lighting.
  • Don't turn on "Auto Generate" in the Lighting window for the same reason.
  • Don't use the "Bake" button on Reflection Probes, unless they're Custom. Clicking "Bake" on a reflection probe in "Baked" mode will start the whole Unity lightmap baking process.

Bakery doesn't use Unity's Light components. If you have a regular Light in your scene, it will always be rendered as a Realtime light. Instead, Bakery comes with its own set of Light components, which have different settings from Unity's own.

You can place a Unity light and a Bakery light on the same object. If you place a Bakery light onto a Unity light, it will provide options to copy the Unity light's parameters. This is handy for when you want to convert a lot of lights to Bakery lights - just select them all, add the corresponding Bakery Light component, and select "copy from realtime light".

When baking the light from Bakery, it will also set the Baked flag on the Unity light. This can be used for Mixed lighting, which has the same performance impact as a Realtime light, but looks nicer due to having bounced indirect lighting from the environment. Or you can use it to preview directional and point lights before you bake them, visualizing them as Realtime lights.

With Unity, the skybox is automatically used to render ambient light in the skybox, but this isn't the case with Bakery. To render ambient light, you must add a Bakery Sky Light component. The Sky Light will cast lighting from all around the outside of your scene onto it using either an ambient colour or a cubemap. Without ones, shadows will be black.

Ideally, you should render a cubemap of your skybox using a Custom reflection probe, with everything but the sky hidden. Then use the resulting texture in the Sky Light. The result will look accurate and smooth.

Bakery DOES use Unity's Light Probe Group components to bake light probes. It provides two Light Probe Modes:

  • L1, where Bakery will create the light probes with the lightmapping process. This is the default and fastest option. It has the minor disadvantage of seeing the scene as Bakery sees it, rather than how Unity sees it, so it won't capture special shader effects properly.
  • Legacy, where Bakery will create the light probes after the lightmapping process. It generates the probes from rendering the scene in Unity into reflection probes, which ensures the results are accurate, but it's a bit slow.

If you use L1 mode, light probes are baked at the same time as the lightmap. If using Legacy mode, you'll need to bake them separately. Bakery will bake data into light probes when the "Generate Light Probes" button is clicked.

So, to review, when making lighting for a scene, you should:

  • Disable Unity light components, unless your lights are Mixed.
  • Add a Bakery Skyprobe, and give it a skybox cubemap to use for ambient light.
  • Add a Bakery Direct Light, and set it up as you would the main directional light.
  • Add Bakery Point Lights if you need them.
  • Make sure your scene has lightmap UVs.
  • Use the Show Checker option in Bakery to see the resolution of your lightmap on individual meshes, and adjust them if necessary.
  • If you have an RTX capable graphics card, turn on RTX mode.
  • If your scene uses normal maps, set the Directional Mode to Dominant Direction, which is the most compatible mode.