Class: MapFlightPlanFocusCalculator
Calculates map projection parameters to fit flight plan foci.
Constructors
constructor
• new MapFlightPlanFocusCalculator(mapProjection
): MapFlightPlanFocusCalculator
Constructor.
Parameters
Name | Type | Description |
---|---|---|
mapProjection | MapProjection | This calculator's map projection. |
Returns
Defined in
src/garminsdk/components/map/flightplan/MapFlightPlanFocusCalculator.ts:24
Methods
calculateRangeTarget
▸ calculateRangeTarget(focus
, margins
, ppos
, out
): MapFieldOfView
Calculates a maximum range and target center for a given flight plan focus such that the terminators of all legs in the focus are visible in this calculator's map projection. If there is only one leg terminator in the specified focus, the calculated range will be equal to 0. If a range and target could not be calculated, NaN will be written to the results.
Parameters
Name | Type | Description |
---|---|---|
focus | FlightPlanFocus | The array of legs on which to focus. |
margins | Float64Array | The margins around the projected map boundaries to respect. Expressed as [left, top, right, bottom]. |
ppos | LatLonInterface | The current position of the airplane. |
out | MapFieldOfView | The object to which to write the results. |
Returns
MapFieldOfView
The calculated range and target for the specified focus.
Defined in
src/garminsdk/components/map/flightplan/MapFlightPlanFocusCalculator.ts:38