Skip to content
Brass Orrery

Orrery Terrain · OrreryTerrain module · member function

FTerrainChunkPosts::

Read

Read one edit-layer tile from a snapshot: heights (Modified surface) and ground class.

Declaration

static TSharedRef<const FTerrainChunkPosts> Read(const OrreryTerrain::Native::FGroundQuery& Query,
                                                 const OrreryTerrain::Native::FTerrainGrid& Grid, FIntPoint Tile);
Header
#include "TerrainChunkPosts.h"
Module
PublicDependencyModuleNames.Add("OrreryTerrain"); in your module’s Build.cs.
Stability
Stable: changes within a major version only add.
Thread
Any thread; pure.

Description

Heights come from FGroundQuery::CopyEditTile in one call, kept as its millimetres (above a datum of 0). The ground class is read per cell through FGroundQuery::CopyEditTileChannel. The paint is held, not copied: FGroundQuery::EditTilePaintPlanes.

Parameters

NameTypeDefaultMeaning
Queryconst OrreryTerrain::Native::FGroundQuery&—

The snapshot to read; acquired on the game thread, read here on any thread.

Gridconst OrreryTerrain::Native::FTerrainGrid&—

The terrain's grid (FTerrainConfig::Grid), metres.

TileFIntPoint—

Edit-layer tile coordinate.

Returns

The posts, or empty posts (IsEmpty) when the tile is outside the terrain.

Note.

Any thread; pure. About 0.1 ms for the heights plus the channel pass per 128² tile.