Class: MapCanvasLayerCanvasInstanceClass
An implementation of MapCanvasLayerCanvasInstance.
Hierarchy
MapCanvasLayerCanvasInstanceClass
Implements
Constructors
constructor
• new MapCanvasLayerCanvasInstanceClass(canvas
, context
, isDisplayed
): MapCanvasLayerCanvasInstanceClass
Creates a new canvas instance.
Parameters
Name | Type | Description |
---|---|---|
canvas | HTMLCanvasElement | The canvas element. |
context | CanvasRenderingContext2D | The canvas 2D rendering context. |
isDisplayed | boolean | Whether the canvas is displayed. |
Returns
MapCanvasLayerCanvasInstanceClass
Defined in
src/sdk/components/map/layers/MapCanvasLayer.tsx:45
Properties
canvas
• Readonly
canvas: HTMLCanvasElement
The canvas element.
Implementation of
MapCanvasLayerCanvasInstance.canvas
Defined in
src/sdk/components/map/layers/MapCanvasLayer.tsx:46
context
• Readonly
context: CanvasRenderingContext2D
The canvas 2D rendering context.
Implementation of
MapCanvasLayerCanvasInstance.context
Defined in
src/sdk/components/map/layers/MapCanvasLayer.tsx:47
isDisplayed
• Readonly
isDisplayed: boolean
Whether the canvas is displayed.
Implementation of
MapCanvasLayerCanvasInstance.isDisplayed
Defined in
src/sdk/components/map/layers/MapCanvasLayer.tsx:48
Methods
clear
▸ clear(): void
Clears this canvas.
Returns
void
Implementation of
MapCanvasLayerCanvasInstance.clear
Defined in
src/sdk/components/map/layers/MapCanvasLayer.tsx:53
reset
▸ reset(): void
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
Implementation of
MapCanvasLayerCanvasInstance.reset
Defined in
src/sdk/components/map/layers/MapCanvasLayer.tsx:58