SlopeInfo

Description

struct Tinman.Terrain.Buffers.SlopeInfo

The SlopeInfo structure stores additional information that is needed for computing terrain slope values for heightmap samples.

Public / Constants

One


public static readonly attribute One → (SlopeInfo)

A SlopeInfo value where both scale factors are 1.0f.

Public / Constructors

Slope​Info


public constructor SlopeInfo → (2)

scaleHorizontal in : float32

[>0]
The horizontal scale factor (see ScaleHorizontal).

scaleVertical in : float32

The vertical scale factor (see ScaleVertical).

Creates a new instance of SlopeInfo.

Public / Methods

Scale


public method Scale → (2)

in : float32

[>0]
Horizontal scale factor.

in : float32

[>0]
Vertical scale factor.

returns → SlopeInfo

The resulting scale factor.

Scales this slope info value.

To​String


public override method ToString → ()

returns → string

The string representation.

Returns the string representation of this value.

The string representation is '(H / V)', where H is the value of ScaleHorizontal and V is the value of ScaleVertical.

Public / Attributes

Scale​Horizontal


public readonly attribute ScaleHorizontal → (float32)

The horizontal scale factor.

The horizontal scale factor is applied to the local coordinates of a heightmap sample. The scaled coordinates are then used in the slope computation.

Scale​Vertical


public readonly attribute ScaleVertical → (float32)

The vertical scale factor.

The vertical scale factor is applied to the normalized elevation values of a heightmap sample.