- Home /
Meshes turn black after baking lightmap
I've been struggling to bake my scene for several days. And I don't know where to look at to solve the issue.
I have a scene made up of some outdoor stuff and a room with no windows. Inside the room, there are four point lights. Models are imported OBJ models. In the editor before baking, the everything looks nice. After the bake, things go black.
The upper half is what I expected, the lower half is what I got:
You can see the floor and walls are blacked out. And it seems light would go through the floor and light the basement below it.
In additional, I've turned off the skybox and directional light in this example, but when they were on, the light can shine through the walls.
Here is my light setting:
I am not familiar with 3D modelling, and don't know what to do. It would be appreciated if someone can point me to the direction of solving the issue.
Answer by SteenPetersen · May 29, 2020 at 05:46 AM
Hi @aristojoyce
There could be several causes for this, one could be that you need to Generate Lightmap UVs. Try turn on "Generate Lightmaps UVs" in the import options of your meshes. Also, could the normals be flipped?
Thanks for the quick reply. This did the trick. I've tried checking "Generate Lightmap UVs" before but it gave me error so I reverted that. Turns out the error is not relevant and it works.
Glad I could help, remember to upvote answers that help as it helps those that answer the question as well as making it easier to find for other users of the community.
Thank you! this was the solution to my problem. (Try turn on "Generate Lightmaps UVs" in the import options of your meshes)
In my case, I had to open a new scene and go back to my original scene.. for some reason.
Your answer
Follow this Question
Related Questions
Indoor Lighting Scene - Baking? Realtime? 0 Answers
How do I adjust the lightmap parameters for objects in Unity 2018? 1 Answer
Emission is not working, or GI is not working Unity 5.50b7 0 Answers
Where is Enable precomputed realtime GI? 3 Answers
Can/Should I bake lightmaps in a completely dark room? 1 Answer