PDA

View Full Version : The normal problems ...



Thomas M.
09-17-2006, 05:05 PM
... like adding two normal maps. One is a tangent space normal map on a UV map, the other is a bump map turned into a normal map (Normal,subtract, normalize). Each on its own works fine, but I can't find a way to add them without loosing the strength of each of them. Scale vector doesn't work like expected and just produces some kind of high contrast rendering. Is there a special trick to it, so that each of them remains its strength? Like adding two bump map?

Cheers
Thomas

Anttij77
09-17-2006, 08:18 PM
if you scale a normal, you need to normalize it.
so the steps to add a bump to a normal would be to add them togehter with an vector add, and finally using the normalize node.

Thomas M.
09-18-2006, 01:11 AM
Well, that's what I did: But as soon as you use normalize, the crispness and the amount of each map seems to fade. Scaling before normalize doesn't work in a way, as it somehow gets undone by normalize. Scaling after normalize corruptes the normals, as the patterns disappear and the model looks somehow like "high contrast". So the actual object will look completely weired. Is this just depended on how vectors get added and scaled. I can manage to add bump maps, so that each layer is clearly visible and doesn't get hidden behind the other, but with vectors I fail.

Cheers
Thomas

Weepul
09-18-2006, 01:54 AM
I don't have any tangent space mapped objects so I can't test this, but I believe it should work.

You have to convert the normal map's output to be independent of the surface normals...bump-ify it, the opposite of what you'd do to convert bump into normals.

Because of this, you could use it as either bump, or re-normalify it afterward. I've connected both to show where in the tree each comes about - 1 being normal and 2 being bump. Ordinarily you'd only use one.

When adding the bump to the normals, you could use add, or add scaled, or whichever operation you wish to mix them.

Thomas M.
09-18-2006, 10:37 AM
Wup-di-du, Mr. Weepul!