OverlaySystem.canvas¶
Summary¶
OverlaySystem.canvas returns the HTML canvas associated with this overlay system. It is the projection reference for viewport size and screen-space mapping.
Syntax¶
Parameters¶
This property does not take parameters.
Returns¶
HTMLCanvasElement - Canvas bound to this overlay system.
Type Details¶
Example¶
const canvas = document.querySelector("canvas");
const wgpu = await WasmGPU.create(canvas);
const overlay = wgpu.createOverlay.system();
console.log(overlay.canvas === canvas);