Creates a Canvas controller instance.
The main HTMLMicrioElement instance.
ReadonlyelementThe main WebGL rendering <canvas> element.
ReadonlyisWritable Svelte store indicating if the client is likely a mobile device.
ReadonlyviewportObject containing current viewport dimensions, position, and ratios.
Getter for the current value of the isMobile store.
Gets the appropriate device pixel ratio for rendering.
Clamped between 1 and 2, disabled on iOS and if noRetina setting is true.
Optional image settings object to check for noRetina.
The calculated device pixel ratio.
Sets virtual offset margins in the engine controller. This likely affects how viewports are calculated or limited.
The horizontal offset margin in pixels.
The vertical offset margin in pixels.
Manages the HTML
<canvas>element used for WebGL rendering, handles resizing, and provides viewport information. Accessed viamicrio.canvas.