Author Topic: Normal Map Baking Artifacts - new to painter  (Read 11907 times)

Hello,
 
I'm new to Substance Painter and have an issue I cannot resolve...
 
I am attempting to bake out some texture maps with Substance Painter and am running into an issue with the normal map baking out weird artifacts and I'm not sure why. If anyone could shed some light onto what I am doing wrong I would love to hear from you.
 
There are 2 main issues here a weird seam like artifact where there is no seam and something that looks like a extended triangle artifact.
 
Please take a look at the files I have provided and tell me why this is happening and how to fix the issues.

Project files can be got here...
https://www.dropbox.com/sh/4cstd7lezkh6mw2/AAAf1kGABJXlL-yKfHT9bU3Va?dl=0

Thank you for your time and effort

I have downloaded the files, I don't see the artifacts that are visible on the screenshot in the Painter file, and I don't get the artifacts when I bake the maps myself using the OBJs.

You might have switched from OpenGL to DirectX accidentally after baking the maps. Go to Edit -> Project Configuration and switch the normal map format.

If thats not it, please describe exactly what you have, done step by step.
Last Edit: August 17, 2017, 10:37:09 pm

So it worked for you, then it must be something with painter itself? - I've got everything setup with default settings

I've tried changing from open gl to directx before baking but they both produce similar artifacts to each other.

So the process...
I start a new project> import the low poly mesh leave everything else at default
click on bake textures > add high poly mesh and then add the cage file and check the use cage box
I leave everything else at default and click bake default textures

and that's what gives me the weird results

@burning01 and Volker,

What version of Painter are you using?
Hobbyist
----------
Common "Help" suggestions:
- LOG FILE tips - https://forum.allegorithmic.com/index.php/topic,22451.0.html
- LICENSING issues https://www.allegorithmic.com/contact
- ATTACH files and pictures to posts: https://forum.allegorithmic.com/index.php/topic,23670.0.html

Substance Painter, version 2.6.1
Build 1589 - 76ba1b925e9f49149fd6e5bf218f6e0e48934910
Last Edit: August 17, 2017, 11:13:57 pm

I use version 2017.2, so there might be problems with older versions of Painter that I cannot reproduce at the moment.

   
Right so I updated to Substance Painter 2017.2
 
At first glance the problem seems to be resolved but on closer inspection the newer substance painter does a better job of hiding the problem but its still there.
 
I have added a new file to the drop link I posted at the top of the page. (for the 2017 version of painter)
 
When you first open up as you can see by the images below it looks fine. However with certain materials applied the artifacts start to show up again. ( for example on highly reflective surfaces but also noticeable on many other surface types too )
 
and when you solo the normal + height + base normal map you can clearly see the same problem exists.
 
So any thoughts on what is causing this- is it my topology? or something else?
As it is right now I can probably cope with the way it is for the most part, but I'd rather know what im doing wrong so I can fix this issue entirely.

Last Edit: August 18, 2017, 08:48:12 pm

You have broken smoothing groups (soft/hard edges) on your low-poly mesh in SP. Everything is soft. Hence the weird smoothing on top of the mesh that can be seen even without any maps/materials applied. Normal map you've been baking struggles to compensate for that, thus artifacts are present.

The mesh should look more like on the right side of the picture below. Try to re-export your meshes from your 3D app and check if Smoothing Groups export is enabled. Also, you can try to export in FBX format if OBJ won't do for some reason. And don't forget that for every hard edge in your LP mesh you should have a split in your UV's for normal map to be baked seamlessly. Most likely you would need to slightly alter your UV's for this mesh to account for that.

Good luck!  :)

I separated out the hard edges on the uv map and updated the smoothing groups as you suggested.

That was really helpful and greatly reduced the problem, although im still getting slight issues around the corners - I guess im not doing something quite right - what do you think?

I updated the files in the dropbox link located at the top of the page.

As you can see from the images below the problem is greatly reduced but not totally eradicated...

Now, your issue is that your low-poly mesh doesn't follow the shape of the high-poly mesh close enough. It's a very similar artifact (basically the same) that you would be getting baking a high-poly cylinder shape into a low-poly with not enough geometry. Check out this thread, it has some great insights on this: http://polycount.com/discussion/81154/understanding-averaged-normals-and-ray-projection-who-put-waviness-in-my-normal-map

