I’ve just updated my project from Unity 6.0 to Unity 6.3. I’m also using Enlighten to Realtime GI. As soon as I baked lighting in one of my scenes, I saw all sort of warning in the log:
“‘MainHall’: Instance with invalid UV bounds was removed from light baking input. This instance will not be lit by or affect baked lighting.”
Pretty much every FBX model I have is generating this error now, which was not happening under Unity 6. The models all have a single UV map assigned named “UVMap”, which is the default when creating a model in Blender. It seems that this now causes the model to have invalid UV bounds for light baking. I can “fix” this for a given model by editing the model in Blender, adding a “UV2” UV map.
Do we seriously need to do this now? That’s a huge amount of work. Is there a setting that just tells the light baking to use the first UV map if it doesn’t find a UV2? This feels like a massive regression.
It looks like I just needed to tick the Generate Lightmap UVs" box for the model:
I’m also seeing a bunch of these warnings after updating to 6.3 and I’m confused.
My project uses realtime lighting and realtime GI only. Not mixed. No baked lights, no baked GI. I’m under the impression that realtime lightmaps and other necessary lighting data are still required to be created via the “Generate Lighting” button, even if I have no baked lights/GI. I have light probes set up in my scene (via Magic Light Probes).
The warning states objects wont be lit by lit by or affect “baked lighting”. If I have no baked lighting, why am I seeing this warning?
Is this warning worth looking into more, or can I ignore it? Do I need to generate lightmap UVs for realtime GI to work properly?
I was not receiving this warning until 6.3 and did not change my lighting settings. Have I been doing it wrong all this time, or is this warning being shown in error?
There may be some subtlety to it, but I’m pretty sure the warning can be ignored in your case (which is also my case: Only using Realtime GI, no other baked lighting.) I’m basing this assumption on the fact that even with these warnings appearing for certain models, I still see those models showing up properly in realtime lightmaps. I don’t see any difference in the lighting before and after fixing the UVs for the model.
I’ll probably just enable the “Generate Lightmap UVs” every time I see this, to avoid console log spam, but I think it’s unnecessary. The only thing I’m not sure about is whether static emissive objects won’t cast light correctly when this warning is showing up. But I’m honestly not sure if I still have any static emitters…
This issue is decisively not fixed. I was using Unity’s Adaptive Probe Volume in 6.2 without problems, and now that I upgraded to 6.3 LTS APV REQUIRES lightmap UVs even if it doesn’t need them (or didn’t use to).
I use up to 4 UVs sets for custom shaders, so enabling “Generate Lightmap UVs” is not an option. I will have to resort to having dedicated geometry for baking the APV that I turn off. Frustrated that this used to be simpler.
Agree, its super annoying. I dont want a create Lightmap UVs for objects where i dont need lightmap UVs. It slows down our workflow.
It would be great if someone from Unity could explain why it is done this way.
Any object that affects GI (any Mesh Renderer with Contribute GI enabled) requires lightmap UVs. When baking GI, either using lightmaps or APV, we render the albedo and emission of each Mesh Renderer into sets of textures, which are used as lookup textures whenever a light ray hits a surface.
These sets of textures are rendered using the Meta Pass of the associated material. This pass uses the lightmap UVs, and will produce unpredictable results when fed UVs that are not suitable for lightmapping (contain overlapping UV islands or islands without sufficient padding). Suitable UVs can be generated either using the “Generate Lightmap UVs” toggle, or manually with a third party tool.
Objects that only receive GI, but don’t affect it (Mesh Renderers with Contribute GI disabled, and Receive GI set to Light Probes), do not require lightmap UVs. If you are seeing warnings for these kinds of objects, that is probably a bug.
The warning should only be displayed for GI contributors with UVs that have been deemed invalid, either because they are missing, contain invalid data like NaN/Inf, or are degenerate (for example having area=0). Before the warning was added, I believe these kind of contributors were either silently ignored, or used incorrect albedo and emission data.
I don’t believe lightmap UVs should be required in scenes that only use Enlighten Realtime GI, since Enlighten creates its own UV layouts. This sounds like a potential bug, did you ever file a bug report?
Sorry for the delay, but I’ve submitted a bug report for this. It’s listed as IN-148577: Jira Service Management
I’ve confirmed that the behavior is the same still as it was when I first mentioned this. Models that don’t have UV2s (despite having other UVs), and don’t explicitly turn on Unity’s “Generate Lightmap UVs” will produce these warnings when baking. However, the models still bake fine for indirect lighting, despite the warnings. So, the warnings appear to be false.