Announcements
Due to scheduled maintenance, the Autodesk Community will be inaccessible from 10:00PM PDT on Oct 16th for approximately 1 hour. We appreciate your patience during this time.
Community
Maya Shading, Lighting and Rendering
Welcome to Autodesk’s Maya Forums. Share your knowledge, ask questions, and explore popular Maya materials topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Ugly artifacts from Transfer Maps: Normal when using normal map texture on hipoly source

16 REPLIES 16
Reply
Message 1 of 17
adamgravois
707 Views, 16 Replies

Ugly artifacts from Transfer Maps: Normal when using normal map texture on hipoly source

Hi y'all. I'm using Transfer Maps to project normals from hipoly to lowpoly. Works great, nicer result than Simplygon! BUT: 

I get terrible results when the source hipoly geo uses a normal map. Ugly, ugly artifacts, black pits along UV seams, plus this: 

illustration of nasty artifacts on lowpoly (top)illustration of nasty artifacts on lowpoly (top)

Here's what I have diagnosed:

The hipoly normal map is a clean PNG with no noise (examined VERY closely)

hipoly geo is using a standard lambert shader with bump2D set to tangent space. 

Color space management is correct (Raw in both hipoly and lopoly source)

There are no UV seams near the artifacts, Vertex normals are clean, vertices are all welded.

There's no inner layer close by, to confuse the envelope.

Tried with map sampling set to Gaussian, None, and MipMap, same results.

 

Rendering with a flat blue texture map does NOT produce the error:

Using an utterly flat blue PNG file as the hipoly source normal map does not have this problemUsing an utterly flat blue PNG file as the hipoly source normal map does not have this problem

 

Here's my Transfer Maps settings, for reference...

Transfer Maps settings, no surprisesTransfer Maps settings, no surprises

 

Am I missing something? This really seems like a render bug. But I'd be delighted if you pointed out something I missed! 

thanks!

Tags (2)
16 REPLIES 16
Message 2 of 17
syracoj
in reply to: adamgravois

can you zip then upload that scene file plz?

Message 3 of 17
adamgravois
in reply to: syracoj

Sure... here's a stripped-down scene file that exhibits the behavior. 

https://www.dropbox.com/s/e4oqha2scaqura7/TransferMaps-errorScene.mb.zip?dl=0

Appreciate you taking a look! 

 

Also, did a little more digging. Unsurprisingly, similar error appears in the Maya Software renderer (remember Maya Software Renderer???) 

Maya Software renderer with and without normal map textureMaya Software renderer with and without normal map texture

vray render of samevray render of same

low poly normal bake resultlow poly normal bake result

Message 4 of 17
adamgravois
in reply to: adamgravois

Oh now this is interesting! Further testing shows that the Transfer Maps-Normal does something weird with even the parts that aren't obviously corrupted. Look at how the intentional normal maps behave on these matcap shaders:

adamgravois_0-1664506181165.png

Look at how the #4 looks doubled up... Like it was differenced over itself? 

Similarly, look how the carbon fiber weave has additional lines in it:

adamgravois_1-1664506374091.png

 

So, something weird is definitely happening. You should be able to replicate this with the file posted above. 

 

 

Message 5 of 17
syracoj
in reply to: adamgravois

are you trying to use a multiple objects as the source geo? Also, many of the source geo parts are not water tight. There is a good chance that the transfer maps will not like this.

Could you provide exact reproduction steps on how you are going about transfering maps please?

Message 6 of 17
adamgravois
in reply to: syracoj

thanks for the reply. Yes, using multiple meshes as the source geo. They all have different materials. I'll see if merging them into a single mesh prior to transfer makes a difference. 

 

The parts are not water-tight, no, mostly because they're derived from CAD at high tessellation with fully-internal faces removed. (Also some need to be separated to accommodate VRay's dislike of multiple materials per mesh.)

 

If water-tightness is the issue, why does it transfer cleanly when there is no texture, or a flat-color texture? I suppose it's worth a test to see. 

 

Exact steps?  nothing fancy...  Maya 2022.3, sample file attached above

open Transfer Maps tool

add lowpoly obj ('lp_4i_LOD1') to Target Meshes

add hipoly geo (everything in 'hp_sourceGroup') to Source Meshes

