- Home /
Normal map seams with Blender
I'm trying to generate a normal map for a low-poly sphere from a hi-poly version in Blender. I'm able to bake a normal map in tangent space, save out the image and the low-poly model, but when I bring it all together in Unity it has nasty seams on the edges of each polygon. From what I can tell, this is being caused by some bleed over between polygons due to the UV coordinates being positioned along the anti-aliased seams in the normal map. See the screenshot below: I've been trying to look for solutions online and I keep seeing mention of "Smoothing Groups", but no good explanations of how to do this in Blender, aside from some vague mention of using an Edge Split modifier.
Could you show the normal map texture and vertex normals? Perhaps you have exploded the UV mapping and the you have UV seams everywhere or maybe your normal map is baked at 8bit per colour channel ins$$anonymous$$d of 16bit. If it is the last try to bake a 16bit normal map and either down-sample it yourself to 8 bit or let Unity do it.
The sphere model you present there actually does not need any normal map at all. You could simply select all faces and press CTRL+F and select "Shade Smooth" to average all the vertex normals making a overall smooth surface.
Answer by RobDiazMarino · Feb 08, 2017 at 09:28 AM
Alright, after some painstaking trial and error I think I finally have this figured out. Now I'm not sure if this is the "best" or "easiest" way to do this so further suggestions are still welcome.
What I did was add a second set of UV coordinates to the sphere (using the data menu) and then I used edge split with all faces selected to break up the UV coordinates into individual polygons. Then I used vertex > remove doubles to rejoin the faces in the model - but this left the UVs split. In the UV editor I then selected all the faces and set the pivot to "individual origins" and scaled them down slightly in both X and Y directions - effectively separating all of the polygons so none were touching one another. I re-baked my normal map using this UV set, ensuring that a margin was present in the bake settings (16px). I saved out the new model (to .fbx as usual) and the new normal map.
In Unity, I imported the new model, then set up its material. I used the Standard shader which has support for secondary maps. Here I used my normal map as the secondary normal map, and used UV1 as the UV set. The reason I did the separated triangles as UV1 instead of UV0 is that I wanted to put an additional normal map onto it to give it the appearance of cracks, which required a UV map where the polygons were touching.
This is the result - a smoothly shaded sphere with an additional layer of detail:
Answer by Kin0min · Feb 06, 2017 at 03:18 AM
Could be a problem with how the model is exported/imported, try exporting it as a .obj, then importing that into unity, if not that, then an .fbx.
The edge split modifier would give you hard edges, which is not what you want for a sphere.
Smoothing groups are usually something used in 3DS Max, in blender it's the difference between ticking "smooth" or "flat in the toolbox panel to the left of the viewport.
Answer by TCROC · Feb 19, 2017 at 11:05 PM
There is a much simpler solution (at least one that seems to be working for me). All you have to do is uncheck "Calculate from grayscale" on the normal map. The normal map has already been calculated within Blender hence there is no need to recalculate it from grayscale.
Answer by FariAnderson · Feb 13, 2021 at 10:13 PM
this is an old post but i think i got the easiest way to solve this problem
i realized what to do after i read this awesome article accidentally at:
Generating Perfect Normal Maps for Unity (and Other Programs)
now What to do:
simply, just before baking Normal Maps, make sure the low poly object have smooth normals :
now you'll get a smooth Normal Map without those lines at UV Edges after baking. here you can see the difference:
as a little Advantage, it doesn't really matter now what fbx settings you use in Unity, both Import and Calculate will work for Normals and Tangents.
P.S. for not getting headaches trying to get Normal Maps (or any other textures) right, it's better to use xNormals, "it's a free App to bake texture maps"
Your answer
Follow this Question
Related Questions
3D Bacteria Game Environment 0 Answers
Object doesn't export correctly from Blender to Unity 2 Answers
Blender to Unity question. 2 Answers