What's the best way for convert to mesh ?

Hi, very good course !

For create a mesh, i make a heightmap (cam ortho from top, in TGA) with the Displacement node to Surface and last Multiply to 1 value, Finaly i add a Displace Modifier with the TGA to the plane.

It's works, but it's the best way to get the mesh ?

Shader vs Mesh

  • Kent Trammell replied

    I'm impressed by your resourcefulness to achieve what you have! However I'm pretty sure the procedural displacement isn't limited to the pure normal direction like the displacement modifier is. If you take a look at the desert plane that starts perfectly flat, the procedural displacement pushes the geometry in a diagonal direction which makes for a "sharper detailed" version:


    Therefore I don't believe there's a way to make a 100% accurate conversion from procedural displacement to geometry. Definitely a bummer. Something I hope the add soon.

  • Ian Johnson(matirixaran) replied

    Playing around with this, I think I've found a closer aproximation at least, however it does produce some artifacts I can't quite resolve: 


    Credit goes to Kent, as you mentioned that you were mixing colors into the vector data which made me think hard about that setting in the Displace node and how you could copy out that data. I took the node tree from the shader and rather than plug it all into displacement, I fed it into an emission node, and then baked it out (I did a simply U > unwrap on the mesh first). Saved as a 32bit float .exr and fed it into the displace nod. Using RGB to XYZ as the direction seems to give the best results, but something about how I'm baking or saving out the image is introducing those artifacts. If I manage to get more time to play around with it later today. One limitation of this is that you lose the ability to have adaptive subdivision with this method.

  • aimerqua replied

    Thank you Kent, I know my method is imperfect.

    Ian, I have to try this, it's great !

  • Kent Trammell replied

    mmatirixaran This looks brilliant! I'm going to have to test this.

  • Kent Trammell replied

    mmatirixaran I tested and it works beautifully. You've discovered a fantastic method! Would you mind if I made it into a short tutorial/tip video about it? I would, of course, credit you for the discovery.

  • Ian Johnson(matirixaran) replied

    By all means Kent, have at it! If anything, you're the one who gave me the idea when I thought back to you mentioning that vectors could be thought of as color data. Just glad that it worked out. I'm a bit curious if you had any artifacts and if so how you dealt with them? I went back and ended up clamping the RGB values before they got to the emit node. The results were clean and the two outputs looked more or less identical but I couldn't be sure. In any case, glad I could contribute to this!

  • Kent Trammell replied

    mmatirixaran I didn't notice any artifacts. From what I can tell it's a near perfect conversion. I think a lot of people will be happy to see it's possible. Look for a video to drop on youtube sooner than later. Thanks for sharing your discovery!

  • Ian Johnson(matirixaran) replied

    Must have been something with that particular bake as I've not managed to reproduce them either. In any case, glad it's worked out!

  • Kent Trammell replied

    mmatirixaran Here's the video. Your technique has come full circle! 🤘