UnigineScript
The Language
Core Library
Engine Library
Node-Related Classes
GUI-Related Classes
Plugins Library
High-Level Systems
Samples
C++ API
API Reference
Integration Samples
Usage Examples
C++ Plugins
Content Creation
Materials
Unigine Material Library
Tutorials

Terrain Editor

The built-in terrain editor allows to change the terrain relief on the spot with the help of brushes. In the editing mode you can draw various terrain features, such as rocky ground and other craggy details, and cut holes. All brushes modify only the Patch levels of detail (0-3 LODs).

To start editing the current terrain, click the Edit terrain button on the Terrain tab. After finishing the editing, click either Apply to apply all changes and exit the editor, or Cancel changes.

Requirements

  • To modify the diffuse color, a surface should have a diffuse texture assigned.
  • To modify the detail mask, a surface should have a mask texture assigned.
  • If there are already 4 detail materials present on the surface, new materials cannot be added.

Controls

  • To draw with a brush, press ALT + LMB.
  • To grab the height / color / material (depending on the brush type) at the current locus of terrain and set it as a brush value, use CTRL + LMB.
  • To change the brush size, use [ and ] hotkeys or the mouse wheel.

Terrain Brushes

The following set of brushes with their specific modes is used to modify the terrain.

Heights

Heights brush adds hills and cavities of different sizes. The available Modes for Heights brush are the following:

  • Normal — makes the locus to be of the height specified by the brush Value. After the height at a current locus is grabbed, decreased brush value will lower the surface down and create cavities, while increased one will raise the locus and model hills. If a surface has different heights, the brush will level them.
  • Addition — adds the specified height to the locus and raises it till the upper height bound of terrain is reached. The brush value specifies the speed of raising.
  • Subtraction — subtracts the specified height from terrain locus and lowers it till the lower height bound of terrain is reached. The brush value specifies the speed of lowering.
  • Smooth — levels the difference between the neighbouring heights.
  • Dilate — raises the terrain locus up to the level of its highest point (regardless of the brush value).
  • Erode — lowers the terrain locus down to the level of its lowest point (regardless of the brush value).

Notice
After using a Heights brush do not forget to regenerate a normal map so that new relief features would be correctly lit.

Holes

Holes brush cuts the holes in terrain grid (Add hole value) or restores the non-cut terrain relief (Remove hole value).

Holes can be seen only on Patch levels (0-3 LODs).

Diffuse

Warning
To modify the diffuse color, a surface should have a diffuse texture assigned.

Diffuse brush modifies the color of diffuse texture that is assigned to the surface. Its Modes are:

  • Normal — paints the color specified by brush Value over the diffuse one.
  • Addition — adds the color to diffuse one thus lightening it. The lighter the color, the lighter the result will be. Completely black color value does not change anything.
  • Subtraction — subtracts the color from diffuse one thus darkening it. The lighter the color, the darker the result will be. Completely black color value does not change anything.
  • Smooth — blurs diffuse colors blending and softening color transitions.
  • Multiply — multiplies the diffuse color by a value color. The result is darker than both colors. Completely white color value does not change the diffuse texture at all; completely black color value gives a black result.

Notice
After using a Diffuse brush do not forget to regenerate a coarse diffuse texture (Update coarse diffuse option) so that introduced color changes would be seen on all levels of detail.

Mask

Warning
To modify the mask, a surface should have a mask texture assigned.

Mask brush controls the clarity and spreading of detail materials across the terrain. The Value allows to choose a material from the list of available ones for the current terrain. The brush Modes are:

  • Normal — applies the chosen material to the terrain locus and erases all other detail materials present there (clears values of all other channels of the mask texture).
  • Addition — increases intensity and clarity of the chosen detail material.
  • Subtraction — decreases intensity and clarity of the chosen detail material.
  • Smooth — blurs spreading boundaries of the chosen material.

Detail materials are seen only on Patch levels (0-3 LODs).

Diffuse + Mask

Warning
To modify the diffuse color and detail mask, a surface should have both diffuse and mask textures assigned.

Diffuse + Mask brush simultaneously modifies the spreading of material texture across the terrain and overpaints its diffuse colors. The brush Modes are:

  • Normal — overpaints the diffuse color with the Value color and applies the chosen material to the terrain locus. It also erases all other detail materials present there (clears values of all other channels of the mask texture).
  • Addition — adds the color to diffuse one (thus lightening it) and at the same time increases intensity of detail material. The lighter the brush color, the darker the result will be. Completely black color value does not change anything.
  • Subtraction — subtracts the color from diffuse one (thus darkening it) and decreases intensity of detail material.
  • Smooth — blurs both diffuse colors and mask texture, making the spreading boundaries of the material softer.

Notice
After using a Diffuse + Mask brush do not forget to regenerate a coarse diffuse texture (Update coarse diffuse option) so that introduced color changes would be seen on all levels of detail.

Other Parameters

  • Shape — shape of the brush:
    • Circle — circular shape
    • Square — a square oriented along the terrain grid
    • Diamond — a square oriented at 45° to the terrain grid
    • Custom — texture-based brush. (The texture is loaded using the additional Texture button.)
  • Radius — size of the brush
  • Power — tip of the brush. The lower the value, the sharper and smaller the tip; the higher the value, the flatter and bigger the tip.
  • Opacity — the rate to apply the brush
  • Value — value of the brush that depends on the brush type

Brush Palette

The terrain palette allows to save all the current brush parameters to be used as pre-set later. For that, drag a Save icon onto the palette. The palette is shared by all terrain objects (except for materials).

Last update: 2017-07-03