Software Development Kit - User Manual

Terrain Mesh

Tinman 3D uses rasters as input for creating terrain meshes and textures.

The basic process of creating a terrain mesh from raster data is simple:

  1. The full resolution raster is stored using an efficient storage scheme.
  2. The application defines a selection criterion, the terrain engine chooses raster samples accordingly. This creates the reduced raster.
  3. The samples of the reduced raster are triangulated into a single triangle strip. This yields a GPU-friendly triangulated irregular net (TIN).

Tinman 3D provides powerful implementations for these steps.

1. Full Resolution Raster 2. Reduced Raster 3. Terrain Mesh

You will never again associate "CLOD" with "slow". The dynamic Continuous Level-Of-Detail mode of Tinman 3D is fast enough for real-time applications.

The basic meaning of CLOD is that the whole terrain is represented by a single triangle mesh. The mesh triangles can differ in size, which makes it possible to capture different levels of detail at once. A CLOD mesh is always contiguous, it does not have holes or T-junctions. Terrain meshes created by Tinman have an inherent quadtree structure, where each node represents a mesh sector. All terrain operations can be performed on the whole mesh or on specific sectors. 

Using a CLOD approach for terrain rendering has various benefits:

Benefits of Continuous Level-Of-Detail
  1. High Detail
    CLOD can capture high local detail. If necessary, terrain mesh triangles can become very small - even down to a single pixel. This makes it possible to encode terrain data into mesh vertices which otherwise would have to be packed into textures. Effectively, this will save GPU memory and bandwidth.  
  2. Low Detail
    Only few triangles are used to represent terrain regions with low detail. The spared triangles will be used to capture high detail instead. 
  3. Vertex Colors
    The terrain surface can be textured by using per-vertex diffuse colors. This is typically used to paint distant terrain parts. This allows to get rid of the terrain base texture which otherwise becomes mandatory. 
  4. Vertex Materials
    Surface materials can be encoded as per-vertex weights. Usually material weights are used to texture near terrain parts. Materials are also used to control placement of ground objects (grass, plants, rocks, etc.). Tinman encodes independent weighted combinations of four materials out of a palette 256 possible materials, for each vertex. This makes terrain detail textures obsolete. 
  5. Vertex Normals
    A CLOD mesh accurately represents the terrain surface. Because of this, per-vertex normal, tangent and bitangent vectors are accurate enough for being used in shading and lighting computations. It is not necessary to use separate normal textures. Lightmaps can also be encoded as per-vertex data. 
  6. Smooth Mesh
    Tinman performs cubic interpolation at runtime in order to create smooth terrain surfaces, independently of the resolution of the input terrain data. This provides high-quality per-vertex data, which in turn allows an application to use advanced rendering techniques (for example, displacement mapping using GPU tesselation) with great success.

Unlimited Detail

The maximum dimensions of a Tinman 3D raster are 2^30+1 by 2^30+1. In other words: 1073741825 by 1073741825.

Rasters are sparse, so an empty raster will not consume a single byte, independent of its size. 

Current realtime 3D engines - even top-notch ones - have an upper limit orders of magnitude below that of Tinman 3D. Here are some examples:

Unreal Engine:
Maximum "Recommended Landscape Size" : 8129 by 8129

Maximum "Recommended Terrain Size" : 4096 by 4096

Maximum "Heightmap Resolution" per Terrain object : 4097 by 4097

A typical game terrain spans an area of 16km by 16km. Using the maximum terrain sizes mentioned above, this would result in ground detail of 4m resp. 8m. Working around these limitations in order to improve ground detail requires considerable amount of manual work and design.

With Tinman 3D, you no longer have to worry about terrain size. You simply choose how big your terrain should be - then you decide how much detail you want to paint on it; on-the-fly and in real-time. The Demo Application uses a detail map of size 262144 by 262144. This would provide ground detail for a typical game terrain of 6cm. The possibility to paint arbitrary detail everywhere onto the terrain simplifies development and saves time.

With a maximum size raster, Tinman 3D can easily represent the entire Earth with 9mm of gound detail.

Data Layers

A Tinman 3D raster can store one or more of the following data layers for use with terrain rendering:

Coverage is used to merge and combine rasters. Also it is used to paint holes into the terrain.

The use of Elevation is straight-forward: it creates the 3D shape of the terrain.

Texture samples are either used as per-vertex diffuse colors or encoded as a texture, depending on the use case.

Material samples store a weighted combination of up to four materials, taken from a palette of 256 possible materials.

By using Displacement, the terrain can be modeled to have overhangs or other non-2.5D terrain features.

Using Terrain Displacement


Geodata Import

Tinman 3D comes with a powerful data import module, which can populate terrain rasters quickly.

The Geodata Examples demonstrate how to import geodata into terrain rasters. 

The import module can also perform a variety of image transformations and conversions, on-the-fly during import.

Georeferenced data is interpreted correctly, which greatly facilitates import of tiled datasets.

In a nutshell, Tinman 3D takes away all the tedious groundwork which is otherwise necessary to import terrain data.

Dynamic Mode

In dynamic mode, Tinman 3D will perform real-time refinement of the terrain mesh, using a proprietary continuous level-of-detail algorithm.

This mode is great for interactive editing or analysis.

Seamless, Real-time, Adaptive CLOD Terrain Mesh

Static Mode

In static mode, Tinman 3D uses precomputed TINs for each terrain mesh sector. The static meshes will fit together seamlessly.

This mode is perfect for constrained real-time environments.

Seamless, Chunked-LOD Terrain Mesh


Decal textures can be placed anywhere onto the terrain surface, at any scale.

Tinman 3D will use existing mesh sectors for decal rendering, which makes creation of custom decal geometry obsolete.

Decal Textures on Terrain Surface

Tinman 3D will also tesselate your decal geometry in order to fit it nicely onto the terrain surface.


Tinman 3D will let you use any kind of texturing:

Texturing methods can be combined freely.

Unique Texturing Material Based Texturing

You are not restricted to a certain render API or forced to use specific GPU shaders.


Vector Shape Overlays

You can use shapes in different ways with Tinman 3D:


Tinman 3D keeps GPU terrain data in a single vertex buffer and a single index buffer.

The entire terrain mesh is wrapped in a single triangle strip. Each mesh sector has a contiguous index range and can thus be rendered efficiently with a single draw call.

The terrain mesh has a quad-tree structure, where each node corresponds to a mesh sector. This allows the terrain mesh to be traversed efficiently (e.g. for culling, shillouette detection, picking). 


Raster data and terrain meshes can be exported easily using Tinman 3D, for example to create 2D maps or to setup collision geometry for physics simulation.