Limited supportUse with care and provide a fallback when broad support matters.

Overview

The optional desynchronized parameter of a canvas's getContext() method permits the browser to draw a WebGL2 canvas independently of the event loop. This can reduce drawing latency. It is most useful when native HTML semantics or browser capabilities can replace custom implementation work.

Browser support

Feature Desktop Mobile
Chrome
Edge
Firefox
Safari
Chrome Android
Safari iOS
api.HTMLCanvasElement.getContext.webgl2_context.options_desynchronized_parameter
81
79
75
1+Supported (version) Not supported Has note Sub-feature descriptions sourced from MDN Web Docs (CC BY-SA 2.5)
Notes 4 item(s)
Implementation note
  • ChromeOS and Windows
  • ChromeOS only
Limitation
  • This browser only partially implements this feature
Removed
  • This feature was removed in a later browser version (81)

Syntax

JAVASCRIPT
const gl = canvas.getContext('webgl2', {
  desynchronized: true,
  preserveDrawingBuffer: true
});

Live demo

WebGL2 low-latency hint

Apply desynchronized rendering ideas to WebGL2 contexts on supported platforms.

PreviewFullscreen

Typical scenarios

Use low-latency rendering when pointer or sensor motion should feel immediate.

PreviewFullscreen

Platform reminder

GPU, driver, and browser differences still determine the final behavior.

PreviewFullscreen

Use cases

  • Use Desynchronized WebGL2 canvas

    Use Desynchronized WebGL2 canvas when standard HTML needs a more specific platform feature, semantic signal, or browser capability.

  • Handle edge cases

    Apply Desynchronized WebGL2 canvas to solve a focused requirement without redesigning the whole page architecture.

Cautions

  • Test Desynchronized WebGL2 canvas in your target browsers and input environments before depending on it as a primary behavior.
  • Provide a fallback path or acceptable degradation strategy when support is still limited.

Accessibility

  • Make sure Desynchronized WebGL2 canvas supports the intended task without making the page harder to perceive, understand, or operate.

Powered by web-features