Author Topic: How to create height map from terrain mesh?  (Read 4167 times)

How can I bake / create a Height Map from an imported high poly terrain mesh?  I want to be ablew to export a 32bit EXR height map for displacement.

What are the exact steps?

I found this earlier thread, but it doesn’t explain how to achieve this.

https://forum.substance3d.com/index.php/topic,34823.msg131050/highlight,height+from+mesh.html#msg131050


Use Designer for this and not Painter. In Designer under Bakers you can generate a height map from a mesh.
I teach people how to use Substance Painter. :)

Thank you!  And after reading the linked post again I see Designer is what was recommended.  I overlooked that.

I am interested in this as well but your explanation was very brief. Can you go into detail of the exact steps? I don't know how to import a 3d model into designer to then convert to a height map.

I am interested in this as well but your explanation was very brief. Can you go into detail of the exact steps? I don't know how to import a 3d model into designer to then convert to a height map.

If you want to do it in Designer you just need to load in your low poly by dragging and dropping the file under your Graph in the Explorer tab. Then add your high poly which is the sculpted terrain or how ever it was made, then add the baker Height Map from Mesh, adjust your front and rear distance as needed, then bake. Once you have this map you can take a look and see how it looks in Designer directly or any where else.







I teach people how to use Substance Painter. :)

Wow, that is great. Thanks for doing that.

I am having some problems with your tutorial. I am trying to bake a pyramid texture to make an array of metal spikes texture  that I saw on a traditional Japanese teapot. The problem is my height map is more like static than a slope of a pyramid. Also, I don't see a graph node option. It isn't even an option by pressing space bar and searching. I drug the height map into the work area and it came as a bitmap. I don't know if that matters. At the end of the day I have a high res plane and it has zero distortion to it. I have had bugs happen to me in the past that somehow worked themselves out as I continued but the height map is there. It just doesn't do anything.



I am trying to upload two pictures but the second one will not upload so this is what I've got.

Can you share your sbs file and include the low and high which you baked your height map from?
I teach people how to use Substance Painter. :)

I actually didn't save it because what I made was useless but I can try and recreate what I made. I can describe it. I made a pyramid in 3ds max, fbx'ed it, drug it into designer in the top left tree window under graph, right clicked it and went to bake as texture, past that I think I started messing up with the high and low maps. I am only after a height map so I don't know if I even need a low map. I don't fully understand the difference except for maybe use with level of detail at different distances from the camera in game engines. But I think that part is where I need help from. If you want me to try and reproduce what I did I can.
Last Edit: December 09, 2020, 03:05:25 am

In the example I provided you'll see I have the base which is a plane, and from that base I created the terrain example.

Not sure if you've used zBrush before for displacement but the same concept applies. You're taking your desired subdivision version of the mesh and your highest and generating a map that will bring your low to your high.

http://wiki.polycount.com/wiki/Displacement_map

If you wanted to do what you're doing with the pyramid you just load in the base which in my example is now a plane, then I have a pyramid from it.





Once you create your height map in Designer you go from this to this:



I teach people how to use Substance Painter. :)

Thanks so much for bearing with me. I had to re-read the description a lot but I think I understand now. I would post a screenshot but they have stopped uploading for the past few days. But my height map looks just like yours.



Ok, finally the upload worked. This is the result of the texture BUT I could not figure out how to get a preview of the texture in Designer. I tried high and low poly planes and nothing updated. I tried setting tessellation and scale as well.

If you can share your .sbs file and the two meshes along with your height map I can look at it.
I teach people how to use Substance Painter. :)

Here you go.


It works fine on my end, but you need to turn off bounding box and bump up your ray distance to capture the high poly version because of the difference in distance.

Then load in your plane into the 3D view and apply a good amount of scale and it will work. I also plugged the height into the normal and increased the strength of the normal map to give the edges.



I teach people how to use Substance Painter. :)