Table of Contents

Class TerrainModel

Namespace
HelixToolkit.Wpf
Assembly
HelixToolkit.Wpf.dll

Represents a terrain model.

public class TerrainModel : ITerrainModel
Inheritance
TerrainModel
Implements
Inherited Members

Remarks

Supports the following terrain file types .bt .btz

Read .bt files from disk, keeps the model data and creates the Model3D. The .btz format is a gzip compressed version of the .bt format.

Properties

Bottom

Gets or sets the bottom.

public double Bottom { get; set; }

Property Value

double

The bottom.

Data

Gets or sets the data.

public double[] Data { get; set; }

Property Value

double[]

The data.

Height

Gets or sets the height.

public int Height { get; set; }

Property Value

int

The height.

Left

Gets or sets the left.

public double Left { get; set; }

Property Value

double

The left.

Lod

Gets the lod.

public int Lod { get; }

Property Value

int

MaximumZ

Gets or sets the maximum Z.

public double MaximumZ { get; set; }

Property Value

double

The maximum Z.

MinimumZ

Gets or sets the minimum Z.

public double MinimumZ { get; set; }

Property Value

double

The minimum Z.

Offset

Gets or sets the offset.

public Point3D Offset { get; set; }

Property Value

Point3D

The offset.

Right

Gets or sets the right.

public double Right { get; set; }

Property Value

double

The right.

Texture

Gets or sets the texture.

public TerrainTexture? Texture { get; set; }

Property Value

TerrainTexture

The texture.

Top

Gets or sets the top.

public double Top { get; set; }

Property Value

double

The top.

Width

Gets or sets the width.

public int Width { get; set; }

Property Value

int

The width.

Methods

CreateModel(int)

Creates the 3D model of the terrain.

public GeometryModel3D CreateModel(int lod)

Parameters

lod int

The level of detail.

Returns

GeometryModel3D

The Model3D.

Load(string)

Loads the specified file.

public void Load(string source)

Parameters

source string

The file name.

ReadTerrainFile(Stream)

Reads a .bt (Binary terrain) file. http://www.vterrain.org/Implementation/Formats/BT.html

public void ReadTerrainFile(Stream stream)

Parameters

stream Stream

The stream.