Yellow areas on Normal map = black areas in render
I have some models that I pulled from a game. Each model comes with a texture map, specular map and normal map. Typically they look great once I import them into DAZstudio, but I have noticed that on some of the normal maps the yellow colored areas cause the rendered result to have black edges and kill transparency. I don't know much about normal maps, and I am hoping someone can give me some advice on how to fix the issue. Attached are a few shots of the object along with the normal map. I read something about 'World space' and 'Tangent space', but after looking around online for a few minutes, my head feels like it wants to explode.
Image 1 = Texture+Specular map
Image 2 = add Normal map
Image 3 = Normal map. Notice the yellow areas in the lower right hand side and upper left.
Comments
Hi
I made that comment about yellow being 'world space'.
...but looking at this example, It may the alpha map as you mention.
What does the alpha map look like?
Hrm, that's a good point. Unfortunately the software I use to pull the models/maps doesn't have any information on a transparency map. Maybe I can get a hold of the developer.
You could also take the normal map into an editor and make the yellow into black, and the rest white. (or it might be the other way round)
I suspect that would work as an alpha.
Yellow, I'd hazard to guess, is reversed normal: the map is colored based on an XYZ axis system, and if I'm right, the usual bluish color is Z-positive (depth outward from the surface), red being X-positive and green being Y-positive. In that case, yellow (as the RGB opposite of blue) becomes Z-negative and turns normals inward.
The "pull normal map into an editor and make an alpha map" thing worked well enough, but I don't feel like going through all the work for, I don't know, maybe a few hundred items. I'll likely just make all the objects into a library and let whoever wants to use them fuss with it. Thanks for the heads up, though.
If you pulled them from a game you can't share them. It's quite possible that you shouldn't be using them at all, other than in the game, but check the publisher's EULA and its stance on fan art.
Maybe it's an Nvidia thing? I imported the object into the DAZstudio beta and everything rendered fine (no black spots) with the exception of, yes, there is an alpha map, but the program developer doesn't pull that map from the game file. I'll have to see if I can get him to include it. In the meantime, yeah, I probably shouldn't share anything with anyone, but I will use them in my own renders.
Within the game, the alpha was probably derived procedurally from the diffuse.
In theory you could make an equivalent shader in the shader mixer and then just swap the appropriate diffuse in as required.
Um, you do know that you already posted the alpha channel, yes? The normal map from the post above contains an alpha channel which looks more like number of discrete values than a continuous alpha value; that is sometimes done in games to save texture space. A pixel shader could convert that into something useful. For use in a renderer you should split that into separate color and alpha channels.
I suspect the image for the normal map you've posted got mangled but the forum posting mechanisms here... but if not, that normal map is borked badly and has the alpha applied as transparency in the png i'm seeing. (or it could just be the way Chrome is handling it for me? png is a funny format when it comes to opacity) millighost seems to be showing an intact version of what you posted.
Your fix (should) be to just remove the alpha channel and re-save. The webbified version of the map I'm looking at in Photoshop is beyond help.
According to the software developer, the render engine of the game ignores any part of the normal map where the blue value is less than (255 * 0.5), so half the scale for the blue value. If you look at the complete normal map, the yellow portions are what is causing the problem. I don't know how to make Studio treat the normal map the same way, and I am completely unskilled in using the Shader builder in an attempt to do so (if that's even the way to go). Thanks, everyone, for the helpful info!
Does anyone know of any good resources for learning about the Shader Builder in Studio 4.8.0.9? I am bound and determined to get these textures working correctly if I can, but I know absolutely zero about how this Shader Builder works (or even if this is the resource I need to use to get things working).
Here is the quick story: I have some models I pulled from a game I am messing with. They have three image maps (texture, specular and normal). The shader in-game sets any blue color value less than 128 in the normal map to transparent (appears as a yellow color on the normal map). I don't want to pull alpha channels from the normal maps or create any new types of files, I would like to see if I can build some kind of math in a shader to perform the same function. If you can point me in any direction I would appreciate it. Thanks.
In case anyone wants to view the other thread with some other details:
Other Thread
Duplicate threads merged.