enable Output Normal Map, tangent space (other settings in screen shot above, but it doesn't seem to matter)

"Bake" ...

 

This also occurs when baking via Python script, and similar artifacts can be seen in a Maya Software render (above)

 

On the plus side: I did figure out a workaround:

-bake clean normal map with just geometry, no normal map textures on source,
-bake source normal map textures as color textures, 

-then combine results with an overlay function.

Works ok, as long as the source UVs have the same alignment as the normal map source texture!

 

 

 

 

 

Message 7 of 17
adamgravois
in reply to: adamgravois

(also the file I uploaded is intentionally missing parts... the actual hipoly mesh is complete, full-surface, if not technically "water tight")

Message 8 of 17
syracoj
in reply to: adamgravois

as we continue to look into this more did you see what the Turtle plugin has to offer? I believe there is texture baking within Turtle. Never used it myself but I was told that it may be an alternative option.

Message 9 of 17
adamgravois
in reply to: syracoj

I have not looked into Turtle, no. I'll give it a try.

Message 10 of 17
adamgravois
in reply to: syracoj

Reporting back on your suggestions, @syracoj :

  • merge source meshes into single mesh: does not fix issue
  • use watertight source (I used the original CAD tessellation, so 100% closed volumes, including internal surfaces): did not fix issue
  • Turtle renderer: does fix issue, has some drawbacks, acceptable solution. 
    • drawback 1: works best with Turtle-specific bump node, requires tool changes
    • drawback 2: litters every Maya scene file now and forever with "Turtle" nodes, causing error messages and grief much like an old mental ray node. Ah well! 

Thanks for looking into it. Cheers!

Message 11 of 17
syracoj
in reply to: adamgravois

I want to continue to look into this issue further. Can I have the original water tight/non-cut-up mesh to test with please?

Message 12 of 17
adamgravois
in reply to: syracoj

yeah, will send you Dropbox link via DM
Message 13 of 17
adamgravois
in reply to: adamgravois

OK, I'm back. Turtle is a finicky, finicky beast. This is not currently an acceptable solution. I cannot get it to behave predictably (got it work a few times!) and there is very little documentation/discussion.

 

I don't suppose you've had luck solving the Maya Transfer Maps issue? 

 

Since it's a topic all its own, I've started a thread about "HOW DO YOU GET TURTLE TO BAKE NORMALS PREDICTABLY"

 

 

 

 

 

Message 14 of 17
syracoj
in reply to: adamgravois


I did a test where I generated a good looking normal map onto a lowrez1 object. The map was transfered from a high rez model with nice modeled in surface detail. 

I then took that lowrez1 object and assured it's generated normal map was set to Raw and Filtering off. I then used that as my source mesh for a lowrez2 object (no surface detail, and base lambert shader) and transferred with "Include Materials" on lowrez1's normal map info to the lowrez2 object and the results were not good. It worked but it didn't work well. Neither the VP or the Arnold Render of it looked good. I however did not have any surface artifacts as you have showcased earlier in your attached images.

We will have to investigate further to see if the poor results have always been like this or if the tool has regressed somewhere along the way. In the meantime, if you have a workaround you could use that or you could just stick with only transferring high rez modeled in detail to a low rez target.

A shot in the dark, but I see in your photo at the very top that showcases your Transfer Map settings under Maya Common Output > Sampling Quality is at the lowest. Any improvements when you increase this?

Message 15 of 17
adamgravois
in reply to: adamgravois

thank you for continuing to look into this, @syracoj!, I really do appreciate it. 😊

To answer your question, no, increasing sampling quality does not solve the problem. 

 

But I believe I have solved (most of) the problem and... oh man, it's always something ridiculous. 

😤😓🤔😵😟😭

 

Even though UV channel map1 is not used: the normal map is using another UV channel, and no textures use map1...

the fact that map1 has some garbage UVs (because CAD) is enough to cause this artifacting. Applying any kind of proper UV mapping to those faces will fix the problem. 

adamgravois_0-1666933941345.png

adamgravois_1-1666934137262.png

Yeah! I'm still not satisfied with the embossed 4, but AT LEAST THE GEOMETRY ISNT HAUNTED ANYMORE! 😁😍😆

 

Try it yourself... if you take the watertight example I sent you, and assign, whatever, automatic UVs on map1, it will render correctly. It will also perform a transfer maps operation cleanly, which is huge. HUGE!

 

(The transfer maps result also has the overcooked normal map detail... I tried reducing the intensity on the bump node, tried filtering with box or none on the texture and the transfer map settings... tried changing the normal map to sRGB... maybe this is just how Maya Software manhandles normal maps?? 🤔

 

Message 16 of 17
syracoj
in reply to: adamgravois

that's an interesting bug we'll have to look into. But glad that you have a means to get past the issue.

Message 17 of 17
adamgravois
in reply to: adamgravois

Confirmed: Maya Software Renderer/bump2d node (and, by extension, Transfer Maps) does not render normal maps correctly. Maya 2022.4

All renders with 'carbon fiber' normal map: Some interesting ramps, and some detail scratches.  

adamgravois_2-1667076890926.png

set to Raw color space. Blinn shader.

 

VRay: looks pretty good

adamgravois_0-1667076764948.png

 

Maya Software: WHAT IS THAT RAKED PLASTER HORROR? 

adamgravois_1-1667076855431.png

Bump2d node, set to Tangent Space normals, Bump Depth 1.0.  Tried with "alpha is luminance" on and off. Incidentally, the bump2d node ONLY accepts alpha as input, not color. Not sure how it thinks it's gonna do a normal map that way.

 

Turtle with Maya bump2d node: also bad

adamgravois_3-1667077090243.png

 

Turtle with ilrNormalMap node: looks great! 

adamgravois_4-1667077125576.png

 

sigh.... 

 

 

 

 

 

 

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report