How do I get rid of seams that are showing up with lightmapping?

So, I’m using Unity 5 and when I put my lights into my scene with my modular enviroment pieces assembled into several buildings I get these seams between wall pieces that are not there then the lighting is not on. Is there a way I can fix this?

Try combining meshes. This will force Beast to have the same lightmap across the surfaces where possible.

Also, try increasing your lightmap resolution. The result should roughly be smoother gradients across similar adjacent surfaces.

For combining meshes, there’s a Unity utility script that you can import called CombineMeshes. If it’s not in Unity 5, you can probably Google to find it.

@mdagreda I have been seeing this in the map I am working on as well. I have a modular set of walls I got from the asset store. One of the things I noticed when trying to fix this problem is that some of my meshes ended up getting strange rotation properties from Unity (359.99 instead of 360, or 0.0001 instead of 0) When I went through and corrected these rotation abnormalities it fixed some of the seams. There are still a few seams that are there and I am trying to figure those ones out.

If you send mesh objects with different positions to the graphics card, unity’s precision is not high enough and the actual vertex positions in the graphics cards, the seams, will not be the same. hence you will see seams inside the graphics card. the further you go from origin, the bigger the rounding error will be.

If you put all your cubes on 0,0,0 and instead change their vertex positions to the positions you want, and send them all to the graphics card, they will not contain seams. they will have identical object position and seam position rounding errors sent to the graphics card.

AFAIK i solved the issue after some time and puzzling, perhaps waster 50 hours to solve it, becaues i was told that my problem was inside the game engine not the graphics card.

So… keep all cubes on zero zero zero, edit their vertex positions, rewrite all the vertices to the new positions you want the cubes to be in, otherwise the seam positions in the graphics card differ microscopically.

Its a weird error inside Unity that no one else than me knows about because i am a lame coder who never managed to code a game but i am basically a genious:) iT WOULD HAVE HELPED ME TO FINISH A GAME IF UNITY TOLD US ABOUT THIS ERROR IN THE FORUMS!!! NOT ME HAVING TO DETECTIVE IT!!!

Try to use a light gray color as a background color in your texture when making it in PS or GIMP it helped me to get rid of seams.