VerticalRange
Description
Mapping of normalized elevation values (i.e. the range -/+
HeightmapSample.MaxValue30) to vertical coordinates in a given range (for example -1000 to +9000) in terms of some vertical coordinate system (see CoordinateSystem.Vertical).
Normalized and terrain-space elevation values are always tied at zero, independent of the given minimum and maximum elevation values (see Minimum and Maximum). For the example range of -1000 to +9000, the normalized elevation zero is mapped to 0, the normalized elevation HeightmapSample.MaxValue30 is mapped to +9000 and the negative value of HeightmapSample is mapped to -9000. The actual minimum and maximum bounds become important when elevation values are encoded in a heightmap dataset, especially when using a low bit-depth.
- See also
Public / Methods
DenormalizeElevation
Transforms the given normalized heightmap elevation value to the corresponding real-world elevation value.
NormalizeElevation
Transforms the given real-world elevation value to the corresponding normalized heightmap elevation value.
NormalizeElevationClamp
Transforms the given real-world elevation value to the corresponding normalized heightmap elevation value.
ToPixelRange
Converts this VerticalRange value to a PixelRange value.
None is mapped to PixelRange.Identity. Otherwise, First and Second are mapped to the normalized pixel values 0
and 16777215
, respectively.
Transform
Transforms this vertical range from one vertical unit to another.
This method assumes that this vertical range is expressed in source in units; then the returned vertical range will be expressed in target opt units. If source in and/or target opt is null
, UnitOfMeasure.Metre will be used instead.
Public / Attributes
Elevation
Returns the factor by which normalized elevation values of this range must be multiplied in order to translate them to terrain-space elevation values.
First
The first terrain-space elevation value.
The elevation value is interpreted as relative height above the base geometry. The base geometry is usually an ellipsoid.
Maximum
The maximum terrain-space elevation value.
The elevation value is interpreted as relative height above the base geometry. The base geometry is usually an ellipsoid.