Class: MapAirportIcon<T>
Defined in: src/garminsdk/components/map/MapWaypointIcon.ts:13
An airport icon.
Extends
MapWaypointSpriteIcon
<T
>
Type Parameters
Type Parameter |
---|
T extends AirportWaypoint |
Constructors
Constructor
new MapAirportIcon<
T
>(waypoint
,priority
,img
,size
,options?
):MapAirportIcon
<T
>
Defined in: src/garminsdk/components/map/MapWaypointIcon.ts:23
Constructor.
Parameters
Parameter | Type | Description |
---|---|---|
waypoint | T | The waypoint associated with this icon. |
priority | number | Subscribable <number > | The render priority of this icon. Icons with higher priorities should be rendered above those with lower priorities. |
img | HTMLImageElement | The image to use for the icon. |
size | Readonly <Omit <Float64Array , "set" | "sort" | "copyWithin" >> | Subscribable <Readonly <Omit <Float64Array , "set" | "sort" | "copyWithin" >>> | The size of this icon, as [width, height] in pixels, or a subscribable which provides it. |
options? | AbstractMapWaypointIconOptions | Options with which to initialize this icon. |
Returns
MapAirportIcon
<T
>
Overrides
MapWaypointSpriteIcon<T>.constructor
Properties
anchor
readonly
anchor:Subscribable
<Readonly
<Omit
<Float64Array
,"set"
|"sort"
|"copyWithin"
>>>
Defined in: src/sdk/components/map/MapWaypointIcon.ts:86
The anchor point of this icon, expressed relative to its width and height. [0, 0] is the top-left corner, and [1, 1] is the bottom-right corner.
Inherited from
MapWaypointSpriteIcon.anchor
frameHeight
protected
readonly
frameHeight:number
Defined in: src/sdk/components/map/MapWaypointIcon.ts:185
The frame height of the sprite, in pixels.
Inherited from
MapWaypointSpriteIcon.frameHeight
frameWidth
protected
readonly
frameWidth:number
Defined in: src/sdk/components/map/MapWaypointIcon.ts:184
The frame width of the sprite, in pixels.
Inherited from
MapWaypointSpriteIcon.frameWidth
img
protected
readonly
img:HTMLImageElement
Defined in: src/sdk/components/map/MapWaypointIcon.ts:183
This icon's sprite's image source.
Inherited from
MapWaypointSpriteIcon.img
offset
readonly
offset:Subscribable
<Readonly
<Omit
<Float64Array
,"set"
|"sort"
|"copyWithin"
>>>
Defined in: src/sdk/components/map/MapWaypointIcon.ts:89
The offset of this icon from the projected position of its associated waypoint, as [x, y]
in pixels.
Inherited from
MapWaypointSpriteIcon.offset
priority
readonly
priority:Subscribable
<number
>
Defined in: src/sdk/components/map/MapWaypointIcon.ts:77
Inherit Doc
Inherited from
MapWaypointSpriteIcon.priority
size
readonly
size:Subscribable
<Readonly
<Omit
<Float64Array
,"set"
|"sort"
|"copyWithin"
>>>
Defined in: src/sdk/components/map/MapWaypointIcon.ts:80
The size of this icon, as [width, height]
in pixels.
Inherited from
MapWaypointSpriteIcon.size
waypoint
readonly
waypoint:T
Defined in: src/sdk/components/map/MapWaypointIcon.ts:100
The waypoint associated with this icon.
Inherited from
MapWaypointSpriteIcon.waypoint
tempVec2
protected
readonly
static
tempVec2:Float64Array
Defined in: src/sdk/components/map/MapWaypointIcon.ts:74
Inherited from
MapWaypointSpriteIcon.tempVec2
Methods
draw()
draw(
context
,mapProjection
):void
Defined in: src/sdk/components/map/MapWaypointIcon.ts:113
Parameters
Parameter | Type |
---|---|
context | CanvasRenderingContext2D |
mapProjection | MapProjection |
Returns
void
Inherit Doc
Inherited from
MapWaypointSpriteIcon.draw
drawIconAt()
protected
drawIconAt(context
,mapProjection
,left
,top
):void
Defined in: src/sdk/components/map/MapWaypointIcon.ts:194
Parameters
Parameter | Type |
---|---|
context | CanvasRenderingContext2D |
mapProjection | MapProjection |
left | number |
top | number |
Returns
void
Inherit Doc
Inherited from
MapWaypointSpriteIcon.drawIconAt
getSpriteFrame()
protected
getSpriteFrame(mapProjection
):number
Defined in: src/garminsdk/components/map/MapWaypointIcon.ts:34
Gets the sprite frame to render.
Parameters
Parameter | Type | Description |
---|---|---|
mapProjection | MapProjection | The map projection to use. |
Returns
number
The sprite frame to render.
Overrides
MapWaypointSpriteIcon.getSpriteFrame