Hello,
Our game at runtime gets a lightmap texture array from a prefab, add them to the scene LightmapSettings, and assign the updated lightmapIndex to the renderers.
// Update scene available lightmaps
LightmapSettings.lightmaps = newLightmapArray;
// (Inside a loop) Assign index to renderer
info.renderer.lightmapIndex = lightmapOffsetIndex[info.lightmapIndex];
We initially had a problem with it due to Unity stripping unused UV channels (“Optimize Mesh Data” options under the “Player” settings), but it is not the case anymore.
This has been working fine in the 2019.3 version, both in editor and build.
Since updating to the alpha version, this works only in the editor windows, and does not work in build.
I added logging and can confirm that both the textures and the meshes are the same as when in the editor.
I tried disabling texture mipmaps and texture streaming, with no effect.
I read from the release notes that a lot of work has been done in global illumination, maybe there are some additional steps we must do to apply the new lightmaps at runtime?
Thank you