Class: TerrainProfileLoader
Defined in: src/sdk/navigation/TerrainProfileLoader.ts:24
Class for loading a vertical terrain profile from the simulator
Constructors
Constructor
new TerrainProfileLoader(
options?
):TerrainProfileLoader
Defined in: src/sdk/navigation/TerrainProfileLoader.ts:36
Parameters
Parameter | Type |
---|---|
options? | Readonly <TerrainProfileLoaderOptions > |
Returns
TerrainProfileLoader
Inherit Doc
Methods
getTerrainProfileAlongPath()
getTerrainProfileAlongPath(
points
,numElevations
):Promise
<TerrainProfile
>
Defined in: src/sdk/navigation/TerrainProfileLoader.ts:62
Gets an array of terrain elevation over a path of specified latlong points
Parameters
Parameter | Type | Description |
---|---|---|
points | LatLong [] | The latlong points to draw a path between |
numElevations | number | The number of elevation points along the path to return |
Returns
Promise
<TerrainProfile
>
A terrain profile interface
getTerrainProfileForFlightPlan()
getTerrainProfileForFlightPlan(
plan
,startLegGlobalIndex
,endLegGlobalIndex
,terrainDefinition
):Promise
<FlightPlanTerrainProfile
>
Defined in: src/sdk/navigation/TerrainProfileLoader.ts:103
Gets the terrain profile for all legs in a given flight plan
Parameters
Parameter | Type | Default value | Description |
---|---|---|---|
plan | FlightPlan | undefined | The flight plan |
startLegGlobalIndex | number | 0 | The global index of the first leg to check, inclusive. Defaults to leg index 0. |
endLegGlobalIndex | number | plan.length | The global index of the last leg to check, exclusive. Defaults to the flight plan length |
terrainDefinition | number | ... | The definition of the terrain, in metres. Defaults to the initial terrain minimum resolution. |
Returns
Promise
<FlightPlanTerrainProfile
>
A flight plan terrain profile
getTerrainProfileForLeg()
getTerrainProfileForLeg(
leg
,terrainDefinition
):Promise
<FlightPlanLegTerrainProfile
>
Defined in: src/sdk/navigation/TerrainProfileLoader.ts:72
Gets the terrain profile for a flight plan leg
Parameters
Parameter | Type | Description |
---|---|---|
leg | LegDefinition | The leg object |
terrainDefinition | number | The definition of the terrain, in metres. Defaults to the initial terrain minimum resolution. |
Returns
Promise
<FlightPlanLegTerrainProfile
>
A leg terrain profile. If no valid terrain profile can be found then the profile is undefined.