OpenTTD: HeightMap Struct Reference

OpenTTD

- Main Page
- Related Pages
- Modules
- Namespaces
- Data Structures
- Files

- Data Structures
- Class Hierarchy
- Data Fields

Public Member Functions | Data Fields
HeightMap Struct Reference

Height map - allocated array of heights (MapSizeX() + 1) x (MapSizeY() + 1) More...

## Public Member Functions
height_t & | height (uint x, uint y)
| Height map accessor.

## Data Fields
height_t * | h
int | dim_x
int | total_size
int | size_x
int | size_y

## Detailed Description

Height map - allocated array of heights (MapSizeX() + 1) x (MapSizeY() + 1)

Definition at line 164 of file tgp.cpp.

## Member Function Documentation

height_t& HeightMap::height | ( | uint | x,
|  | uint | y
| ) |  |
| inline

Height map accessor.

Parameters

  x | X position
  y | Y position

Returns
  height as fixed point number

Definition at line 180 of file tgp.cpp.

Referenced by GenerateTerrainPerlin(), HeightMapCoastLines(), HeightMapCurves(), HeightMapGenerate(), HeightMapGetMinMaxAvg(), HeightMapSmoothCoastInDirection(), and HeightMapSmoothSlopes().

The documentation for this struct was generated from the following file:

- src/tgp.cpp