Basically, to fix this, you should add some geometry to your low-poly where there are artifacts you're seeing in the normal map. Also, make sure that your low-poly wraps high-poly as close as possible - there are a few areas on top where that isn't the case, and you get some thin line-like artifacts on your normal map because of this.

And finally here's a quick mockup of what's going on with your bike. Blue is low-poly, red is high-poly. Blue line is the distance between the low-poly and the cage (a "push" for the cage or Frontal Distance if you don't use a cage in SP) and an approximation of a pixel for which a particular baking ray will be cast. The black line is a ray cast for a particular point on the side of your mesh (where you see the artifacts). As you can see, the ray cast from the side of the low-poly will hit the top side of the high-poly (black dot). Normals baked from such will produce visible artifact on you normal map because it will contain normals from the top of the mesh on the side of the mesh. Additional geometry should alleviate that.



Last Edit: August 20, 2017, 07:18:21 pm

updated the dropbox link at the top of the page.

So I've read everything you've posted and checked out poly count posts- still wrapping my head around it.

I have managed to improve the bake to smaller dots and thin lines by increasing geometry to closer resemble the high poly.

You say "make sure that your low-poly wraps high-poly as close as possible" - are you saying that the high poly must be entirely enveloped by the low poly mesh ? - you mentioned "a few areas on top where that isn't the case" - on the top of the model the HP & LP are intersecting (as you can see below with the textures fighting each other), which I believed was ok to be doing and from what I read on polycount that seemed to be what people were aiming for.

Now Im even more puzzled as to how I would properly envelope the high poly with the lowpoly, especially as I make the low poly first to the correct dimensions the asset needs to be- so I wouldn't want to change those dimensions by altering the  the low poly to fit the high poly. - unless I just shrink the HP - but that doesn't seem like a very elegant or precise solution?

by the way I really appreciate all your help :)


I've meant areas like on the first picture attached - it's really the same issue with missing projection rays that you've (mostly) fixed already. Unfortunately, on shapes like this, it's close to impossible to bake a normal map without any artifacts - at most, by moving around the geometry you can choose to have them either on top or on the side.  :D

That's why you should change the geometry to have a better bake. Consider adding a slight bevel on top of your low-poly shape (see the second picture attached for an example). Generally, you should avoid right angles (close to 90 degrees) on your shapes as much as possible, because it's pretty hard to bake them without artifacts. It's a good practice to slightly exaggerate such angles and make them a bit more round and smoother than they are on real objects - you will not only get a better normal map from it, but the object also will catch highlights on those edges better and keep visual integrity on larger distances.

That said, you have really sharp edges on top of your high-poly — it may be realistic, but will not play so well for the normal map. Try to make them much more round and smoother - you can follow the profile on the low-poly mesh with bevel you'll be adding to it.

Lastly, there are some redundant edges on the top side of the low-poly (see the third picture attached). They can affect baking in a negative way, so remove them (and check UV's after that).

With those three steps, you should get a much better normal map.
Last Edit: August 21, 2017, 06:54:56 pm

I was kind of thinking that how it is right now, I can probably get away with, especially once I texture properly, I guess I can just paint those dots out if its that important on a particular piece and like you say I can always hide the artifacts on the top side which will probably be removed anyway for this asset as it is unlikely needed.

I didn't want to put any extra geo on the low poly as wanted to keep it as low as possible as its for vr and have to keep the cpu processing low to stay at a constant 90fps, however I already tested adding a bevel to the low poly where you suggested strangely that gave me a worse result than I managed to get without the bevel. - (although im checking and I may have used the old HP for the bake, so will give that another go with the right one)

Yeah I found those extra polys hiding and removed them on the last bake I done(and also redone the uv's).

So anyway you really helped me minimize the baking artifacts especially with the smoothing groups, so a big thank you for your time and effort, it was really helpful and appreciated, great to have people like you who take the time to help others. So thanks :)
Last Edit: August 21, 2017, 08:23:38 pm

You're welcome and good luck!  ;)