Convert normal map to height map?

Hi do you have an idea to efficiently convert a normal map to a height map?
The interest would be to use the height map to create other maps such as roughness from volume information by playing with colorramp or photoshop.
I know that we can create this kind of map from photo texture but what I would like is to be able to make my details in sculpture then bake the normal and have for example a shine only on the excavated parts without having to paint by hand.
I saw that awesomebump allowed to do this kind of thing but it’s not very good, it creates big imperfections in the locations of the seams

1 Like

That’s not really how a normal map works. A normal map is housing normal angle information, not depth. There are a few apps out there that allow you to convert maps online and some you can download. I usually find the effect to be gimmicky at best but my standards (at least the ones I hold myself at) are usually pretty high so take that opinion with a grain of salt. Basically the way they work is by taking the normal information and then allowing you to define the height threshold manually but in all actuality the problem typically lies that, an angle can only appear to look a certain height based on its adjacent length. With a normal map, it can in some ways defy the laws of physics when it comes to height which is why most accurate maps are typically a combination of height and normal.

Long story short, I think for your application, you might find it easier than you think just to make the maps yourself from scratch and go from height to normal, which is totally doable with a great deal of accuracy as opposed to the other way around. What you want can be done, but even for stylized work the quality and fine tune control typically just really isn’t there in 9/10 cases. The first app that comes to mind is Substance Designer which has a node for this but as much as I love substance and basically live in it, even substance doesn’t “nail it” per se.

Thank you for your answer.
I know that this is not the goal of the normal map but I imagine that an algorithm is able to convert its angle diferences in aproximative height as does awesomebump. I don’t need much precision, just something clean.

You mean I should do without creating shape details with the sculpture and do everything by painting grayscale? to engrave text or ornamental patterns I agree but the sculpture is much more intuitive and precise to create organic shapes or for example the fabrics folds. The screen that I show is only an example to test, I intend to use this method in many other kinds of shapes.

These maps are typically created by starting with a hand painted height map OR a generated brush that they create from a photo, drawing, scan, or even create procedurally. Like I said, if you aren’t expecting exact precision, the only tool I would recommend is substance designer. I am sure there is a free one out there too but given that most struggle to create an accurate DX normal map, much less OGL normal map that is “flawless,” I don’t know how confident I am with their algorithms to turn one back into a height map. Substance is probably your best bet. If you have just a few you do not have substance and are not in a rush I can convert a small few for you if you already have them ready to go and want to private message me. Some will work great, some will work terrible. The ones that will work the best are the ones that do not have multiple layers of flat heights, because a normal map does not have height and cant tell the difference between flat 0 and flat +0.573x.

Sorry I didn’t see that you recommended substance designer in your 1st message, you must have edited it after I read it :thinking:.
Thank you for your proposal to transform me some maps but I’m looking for a workflow solution valid over time.
I will try to get substance designer.
As it will be the first time that I use this software, If you have explanations to give me to do what I am looking for or a tutorial (I have not found) I am verry interested

Substance is great. It is a worthwhile investment and you can also get a month to month license to all the software for like $20 a month I think? thats what I use. That way if I go through a period where I might not need it I can cancel it temporarily. I would be happy to answer any questions you ever have about it. It is pretty straight forward for the most part just takes some getting used to using the space key instead of shift+a. My other tips are just pay attention to which nodes are in grayscale and which are in color mode. It will save you a lot of headaches instead of backtracking looking for a problem 10+ nodes back. And lastly… pls pls pls pls PLLLLSSSS make sure your normals are in OGL mode. Most PBR engines only take OGL normals. If you do not go to the normal node and set it to OGL then cycles will be confused and your maps will look inverted. Just gotta check that and make sure it’s all rigged up as intended for blender and youll be all set.

1 Like

Hello, you can also try this open source tool, it is free, powerful and easy to use:

http://www.boundingboxsoftware.com/materialize/index.php

I second this actually. I like it but it’s worth noting that (at least when I last installed it) it’s windows only and can be a pain to get the map to translate in any fluid way but given that it’s free, it’s a huge plus. In this case paying for substance of this were your ONLY need for substance, you would mostly be paying for ease of use and instantaneity of visualization which can be very important in making lots of small fine tuned changes but if you aren’t ready for the price tag on substance yet, this is not a bad choice, for as good as a normal to height conversion can possibly be.

Thank you, I knew this software but I didn’t know that it made this kind of conversion.

I just tested with substance designer and I still have the same problem. but I just understood that it’s the bake of my normal that is the source of these issues. At the place of the seams cut there are variations in the colors from one side to the other, strangely It does not seem to pose any problem by using it as bump but it seems logical that it disturbs the algorithm which converts the normal in height.
I just tried with a simpler unvrap and I’m already getting better results.
I think I would never manage to have something clean with this kind of software but I can use it as a base and make touch-ups in painting.
I managed to get this kind of result to have domed parts less shiny and metallic than the hollows

1 Like