Skip to main content

Interface: MapCachedCanvasLayerCanvasInstance

Defined in: src/sdk/components/map/layers/MapCachedCanvasLayer.ts:151

An instance of a canvas within a MapCachedCanvasLayer.

Extends​

Properties​

canvas​

readonly canvas: HTMLCanvasElement

Defined in: src/sdk/components/map/layers/MapCanvasLayer.tsx:17

This instance's canvas element.

Inherited from​

MapCanvasLayerCanvasInstance.canvas


context​

readonly context: CanvasRenderingContext2D

Defined in: src/sdk/components/map/layers/MapCanvasLayer.tsx:20

This instance's canvas 2D rendering context.

Inherited from​

MapCanvasLayerCanvasInstance.context


geoProjection​

readonly geoProjection: GeoProjection

Defined in: src/sdk/components/map/layers/MapCachedCanvasLayer.ts:165

The projection used to draw this instance's canvas image.


isDisplayed​

readonly isDisplayed: boolean

Defined in: src/sdk/components/map/layers/MapCanvasLayer.tsx:23

Whether this instance's canvas is displayed.

Inherited from​

MapCanvasLayerCanvasInstance.isDisplayed


isInvalid​

readonly isInvalid: boolean

Defined in: src/sdk/components/map/layers/MapCachedCanvasLayer.ts:162

Whether this instance's transform is invalid.


reference​

readonly reference: MapCachedCanvasLayerReference

Defined in: src/sdk/components/map/layers/MapCachedCanvasLayer.ts:156

This instance's map projection reference. The rendering of items to this instance's canvas is based on this reference.


transform​

readonly transform: MapCachedCanvasLayerTransform

Defined in: src/sdk/components/map/layers/MapCachedCanvasLayer.ts:159

This instance's transform.

Methods​

clear()​

clear(): void

Defined in: src/sdk/components/map/layers/MapCanvasLayer.tsx:26

Clears this canvas.

Returns​

void

Inherited from​

MapCanvasLayerCanvasInstance.clear


invalidate()​

invalidate(): void

Defined in: src/sdk/components/map/layers/MapCachedCanvasLayer.ts:182

Invalidates this canvas instance. This also clears the canvas.

Returns​

void


reset()​

reset(): void

Defined in: src/sdk/components/map/layers/MapCanvasLayer.tsx:32

Resets this instance's canvas. This will erase the canvas of all drawn pixels, reset its state (including all styles, transformations, and cached paths), and clear the Coherent GT command buffer associated with it.

Returns​

void

Inherited from​

MapCanvasLayerCanvasInstance.reset


syncWithCanvasInstance()​

syncWithCanvasInstance(other): void

Defined in: src/sdk/components/map/layers/MapCachedCanvasLayer.ts:177

Syncs this canvas instance with another canvas instance.

Parameters​

ParameterTypeDescription
otherMapCachedCanvasLayerCanvasInstancethe canvas instance with which to sync.

Returns​

void


syncWithMapProjection()​

syncWithMapProjection(mapProjection): void

Defined in: src/sdk/components/map/layers/MapCachedCanvasLayer.ts:171

Syncs this canvas instance with the current map projection.

Parameters​

ParameterTypeDescription
mapProjectionMapProjectionThe current map projection.

Returns​

void