Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Erosion Brush Settings to Generate Decent Erosion

Discussion in 'World Building' started by Dave3of5, Jan 11, 2021.

  1. Dave3of5

    Dave3of5

    Joined:
    Jan 20, 2015
    Posts:
    32
    Hi all,

    I'm using unity 2020.1f1 and the terrain tools 3.0.2-preview3 and when I try to use the erosion brush with any settings I get terrible results. If you look at this blog post:

    https://blogs.unity3d.com/2019/05/2...rain-tools-siggraph-session&utm_content=video

    The erosion looks like it came straight out of world machine but mine looks like this:

    https://imgur.com/ltQv1bc

    I have a large brush size and the default erosion settings click and move the brush around a bit but the erosion chops off the top of the shape and that's about it. Terrain resolution is 2049 500x500m in size. Do I need a much larger size or what ?

    Anyone know how they actually created that terrain? It would be handy to have a demo of this tool to see how you can actually produce terrains with it. Like what settings would you use in the erosion tool to get it to actually work and do you just create a large brush and apply to the whole terrain or a small brush and go over.

    David
     
  2. Dave3of5

    Dave3of5

    Joined:
    Jan 20, 2015
    Posts:
    32
    I can get something that looks slightly similar but the terrain height is reduced a lot. Did they achieve this affect using the tools or using worldmachine?
     
  3. B_Campbell

    B_Campbell

    Unity Technologies

    Joined:
    May 21, 2019
    Posts:
    10
    Hello Dave3of5,

    The results you're witnessing are usually the outcome of a low-resolution heightmap. My recommendations are to change your terrain settings by changing

    1) Draw Instanced: On
    2) Pixel Error: 1 (This will allow us to accurately see how we're altering the heightmap, keep in mind lower # means higher rendering overhead)
    3) Heightmap Resolution: 2049x2049

    Just from altering those settings, you should see a drastic difference when eroding your terrain with the default parameters. If you're seeing a performance hit I recommend tweaking the Simulation Scale. Erosion is GPU base, so different GPUs will result in different erosions. The example you see in the blog was created using a high-end GPU, which allows for a higher Simulation Scale. Lowering the simulation scale will increase the performance of your erosion at the cost of fidelity.

    From here you can begin tweaking the erosion settings to get your desired results. I recommend starting with Sediment transport parameters.
     
  4. Dave3of5

    Dave3of5

    Joined:
    Jan 20, 2015
    Posts:
    32
    Firstly thank you so much for the reply ! Been pulling my hair out with the the last few days.

    This was at 2049 terrain resolution I mentioned that in the main statement, but for clarity here are my settings:

    https://imgur.com/a/u3CUzz0

    Pixel Error is set to 1 and Draw distanced is on:

    https://imgur.com/a/rA1YwuR

    With a high Simulation Scale I still don't get those nice erosion lines I get a horrible pitted looking landscape like this:

    https://imgur.com/a/jCq0hT3

    Changing the Sediment Transport values just melts the terrain faster or slower.

    In terms of GFX cards I'm using a GTX 1070 and the performance is fine and only slows down when I turn the iterations up to max.

    How are you suppose to apply this erosion? Over all the terrain with a large brush or specifically sculpted with a small bursh. Should the brush strength be high or low ? If I sculpt I can get something similar:

    https://imgur.com/a/uUfii4t

    But this looks quite different from the screenshot. It's too uniform almost as if the water is cut straight down rather than sloping down the terrain if that makes sense. In terms of erosion the screenshot looks a lot like the type of erosion you get out of world machine. If you look at this blogpost you'll see what I mean in this screenshot the second one at the bottom the channelled erosion. Did the author maybe use a brush mask as well ?

    I've tried dozen of settings so far with the erosion and I can't get anything like what is in the blog post from unity. Maybe whomever managed to get that result could do so in a video or something ?

    Again thanks for taking the time to reply !
     
  5. B_Campbell

    B_Campbell

    Unity Technologies

    Joined:
    May 21, 2019
    Posts:
    10

    No problem Dave3of5!

    Ahh, so the reason why you're most likely seeing a different result is that you've changed the Detail Resolution to 2049 and not the Heightmap Resolution. Changing detail resolution increases the number of cells that you can place Details on, which won't affect altering the Terrain with sculpting brushes. What I'd recommend increasing is the Heightmap Resolution which allows the Erosion brush to run its algorithm against a higher detail Heightmap, which will lend to better erosion results.

    There are two ways you can change the setting, one way is inside the Terrain Toolbox within the "Texture Resolutions" section
    upload_2021-1-15_6-53-38.png

    Or inside the Terrain's settings also within the "Texture Resolutions" section
    upload_2021-1-15_6-54-32.png

    The method of applying the erosion depends on the desired results. If you want to focus on a specific area then a smaller brush size is best. A larger area larger brush size. The greater the strength the stronger the erosion. If I'm eroding a mountain I usually start with a large brush and high strength to get the desired base shape. Then switch over to a small brush and lower strength to go over details. It's all preference though.

    If the Heightmap Resolution doesn't fix your problem let me know and we can keep looking for a solution :)
     
    wyattt_ likes this.
  6. Dave3of5

    Dave3of5

    Joined:
    Jan 20, 2015
    Posts:
    32
    Hi,

    Increasing the resolution slowed the whole thing down and gave higher fidelity results but the results still look not that great. The water still seems to be eating into the terrain at an almost vertical angle. To be honest, and I'm sure you're the same, I've just about had enough of all this. It's not working well for me so I'll just give up.

    I've got a few open source erosion tools that do a better job so if I need erosion I will just use those. I'm not sure about an erosion brush as it is anyway I think a better method would be to apply erosion over the whole terrain with a button click.

    Thanks for taking the time to help me.

    David
     
  7. Querke

    Querke

    Joined:
    Feb 21, 2013
    Posts:
    54
    I've had my issues with the erosion brush as well. Can you share the open source erosion tools that you speak of?
     
  8. Dave3of5

    Dave3of5

    Joined:
    Jan 20, 2015
    Posts:
    32
    The one I'm specifically talking about is here:

    https://github.com/SebLague/Hydraulic-Erosion

    By Sebastian Lague who's youtube channel is here:

    https://www.youtube.com/channel/UCmtyQOKKmrMVaKuRXz02jbQ

    This is a particle type of hydraulic erosion rather than a grid base cellular automata but you can see the results yourself with that github link.

    There is also:

    https://github.com/bshishov/UnityTerrainErosionGPU

    and

    https://github.com/Scrawk/Interactive-Erosion

    The last one there is slightly different from pure hydraulic erosion.
     
  9. mdaarishkhan_ls

    mdaarishkhan_ls

    Joined:
    Jan 11, 2016
    Posts:
    4
     
  10. mdaarishkhan_ls

    mdaarishkhan_ls

    Joined:
    Jan 11, 2016
    Posts:
    4
    hi dave , i am fairly new to world building ,so i recently starting working on a terrain for a personal project ,since i am a noob with respect to terrain ,i have gone through various resources on internet for making nice terrain , i came across your post on this thread when i was also looking for the same answers ,unfortunately i couldn't find any answers so i decided to play with the settings myself and see what happens , now i am glad to tell you that i have a answer for you if you are still looking .so here it is what i found ,i ll attach a ss of the settings but i would like to tell you this here the secret lies in a few things collectively like the time interval dt especially you can always play with simulation scale and iterations apart from that i tweaked the riverbank deposit rate to a high value to preserve the shape of peak better and i used a basic built in brush 2 with 30 percent strength to sculpt the details also while sculpting i made slow strokes from the peak towards the base of mountains have a look at the results
     

    Attached Files:

  11. Heislitz

    Heislitz

    Joined:
    Feb 23, 2018
    Posts:
    1
    What I really cannot understand is why can´t you save your settings as custom presets for your erosion simulations and other special brushes. I mean, really? Am I the first one thinking this is essential?
    Every time adjusting everything by hand, every time again? This is so thoughtless. When creating terrain, you usually might want to play around with different settings along the way, but adjusting a ton of sliders for every little change you do, again and again, is simply time-consuming and annoying. Also, I hate that I can't recall some great working setting afterward... Please get this feature added, I cannot see why this is not already there in the first place.
     
    TapCrush likes this.