TerrainBufferOptions

Description

sealed class Tinman.Engine.Components.TerrainBufferOptions

Helper class for creating instances of TerrainBuffer.

Public / Constructors

Terrain​Buffer​Options


public constructor TerrainBufferOptions → (1)

textureAtlasCount in : int32

[>=0]
The number of texture atlases (see TextureAtlasCount).

Creates a new instance of TerrainBufferOptions.

Public / Methods

Create​Terrain​Buffer


[OwnerReturn]
public method CreateTerrainBuffer → ()

returns → TerrainBuffer

The created TerrainBuffer instance.

Creates a new instance of TerrainBuffer, based on these options.

IOException

If an I/O error has occurred while initializing the pyramid file cache (see CacheOptions).

Texture​Atlas


public method TextureAtlas → (1)

index in : int32

[0..TerrainBufferOptions.TextureAtlasCount-1]
The texture atlas index.

returns → TextureAtlasOptions

The texture atlas options.

Options for creating the index in-th texture atlas for terrain layer slot textures (see TerrainLayerSlot.TexelPyramid).

Public / Attributes

Cache​Options


public attribute CacheOptions → (get,set)

value : PyramidFileCacheOptions

The pyramid file cache options or null to open the pyramid file cache in read-only mode (i.e. for sharing between processes resp. machines).

Options for creating the texture tile cache.

These options are ignored when CachePath is null. Defaults to a fresh instance of a PyramidFileCacheOptions.

Cache​Path


public attribute CachePath → (get,set)

value : Path

The texture tile cache path or null.

Path to the texture tile cache.

Specify null to disable texture tile caching. The default value is null.

Flags


public attribute Flags → (get,set)

value : TerrainBufferFlags

The flags.

The terrain buffer flags.

Heightmap​Layers


public attribute HeightmapLayers → (get,set)

value : HeightmapLayer

The used heightmap layers.

The heightmap layers that are going to be used by terrain meshes.

The default value is HeightmapLayer.All.

Texture​Atlas​Count


public attribute TextureAtlasCount → (get)

value : int32

[>=0]
The texture atlas count

Returns the number of texture atlases.

Vertex​Capacity


public attribute VertexCapacity → (get,set)

value : int32

[>0]
The vertex capacity.

The capacity of the terrain mesh buffer.

The default value is 2097152.

Vertex​Format


public attribute VertexFormat → (get,set)

value : IVertexFormat

The custom vertex format or null to use the default one.

The custom vertex format to use.

The default value is null.