Capability Probing & Engine Creation (probeCapabilities / createFrameFlow)
Tries WebGPU Compute (auto-enabling shader-f16 with seamless f32 fallback) first and degrades automatically to WebGL2 RGBA16F + MRT; accepts { device } or { gl } for zero-copy emulator sharing.
Open Browser & Emulator Integration ↗✅ Supported Capabilities
- probeCapabilities() checks WebGPU and WebGL2 float FBO support without allocating session textures
- Supports zero-copy shared { device: GPUDevice } (PVSSPW) and { gl: WebGL2RenderingContext } (PPSSPW)
⛔ Explicit Non-Goals & Limits
- No CPU / WASM inference fallback: explicitly rejects browsers lacking both WebGPU and float/half-float FBO targets
- Never call cross-device copyExternalImageToTexture on an OffscreenCanvas-transferred element
Parameters, Options & Validation Guards
backendconfig'auto' | 'webgpu' | 'webgl2'OptionalDefault: 'auto'Follows device -> webgpu or gl -> webgl2 hints when supplied
deviceconfigGPUDeviceOptionalReuse host GPUDevice to avoid cross-device texture copies
glconfigWebGL2RenderingContextOptionalReuse host WebGL2 context
precisionconfig'auto' | 'f16' | 'f32'OptionalDefault: 'auto'Selects f16 WGSL compute when shader-f16 is exposed