Luxar Viewer API Documentation - v2026.10.22
    Preparing search index...

    Module scene/scene-manager/render-pipeline/backend-policy

    Which machines get WebGPU when nothing selects a backend.

    WebGPU is the intended renderer, but whether it beats WebGL depends on the platform: the #3146 go/no-go measured it 2-9% faster in GPU time on Linux with an NVIDIA card (Vulkan), and up to ~20% slower on Apple GPUs (Metal), where Dawn's bounds-check clamps run inside the shader (#3224). So the default is a table of measured platforms rather than one global switch: a row admits a platform to WebGPU, and everything without a row stays on WebGL. Add a row only after the render gate's perf and hosted suites have been run on that platform (--backends webgl,webgpu), and only once cold load there is within 0.15 s of WebGL (#3172). Until then the table is empty and measured rows wait in STAGED_WEBGPU_PLATFORM_RULES.

    Matching runs in two steps so a session that cannot qualify never pays for WebGPU. The OS and browser come from the user agent and are checked before any adapter request; the GPU vendor comes from GPUAdapter.info and is checked once the adapter answers, before the device request and the three/webgpu download. The vendor is the reliable key: user-agent strings misreport the hardware (Safari on Apple silicon says "Intel Mac OS X").

    BrowserPlatform
    WebGPUPlatformRule
    PlatformOS
    BrowserFamily
    STAGED_WEBGPU_PLATFORM_RULES
    WEBGPU_PLATFORM_RULES
    defaultPlatformRules
    detectBrowserPlatform
    candidateRules
    matchAdapterRule