Author Topic: Noisy results using the Mountain erosion  (Read 4115 times)

Danilo Nishimura

  • Sr. Member
  • ****
  • Posts: 66
  • Senior Technical Artist at Massive Entertainment
Hello there,

First of all, I'd like to say I'm impressed by the speed Instant Terra is able to generate such results. Great technical achievement there! Congrats!


Now, regarding the Mountain erosion, I've noticed that it generates some very weird noisy results when processing large sets of terrains. I'm pretty sure you guys already noticed it, but for the sake of clarity, I'll post the information here.


I created a test graph, with a UK heightmap as input sample, and applied the Mountain erosion using different terrain sizes.
Heightmap: https://casual-effects.com/g3d/G3D10/build/data/heightfield/united-kingdom-2048.png

The import node is set with a 2048x2048 8bit map, 4.0 Quad Size, with height set to a min of 0 and max of 200, not flipping the Y axis.


Then I created test cases.

The Mountain erosion uses the following setup:
Iterations: 250
Strenght: 0.50
Wrinkling: 0.40
Smoothness: 2.00


1st - Applied the terrain erosion in the raw input. All good.
See "result1.png"

2nd - Increased the resolution to 4x (8192), keeping the quad size (4.0), then applied the same erosion. Noisy peaks appeared.
See "result2.png"

3rd - Increased the quad value (16.0), keeping the terrain size, then applied the same erosion. Huge noise appeared.
4th - Increased both, resolution (to 8192) and quad values (to 4.0), then applied the same erosion. Also, huge noise peaks.
See "result3.png", as both results were similar

5th - Increased the resolution to 8X (16384), and reduced the quad size to 1.0, then applied the same erosion. Noticeable performance loss; No noise peaks appeared; Somehow the color map came out different than expected, as if there were values sunk down below the ocean floor... looked up, couldn't find any negative peak.
See "result5.png"


« Last Edit: April 24, 2019, 04:38:24 PM by dnishimura »

Jean-David Génevaux

  • New Member
  • *
  • Posts: 1
Hello,

Every simulation node can create graphical artifacts due to numerical instabilities. Here, the problem is mainly the presence of too strong high frequencies when you import the heightmap (i.e. too steep cliffs). The import node is configured to create a 2048 x 4m = 8192m with the elevation between 0 and 200m => that gives us a ratio of 8192 / 200 = 40 If we compare to the real size we get on Earth (i just measured it on Google Maps really quickly) :1 200 000m / 1 300m = 923. So the difference in ratio is quite big.



I've constructed the same example with a different import. 2048 x 6m = 12 288m with elevations between 0 and 13m. That gives us a ratio of 945 (so the same scaling as the real world data). By computing the erosion on it with different cellsize (and upscale/downscale of the resolution of the terrain), the erosion will create smaller or larger crevices (the details created match the cellsize). Of course, the erosion may drastically
erode the terrain (thus creating a too flat area for you), so you can always boost / reproject the elevation into your desired range afterwards.



You can find all those terrains inside the attached .terrain file.

Hello there,

First of all, I'd like to say I'm impressed by the speed Instant Terra is able to generate such results. Great technical achievement there! Congrats!


Now, regarding the Mountain erosion, I've noted that it generates some very weird noisy results when processing large sets of terrains. I'm pretty sure you guys already noticed it, but for the sake of clarity, I'll post the information here.


I created a test graph, with a UK heightmap as input sample, and applied the Mountain erosion using different terrain sizes.
Heightmap: https://casual-effects.com/g3d/G3D10/build/data/heightfield/united-kingdom-2048.png

The import node is set with a 2048x2048 8bit map, 4.0 Quad Size, with height set to a min of 0 and max of 200, not flipping the Y axis.


Then I created test cases.

The Mountain erosion uses the following setup:
Iterations: 250
Strenght: 0.50
Wrinkling: 0.40
Smoothness: 2.00


1st - Applied the terrain erosion in the raw input. All good.
See "result1.png"

2nd - Increased the resolution to 4x (8192), keeping the quad size (4.0), then applied the same erosion. Noisy peaks appeared.
See "result2.png"

3rd - Increased the quad value (16.0), keeping the terrain size, then applied the same erosion. Huge noise appeared.
4th - Increased both, resolution (to 8192) and quad values (to 4.0), then applied the same erosion. Also, huge noise peaks.
See "result3.png", as both results were similar

5th - Increased the resolution to 8X (16384), and reduced the quad size to 1.0, then applied the same erosion. Noticeable performance loss; No noise peaks appeared; Somehow the color map came out different than expected, as if there were values sunk down below the ocean floor... looked up, couldn't find any negative peak.
See "result5.png"

Danilo Nishimura

  • Sr. Member
  • ****
  • Posts: 66
  • Senior Technical Artist at Massive Entertainment
Thanks for the explanation! It really helped me to understand how to get the best out of simulation nodes.
Just one thing, maybe, this info should be in the documentation, regarding how scaling (or inputting the correct height information) affects the simulation nodes. I mean, in a way, it's obvious, but when I see those noisy peaks, its not clear what generated the wrong result. What do you guys think about it?

Marianne Calva

  • Administrator
  • *****
  • Posts: 63
Yes you're right. We'll add the information, it will be helpful.  Thanks for the suggestion.