Skip to content

Commit 0f9791e

Browse files
authored
Merge pull request #11189 from Calinou/using-gridmaps-baking-lightmaps
Add a section on baking lightmaps in Using GridMaps
2 parents bce621f + 5d8fb8d commit 0f9791e

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

tutorials/3d/using_gridmaps.rst

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,21 @@ additional nodes can be added as source geometry just for baking the navmesh.
8989
The baked cell size of the NavigationMesh must match the NavigationServer map cell
9090
size to properly merge the navigation meshes of different grid cells.
9191

92+
Lightmaps
93+
---------
94+
95+
It is possible to bake lightmaps onto a GridMap. Lightmap UV2 data will be reused
96+
from meshes if already present. If UV2 data is not present, then it will be
97+
automatically generated on bake with a lightmap texel size of 0.1 units.
98+
To generate UV2 data with a different lightmap texel size, you can set the
99+
global illumination mode in the Import dock to **Static Lightmaps**
100+
and specify the texel size there. This option must be changed *before* the scene
101+
is converted to a MeshLibrary, as changing it later on will not affect
102+
the existing MeshLibrary data.
103+
104+
Aside from this peculiarity, the lightmap baking process is the same as for any other 3D scene.
105+
See :ref:`doc_using_lightmap_gi` for more information about lightmap baking.
106+
92107
MeshLibrary format
93108
------------------
94109

@@ -120,7 +135,7 @@ as a resource.
120135

121136
.. image:: img/gridmap_export.webp
122137

123-
You can find an already exported MeshLibrary in the project named "MeshLibrary.tres".
138+
You can find an already exported MeshLibrary in the project named ``MeshLibrary.tres``.
124139

125140
Using GridMap
126141
-------------

0 commit comments

Comments
 (0)