Home Reference Source
import {CanvasOverlayer} from 'mapbox-plugins/src/layers/canvasOverlay.js'
public class | source

CanvasOverlayer

Extends:

Overlayer → CanvasOverlayer

Direct Subclass:

WindLayer

initCanvasOverlayer based on mapboxgl-canvas

Constructor Summary

Public Constructor
public

Member Summary

Public Members
public
public

canvas: *

public
public
public

labelOn: *

public
public
public

redraw: *

public

shadow: *

public
public
public

tracks: *[]

public

xfield: *

public

yfield: *

Method Summary

Public Methods
public

getTracks(): *

public

render cached tracks to line when map moved..

public

setTracks(tracks: *array of track points.): *

set tracks coordinates of overlayer.

Private Methods
private

_init(shadow: boolean, keepTrack: boolean): *

private

init track ctx for each track segment rendering..

Inherited Summary

From class Overlayer
public

map: *

public

lnglat2pix(lng: *, lat: *): undefined[]

use Global map or this.map instance to project

public

setMap(map: *): *

private

_init()

to be overwrite in subClass

Public Constructors

public constructor() source

Override:

Overlayer#constructor

Public Members

public blurWidth: * source

public canvas: * source

public initTrackCtx: * source

public keepTrack: * source

public labelOn: * source

public lineColor: * source

public movedTo: boolean source

public redraw: * source

public shadow: * source

public trackCtx: * source

public trackLayer: * source

public tracks: *[] source

public xfield: * source

public yfield: * source

Public Methods

public getTracks(): * source

Return:

*

public redrawTrack() source

render cached tracks to line when map moved..

public setTracks(tracks: *array of track points.): * source

set tracks coordinates of overlayer.

Params:

NameTypeAttributeDescription
tracks *array of track points.

Return:

*

Private Methods

private _init(shadow: boolean, keepTrack: boolean): * source

to be overwrite in subClass

Override:

Overlayer#_init

Params:

NameTypeAttributeDescription
shadow boolean
  • optional
  • default: false
keepTrack boolean
  • optional
  • default: false

Return:

*

private _initTrackCtx() source

init track ctx for each track segment rendering..