Lighting and Lightmaping Problems With Unity 3

I am having lots of problems when lighting a scene with unity 3. I just purchased a license and yes it does create lighmaps uvs on the fly, but where can I modify the resolution of the objects, or is everything rendered on 1K by 1K?
Also how does unity pack the lightmaps because I have a complex scene with lots of objects and it just told me that I have a lightmap limit of 254 lighmaps. That is a huge number of lightmaps so my question is how can I optimize this if I have no control on how Unity is packing the lightmaps.
Is anybody else experiencing that when they bake the whole scene some objects wont get lightmaped, but when i bake selected, everything else looses their lightmaps?
Need some help please if anybody has some documentation on how to properly light a complex scene in Unity 3 it will be greatly appreciated.

The lightmaps are generated basing on your configuration in the dialog (your texel density). That will define how large the lightmaps will need to be.

and if an object does not get a lightmap, its either not marked as static, has a second uv channel you marked to not touch or just is not touched by bake or bake&dynamic lights

Thanks for your fast reply! But everything has 2 uv sets and all the geometry is set to static.
The strange thing is that when i render the whole scene some objects just will not render, but when I bake the objects on their own using the bake selection option I loose all of the other lightmaps. Is this a bug?
Its really annoying because I have not been able to render my scene successfully.

sounds more like you disallow them to get a lightmap.

for example “everything has 2 uv sets” might be totally antioptimal as their present uv2 might prevent them from receiving an appropriate lightmap area or any non-white at all. especially if you built the models to be combineable in the editor for example, having UV2 present is a horrible idea as it will definitely not work out for lightmapping, the whole story is different if you built the whole level in the modeller, generated the uv2 there for this setup and now replicate this in unity. in this case double check your beast settings

The second uv set we are talking about is Lighmap uv set? I just want to clarify this. Right now I have my diffuse uv set, and I was telling unity to make a second uv set for lighting. It would be extremely helpful if there was any documentation to troubleshoot this issues as so fat this forum is my only source of help. Could you explain to me how to verify this issue? I have checking this forum and I have encountered a lot of people with the exact same problem I am having.

If you turn on “Show Resolution” in the Lightmap Display what size are the texels (the checker pattern)? My guess is you have the resolution set to something way too high.

I am having the same problem. If I click the “Bake” button, which is supposed to bake all “static” marked objects, one or two of those objects will NOT get lightmaps. However, if I marquee select all the geometry in the scene and click “Bake Selected” those same objects WILL be lightmapped.

Is it possible that Unity is not sending Beast the right list of objects to bake when we click the “Bake” all button?

[EDIT] I may have to back off on this. Sometimes “Bake Selected” also has problems. It seems almost random.

Unity has confirmed that its a bug that hopefully will be fixed on the next release :slight_smile:

The work around is to select your lightmaps and make sure they are all marked as lightmap under inspector. I found a lot of them were marked as “texture.”
Your lightmaps is under project you probably you have a folder with all of your lightmaps, and when you select them, (make sure you are under inspector) You will see that there is a tab called Texture Type, make sure that all of your lightmaps are set to “Lightmap.”

That is what I did and it has worked for me, let me know if you find a different workaround. :slight_smile: