Gaia contains two very common mask types that you will need almost in every project:
- The Height Mask, which allows you to select your terrain according to the underlying height of the terrain ("how high or low the terrain is")
- The Slope Mask, which allows you to select your terrain according to the steepness of the surface
Both these masks utilize a curve with minimum and maximum values to make your selection:
Below the curve you can find a range selection slider for minimum and maximum values for your mask, followed by text entry fields which allow you to enter precise numerical values directly. The height mask displays additional information as well:
* The red line on the slider represents the position of the sea level in your world. This allows you to adjust your selection according to the sea level quickly, e.g. only select parts that are above the sea level.
* The numbers next to the min max number entry fields represent the height of the lowest and the highest part of the world. The range of the slider represents is mapped to the height range as well.
Please Note: If you select minimum and maximum values that don't fit in the slider range anymore, the slider will be deactivated for technical reasons. To use the slider again, enter values in the min max number entry fields that fit between the min max world range.
The interesting part is: How do you need to set these values when wanting to spawn (or stamp) at a certain height / slope level only? Both these masks work by modeling a strength transition between a minimum and maximum value. This does not automatically mean the masks will only select within the range of the min max values - this can absolutely be done, but it depends on how the curve for the transition is set up.
This might sound confusing at first, but should become clearer with the following examples. This scene shows a gray terrain consisting only of a slope going from a height of 0 to 1000, with the sea level (blue plane) set at 500:
Now let's apply our first height mask to the terrain. A simple linear increase in strength from 0 to 1000:
This should be as expected - as the height of the terrain increases, so does the strength selection of the mask until full strength at the top.
Where it gets more interesting is when we limit the range of the same transition beginning at 200 and ending at 600:
The strength begins increasing under the sea level as expected, but then exceeds beyond our maximum of 600 - and this is where a common misconception of how the strength curve works lies: The minimum and maximum values are not necessarily the minimum and maximum points of our selection, but they are the minimum and maximum points of the transition. The strength curve is "open ended": If the strength value is at full strength at the end of the transition, this value will be kept for any value higher than the transition maximum as well.
If you want your selection to only include heights between the minimum and maximum value selected in the mask, you would need to cut off the strength at the end of the curve again. Here is the same mask with a different curve, jumping directly to 100% strength, then cutting off to 0% at the end again:
Note how the selection changed to a strict "square" now on the terrain.
Transporting this idea over to real world terrains this means by setting your minimum and maximum values for your transition & adjusting the curve, you can do any height selection you could possibly think of:
Selecting a a smooth "strip" of beach along the sea level:
Stopping an underwater texture from going over sea level:
Increasing strength at certain "steps":
The same principle of the "open ended" curve and "modeling a transition" applies the same way to the slope mask. Here are some slope mask examples:
Selecting everything with a slope higher than 3 degrees:
A strict selection of all angles between 10 and 60 degrees:
Flat areas between 0 and 5 degrees only: