High-level terrains can be rendered through one or more views, each having its own properties and settings.
The Terrain View GUI component display the settings of a terrain view and allows the user to modify some properties.
The Texturing fields display the current status of unique terrain texturing.
The first field shows the overall status:
Some more work needs to be done for unique texturing until the terrain is textured with the desired quality.
Unique texturing has finished, the terrain is textured with the desired quality (approximately).
The second field shows the relative progress, in percent. The progress will be 100% if and only if the displayed textual status is done.
The third field shows the current ratio between screen pixels and texture samples. Unique texturing strives to reach a ratio of approximately one, unless a mipmap offset is specified (see Terrain Layer List GUI component).
The Chunks slider controls the overall screen-space size that a terrain mesh sector is allowed to reach until terrain processing is stopped, which effectively defines the granularity of mesh traversal.
The Displacement slider can be used to scale displacement-mapping by a percentage between 0% and 300%. Displacement-mapping is disabled when set to 0%.
The Tessellation slider controls the threshold that drives dynamic subdivision on the GPU, in order to generate triangles for displacement-mapping. It is given as an error threshold in screen-space.
The first choice is used to select the GPU feature level. The terrain render effect implementation for a certain graphics context is not required to support all GPU feature levels. Feature levels are described using Direct3D nomenclature, but their meaning can easily be translated to OpenGL or Vulkan.
Used shaders: vertex, pixel
Texture arrays: no
Displacement mapping: none
GPU triangulation: none
Used shaders: vertex, geometry, pixel
Texture arrays: yes
Displacement mapping: triangle subdivision with geometry shader
GPU triangulation: no
Used shaders: vertex, hull, domain, pixel, compute
Texture arrays: yes
Displacement mapping: triangle subdivision with hull/domain shader
GPU triangulation: triangle list expansion with compute shader
Used shaders: amplification, mesh, pixel
Texture arrays: yes
Displacement mapping: triangle subdivision with mesh shader
GPU triangulation: triangle list expansion with amplification/mesh shader
The second choice selects the CPU triangulation mode. In all modes, the CPU generates indices (i.e. 32-bit integers) that describe the graphics primitives for rendering. The generated indices are uploaded to the GPU for each frame.
CPU triangulation generates a triangle-strip for each terrain mesh sector.
Overhead: ~1.61 indices / triangle
CPU triangulation generates a triangle-list for each terrain mesh sector.
Overhead: 3 indices / triangle
CPU triangulation generates a terminal-triangle-list for each terrain mesh sector.
Overhead: ~0.25 indices / triangle
CPU triangulation generates a sector-list for each terrain mesh sector.
Overhead: < 0.01 indices / triangle
The third component describes the mode of operation that results from the current GPU feature level and CPU triangulation mode.
'Rendering triangulation on GPU'
The CPU generates triangle-strips or triangle-lists, which are uploaded to and rendered on the GPU, using the fixed-function input assembler stage.
'Decoding triangulation on CPU'
The CPU generates triangle-strips, terminal-triangle-lists or sector-lists and converts them to triangle-lists, before uploading them to the GPU.
'Decoding triangulation on GPU'
The CPU generates terminal-triangle-lists or sector-lists and uploads them to the GPU. The GPU expands them to triangle-lists in a separate compute step, which are then used for rendering.
'Performing triangulation on GPU'
The CPU generates terminal-triangle-lists or sector-lists and uploads them to the GPU. The GPU generates triangles on-the-fly, using amplification and mesh shaders.
This feature is not available yet.
The Model checkbox shows or hides the 3D models.
The Bounds checkbox toggles rendering of the box soup that contains the bounding boxes of all 3D models.
TerrainModel API for details.
The Planted checkbox shows or hides the dynamically planted 3D models.
The Bounds checkbox toggles rendering of the box soup that contains the bounding boxes of all dynamically planted 3D models.
TerrainPlanting API for details.
The Lock View checkbox can be used to lock all view-dependent computations to the current camera position. Use this to inspect the result of frustum culling or shadow mapping, for example.
The Cascades checkbox toggles rendering of the box soup that represents the shadow-mapping cascades. The near, mid and far cascades are rendered with white, blue and red colors, respectively.
The Frustum checkbox enables or disables frustum culling.
FrustumCulling API for details.
The Horizon checkbox enables or disables horizon culling.
HorizonCulling API for details.