Landscape Displacement Using Virtual Height Mesh In Unreal Engine 5

Sdílet
Vložit
  • čas přidán 7. 07. 2024
  • You can support my channel at www.patreon.com/user?u=75006076
    Learn how to achieve landscape texture displacement in Unreal Engine 5 using Virtual Height Mesh.
    0:00 - Intro
    4:38 - Painting The Landscape
    7:07 - Adding Displacement
    8:58 - Setting Up The Heightfield
    18:33 - Taking A Closer Look
    20:17 - LOD Settings

Komentáře • 94

  • @buildgameswithjon7641
    @buildgameswithjon7641  Před 2 lety +1

    Check out the new version of this video! czcams.com/video/H4jzMsiBkYg/video.html

  • @ExploreSweden
    @ExploreSweden Před 2 lety +19

    All tutorials should be like this, straight to the point, explains why, when and how to do something without going too much in depth just for the sake of it, no "umm" "uuh". Well done!

  • @darklordstudios72
    @darklordstudios72 Před 2 lety +2

    Finally! A straight forward tutorial on this! Google couldn't find it but my CZcams algorithm finally did!

  • @eugenekabacka5643
    @eugenekabacka5643 Před 2 lety +11

    This is absolutely what I need right now. Many thanks to the author

  •  Před 2 lety +10

    For those go suffer the problem of not having a world displacement node anymore i have 2 solutions to you:
    A)The easy yet wrong (kinda) way: Just pin your displacement texture to the world position offset in your material attributes and on the break attributes before the multiply node just add a component mask with only the (B), blue channel, so you convert a vector3 (world position offset vector) into a scalar, and it works.
    B) the complex one: you get all your base material nodes into a function and create a material attribute that connects to the result node, and also add an extra output node in that function in which you will connect your displacement texture, then drag that base material function into your landscape/mesh blend material and just use a break material attribute to connect everything but the displace and use the displace output of the function to get your displace connect as show in the video instead of the world displacement pin you are lacking. (dont forget to make sure you set your displacement output node in the function as scalar, otherwise it will give you an error, as world height is a scalar)

    • @nikolasherold
      @nikolasherold Před 2 lety +1

      so I did option a, which kind of works but the vhfm is above the landscape. The larger the displacement value, the higher it goes, if you can help me I'd appreciate it

  • @2coolcello2011
    @2coolcello2011 Před 2 lety +2

    You are my saviour, I was unable to get my heightfield mesh working and stopped working on my game for a few months

  • @peterallely5417
    @peterallely5417 Před 2 lety +3

    Thanks dude! Keep making these technical vids!

  • @harshitpenamata2682
    @harshitpenamata2682 Před 2 lety +1

    Absolutely amazing !!!!!

  • @LupusMechanicus
    @LupusMechanicus Před 2 lety +1

    Subbed for sure thanks man!

  • @smelllikegreeny
    @smelllikegreeny Před 2 lety +2

    that is a great help, thank you!

  • @brianmo2611
    @brianmo2611 Před 2 lety

    awesome video!

  • @dombarbuto2404
    @dombarbuto2404 Před 2 lety

    Great video

  • @esk6a
    @esk6a Před 2 lety

    very helpful! thanks a lot!

  • @cr3ap3r1
    @cr3ap3r1 Před 2 lety

    Thanks for this. I could not figure out how to get textures on the landscape to the VHM. I did not realize you have to create a separate material for the VHM and sample the RVT within it. I kept trying to use the same material.

  • @dylanmelotti4301
    @dylanmelotti4301 Před 2 lety

    Great video, straight to the point. 10/10.
    Could you possibly do a video on setting up Landscape materials? I have downloaded and imported materials from the integrated Quixel Bridge, however, when in the node editor, it looks very different from what you have @0:40.

  • @Simon-iq1yl
    @Simon-iq1yl Před 2 lety +8

    VHFs I found pretty useless when looking at them 6 months ago because of the lack of collisions and negative displacements. But I should have a look at the latest UE5 source build to see if progress here. Personally I'm hoping the landscape heightmap and layerInfos get replaced with streamable VTs - so higher resolution sculpting and painting will be possible at Edit time.

  • @Dexxter_slav
    @Dexxter_slav Před 2 lety +2

    Very valuable information, thank you! This can be also used for brick/stone grounds for example indoor scene right?

  • @oloriun
    @oloriun Před 2 lety +5

    Hey Jon, did you get to try this in UE5 pub release? I can't figure out quite how to do it since the material attributes have changed.

  • @AndrewByrnes1
    @AndrewByrnes1 Před 2 lety +3

    10/10 explanation.
    I just have one question. What about for snow that you want to displace during play like they used to do with render targets and WPO? This technique isn't dynamic during play mode I assume?

  • @Max_Stupa
    @Max_Stupa Před 2 lety

    Hey Jon, thanks for the explanation!
    I have a question, is it possible to make holes in Virtual Height Mesh like in regular terrain?

  • @ThreeTreeDog
    @ThreeTreeDog Před 2 lety +1

    Does this work using landscape layer coordinates? I have a basic setup Layer Coordinates>texture samples>makematAtrib>blendmatatrib>landscapelayerblend material set to use material attributes. initially it works on the base layer, try to paint it goes to worldgrid color. I build save all nothing works. Also, im controlling my blend alphas using a single tex coord and noise texture dotted and with cheap contrast. Edit ok thats solved, shared wrap on textures lol. The problem I have now is the VHM isnt working in PIE when I press play, it is turned on and working in editor. Standalone works. Now how to make it lower where my character isnt up to the knee in the terrain in spots...

  • @marcin2008
    @marcin2008 Před 2 lety

    Hi, would you mind sharing where did you get the puddles material from ? Great tutorial btw. thanks !

  • @Baleur
    @Baleur Před rokem +1

    If you use Nanite for the landscape itself, do you then not need this? Can you then just use the world position offset?

  • @021shaw
    @021shaw Před 2 lety +1

    unfortunately it didnt work for me, got a bunch of artifacts and no displacement. im using a houdini landscape through HDA and maybe this technique dont work with imported heightfields. thats sad because i really hoped to get my displacements with this great tutorial!!

  • @prototypega8257
    @prototypega8257 Před rokem

    Hey could this method be used on Skeletal Meshes wich used Displkacement Maps ?

  • @edwardkeefner3540
    @edwardkeefner3540 Před 2 lety

    Is there a way to somehow run the height information from the terrain into the characters feet?

  • @nikiniki6861
    @nikiniki6861 Před 2 lety +1

    Hi! thx for the tutorial. Just want to know is there a way to displace textures along normals using virtual height mesh. For example if I have rocks on hills i want them to displace along normal and not straight up causing stretch effect.

    • @cosmotect
      @cosmotect Před 2 lety

      Have you tried multiplying by vertex normal?

  • @May-yn1zx
    @May-yn1zx Před 2 lety +1

    After struggling for half a day to implement a virtual height field mesh with terrain materials in UE5, I finally came across this video... Strangely enough, I couldn't find any practical information in the official documentation, but I'm still a beginner, so I must have missed something. Thank you so much for making this video, Jon.
    By the way, I can't press the "Build" button in the detail panel of the VirtualHeightfieldMesh, like you did around 13:10 in this video; I set up a Virtual Texture, but that button doesn't seem to be active. Does anyone else have the same problem?

    • @May-yn1zx
      @May-yn1zx Před 2 lety +1

      Ok it was me overlooking the explanation at 9:35! The part about changing the type of Virtual Texture Content to World Height has slipped from my brain. Now I can build a MinMax Texture.

    • @michaelcarville7072
      @michaelcarville7072 Před 2 lety

      @@May-yn1zx Im stuck at that point too :( When i Open the RVT World Height the menu is empty , plugins / settings are all enabled.

    • @JoseGomez-hg6qv
      @JoseGomez-hg6qv Před 2 lety

      @@michaelcarville7072 you must enable , view details panel
      its must be in edit tools or windows panel , on top

  • @nocnestudio7845
    @nocnestudio7845 Před 2 lety +1

    Do you have any idea how to make collision with Heightfield mesh????

  • @neeo9949
    @neeo9949 Před 2 lety

    Hi, I followed it on the simple landscape material and everything works fine with VHFM, but it doesn't work on my other material, both materials use roughly the same way of working, the only difference is just some Blende node, so am I doing something wrong? been stuck for days now.
    I can send you my material blueprint if possible, just want to know what's going on, I'd really appreciate it!

  • @nocnestudio7845
    @nocnestudio7845 Před 2 lety

    beautyfull. I use WOP and looks great but when camera is far there are artefacts...

  • @ethanwasme4307
    @ethanwasme4307 Před rokem

    Don't forget to transform your normals from tangent to vertex space using the provided nodes

  • @tgreis
    @tgreis Před rokem

    My makematerial attributes don't have displacement either? Do I need to download or enable plugins?

  • @bedirhanctak5658
    @bedirhanctak5658 Před rokem +1

    Hello! I need your help with my project in Unreal Engine 5. As a last resort, I'm reaching out to you here. While working on the landscape part of my project, I managed to apply displacement using the "Virtual Heightfield Mesh" method. However, I'm struggling to apply an opacity mask to the same terrain. I would greatly appreciate your assistance.

  • @lordew9476
    @lordew9476 Před 4 měsíci

    oh god just returnt my tesselation!

  • @importon
    @importon Před 2 lety

    could this be used for an effect that can dynamically update in realtime? for example terrain deformation from an explosion? or chipping away at a concrete wall by shooting it?

    • @XEPHOROfficial
      @XEPHOROfficial Před rokem

      Late, but the short answer is no, as the heightmap is generated in build time, not at runtime. If the deformation of terrain was managed at runtime, then it'd be possible, but I think we're a long way from that using VHT's. It's not impossible to do (relatively easy), just not with VHT's.

  • @jakopwills
    @jakopwills Před 2 lety +1

    Thanks for the video but I have a question.
    How can I change the collisions after using this method? Some part of landscape get high or deep and collisions doesn't match. Is there a way to do

    • @cr3ap3r1
      @cr3ap3r1 Před 2 lety +1

      He stated in the video that collisions come from the original landscape and do not work for the VHM at this time, thus collisions do not match.

  • @FPChris
    @FPChris Před 4 měsíci

    When I use displacement on a landscape I get rippled seams along the tile edges :/ You can see the sky dome through the seams under the ground.

  • @Animeke-san
    @Animeke-san Před 9 měsíci

    This is no longer needed, thank God.

  • @gualmasoothes8238
    @gualmasoothes8238 Před 2 lety

    Is there any guide to blueprint like this?

  • @NP-Adrian
    @NP-Adrian Před 2 lety +5

    Nice job Jon, great video !
    One question : how you get the displacement texture into the landscape material ?
    I followed the tutorial and the RVT is not working :( . I guess I'm doing something wrong.

    • @buildgameswithjon7641
      @buildgameswithjon7641  Před 2 lety

      In my example I am piping the displacement textures from the landscape materials into the World Position Offset pin and then when I break the material attributes later on I take the World Position Offset pin and pipe it into the virtual texture. Hopefully that helps!

    • @NP-Adrian
      @NP-Adrian Před 2 lety

      @@buildgameswithjon7641 I understand that, I'm trying to figure out how you got the displacement file into the UE5, with bridge or you import it manually?
      Can you upload the landscape material so i can take a better look? , it will really help me understand exactly what i'm missing.

    • @buildgameswithjon7641
      @buildgameswithjon7641  Před 2 lety +1

      @@NP-Adrian Ok I understand your question now. So I didn't use Bridge or anything, I just downloaded the .ZIP files for the textures right from the Quixel website. I unzipped the files on my desktop and then drag them from the desktop (off camera) into the content browser. The displacement maps are included in those .ZIP files as .EXR or .JPG files (or both).

    • @NP-Adrian
      @NP-Adrian Před 2 lety

      ​@@buildgameswithjon7641 I understand now, well I did something similar, I already had the material upload through bridge and I imported just the displacement file into UE5 . I think I used the JPG file. Is there any difference between EXR and JPG ?
      I don't know why it didn't work.
      I will try your way and import all the files manually . maybe something will change.
      Thank you again for the support and for doing this video, I was struggling to find tutorials for RVT UE5 for a while.

    • @buildgameswithjon7641
      @buildgameswithjon7641  Před 2 lety +1

      @@NP-Adrian The .EXR file is a 16-bit lossless (I believe) file format, so a bit more fidelity than the .JPG but either one should work just fine.

  • @lungamaluleka42
    @lungamaluleka42 Před 2 lety

    My build MinMax Texture button is greyed out, what do I do ??

  • @borisstengele5389
    @borisstengele5389 Před rokem

  • @Belarus9000
    @Belarus9000 Před 8 měsíci

    What version UE? In 5,3 i dont have world displasemenet

  • @lenstobrush7266
    @lenstobrush7266 Před 11 měsíci

    Great video, very clear and precise however why has Epic made quite a simple procedure so complex. This is so long winded and tedious for an effect that every landscape requires.

  • @buildgameswithjon7641
    @buildgameswithjon7641  Před 2 lety +13

    NOTE: There is no longer a world displacement pin on the material node. YOU CAN STILL use this method in the video, simply move from the world displacement pin, and borrow the specular pin instead.

    • @HansLollo
      @HansLollo Před 2 lety +3

      I am not quite sure what you mean there. When I try to use the Specular pin instead of the now missing World displacement pin, I get an error.

    • @CutThroatG
      @CutThroatG Před 2 lety +2

      doesnt work

    • @PaPaJOKe
      @PaPaJOKe Před 2 lety +1

      @@HansLollo Yeah, I tried using the specular pin as well and it didn't work for me. Maybe we're misunderstanding, but I'm not finding info anywhere other than using OpenLand. I don't much want to spend 30 dollars for a function that was in the engine less than 3 months ago.

    • @nikolasherold
      @nikolasherold Před 2 lety +1

      doesn't work, is there any other way?

    • @Rhen5656
      @Rhen5656 Před 2 lety +1

      can you elaborate? this doesnt work for me.

  • @donaldblattner3474
    @donaldblattner3474 Před 2 lety

    Where can I find any documentation?

  • @BlackAngel-gg5tw
    @BlackAngel-gg5tw Před 2 lety

    Not working in EU 5 in noudzie makematerialAttributes not on World Displacement connection.

  • @hayriocak749
    @hayriocak749 Před 2 lety

    Is it suitable for 4

  • @MrHayli
    @MrHayli Před 2 lety

    can u do this in nanite?

  • @chromativerse
    @chromativerse Před rokem

    Hi, so I followed along multiple times now and each time my VirtualHeightfieldMesh has turned out extremely blurry (both texture and height). Do you (or anyone else) have any idea why?

  • @peter486
    @peter486 Před rokem

    less bumb + grass will remove the avbilty to see clipping :)

  • @Мирный_атом
    @Мирный_атом Před 2 lety +4

    Good evening. The lesson is good and I want to say thank you. But there is a misunderstanding. At 03:58, the MakeMaterialAttributes node has the WorldDisplacement input. Where did you find this in your node, I do not understand, because I do not have this input. I have Unreal Engine 5 Preview 2 installed and it's not there. Please tell me how can I create material then?!

    • @BleederFoE
      @BleederFoE Před 2 lety +1

      Sadly, that option is not there is Preview 2. It has been removed.

    • @Мирный_атом
      @Мирный_атом Před 2 lety

      @@BleederFoE And then what to do? Is there any way to get around this problem?

    • @BleederFoE
      @BleederFoE Před 2 lety +1

      @@Мирный_атом i haven't figured it out yet. VHT is ok, but not as good as tessellation/displacement was.

    • @Мирный_атом
      @Мирный_атом Před 2 lety

      @@BleederFoE Thanks a lot. Let's find a way to solve the problem

  • @ott113
    @ott113 Před 2 lety +2

    how can you turn on worlddisplacement? please i can't find it..

    • @fityfive
      @fityfive Před 2 lety

      me neither...

    • @gursimransingh8726
      @gursimransingh8726 Před 2 lety

      @@fityfive no need to do worlddisplacement just hook the world height setup combined with the height texture directly to the world height in rvt sample thats it

  • @matheuskrum4009
    @matheuskrum4009 Před 2 lety +1

    For me, World Displacement does not appear in MakeMaterial

    • @GilGuminski
      @GilGuminski Před 2 lety

      Yes it was updated with Unreal 5 preview 1. I'm trying to figure out a way to make it work with the latest Unreal...
      Edit : You can simply link WorldHeight & World Position Offset (donc forget to only keep up values, so a mask where you keep the blue channel will be needed). It works like a charm.
      I only have a shadow bug on the virtual height field mesh to solve...

    • @fityfive
      @fityfive Před 2 lety

      @@GilGuminski can you explain in more detail? when i connect wpo to world height i get error x3017 saying cannot connect vector to scalar

    • @GilGuminski
      @GilGuminski Před 2 lety

      @@fityfive world height output a vector 3, you need to keep only one vector (the up one) to connect it

  • @K1N3RGY
    @K1N3RGY Před 2 lety +1

    **NOTE** If you're using UE5 full release and want the displacement effect then use this instead: czcams.com/video/cf_RgBEF6bA/video.html
    A lot of time wasted setting this up when there is a better version available which the creator should direct you to if you're using UE5 anyway.
    Followed your guide all the way through, using UE5 (latest version) unfortunately my landscape is still as flat as a pancake. Changing the displacement value and still no result. This is using the method below about using specular as world displacement is no longer available.

    • @Andrew-mi7bt
      @Andrew-mi7bt Před 2 lety

      I just watched the link video you posted. And is great but do you know if I can use it on landscape mode or is only for apply on specific meshes ??

    • @K1N3RGY
      @K1N3RGY Před 2 lety

      @@Andrew-mi7bt specific static meshes at the moment. Seems UE is going towards this way

  • @peter486
    @peter486 Před rokem

    hey what is your name? anyways thank you. intreseting video.

  • @audunaarseth6237
    @audunaarseth6237 Před 2 lety +2

    Good tutorial but what a tedious process. Tes was so much more straight forward to use.

  • @lonewolf_studio
    @lonewolf_studio Před 2 lety

    I don’t understand the tutorial makes sense but it doesn’t work with me. Although I followed you step by step.

  • @jkarafilms
    @jkarafilms Před rokem +1

    2023 and we still don't have an easy way for the ordinary tasks such as landscape texture mapping/blending (facepalm epic games)

  • @korcanatalay
    @korcanatalay Před 2 lety

    coming from a traditional 3d software... why is a displacement taking 20 minutes to apply? That's not practical. I know ue gives many upsides but the ones it takes from you are a bit weird.

    • @LilYet
      @LilYet Před 2 lety

      it blew my mind how complicated it is just for displacement now