Choose a light baking backend
Choose which backend Unity uses to bake lightmaps and Light Probes, and configure it for your project and hardware.
阅读时间2 分钟最后更新于 25 天前
To generate baked lightmaps and Light Probes, Unity provides the following light baking backends:
-
The Unity Compute Light Baker uses your computer's GPU and video RAM (VRAM). It relies on the Unity Compute shaders and the Unified Ray Tracing API. It's available in the Universal Render Pipeline (URP) and the High Definition Render Pipeline (HDRP) only.
-
The Progressive GPU Lightmapper uses your computer's GPU and video RAM (VRAM). It relies on OpenCL.
-
The Progressive CPU Lightmapper uses your computer's CPU and system RAM.
The Progressive GPU Lightmapper and the Progressive CPU Lightmapper are the two backends of the Progressive Light Baker.
If your project uses the Built-In Render Pipeline, the Unity Compute Light Baker isn't available. Use the Progressive GPU Lightmapper instead.
Select a light baking backend
Selecting a backend has two levels: you select the default light baker for the project, and then, if the project uses the Progressive Light Baker, you select the backend for each scene.
Select the default light baker for the project
- From the menu, select Edit > .Project Settings
?
- Select Graphics.
- In the section, set Default Light Baker to Unity Compute Light Baker or Progressive Light Baker.Light Baker
?
For more information, refer to Light Baker in the Graphics settings window reference.
Select the backend for a scene
This step applies only when Default Light Baker is set to Progressive Light Baker.
- From the menu, select Window > Rendering > Lighting.
- In the Lightmapping Settings section, set to Progressive CPU or Progressive GPU.Lightmapper
?
You can perform many of the functions available in this window via scripts, using the LightmapEditorSettings and Lightmapping APIs.
Progressive GPU Lightmapper hardware and software requirements
In order to use the Progressive GPU Lightmapper, your computer must meet these minimum specifications:
- At least one GPU with OpenCL 1.2 support
- At least 2GB of VRAM dedicated to that GPU
- A CPU that supports SSE4.1 instructions
If the scene you are baking requires more VRAM than is available on the designated GPU, bake times can significantly increase.
The Progressive GPU Lightmapper does not support OpenCL CPU devices.
The Apple silicon version of the Unity Editor is not compatible with the Progressive CPU Lightmapper. However, it is compatible with the Progressive GPU Lightmapper and the Unity Compute Light Baker.
Render pipeline support
Refer to render pipeline feature comparison for more information about support for light baking backends across render pipelines.