demo · v131

library handshake: host + overlay agreeing on format

A 3D library configures the canvas. An overlay library (HUD, debug, screenshot tool) needs the active format and alphaMode to build its own render pass. Before getConfiguration(), libraries had to convention-agree on a format. Now they can read it back. This page simulates both sides and shows the handshake log.

host (3D library)

awaiting init

overlay (HUD library)

the use case

Imagine three.js or babylon.js configures the canvas with rgba8unorm, then a deck.gl-style overlay wants to render on top. The overlay needs the same format to attach a render pass. Without getConfiguration() the overlay was guessing or requiring an explicit handshake API. v131 lets it ask the canvas directly.

see also