WebGPU XR: velocity-proportional pose drift ("world crawl") on desktop PCVR (SteamVR/OpenXR)
WebXR
### Description
Testing WebXR-over-WebGPU (`WebGPURenderer` + immersive-vr with the `webgpu` session feature) on **desktop PCVR** (SteamVR/OpenXR, Windows, AMD Radeon): the session starts and renders correct stereo, but the whole world exhibits **crawling/warping proportional to head velocity** — slight shimmer at rest (tracking micro-movement), severe on head turns. Nausea-grade.
**Control:** the identical page/scene with `forceWebGL: true` (and a GL-flavored session) is flawless on the same hardware/compositor. The defect is specific to the WebGPU XR path.
Reproduced on **r185** and on a **current dev build** — the recent XRManager changes (removal of the layer `depthStencilFormat`, MSAA rework) don't affect it.
### What we ruled out (one variable per experiment, on hardware)
1. **Frame cadence** — instrumented XR rAF deltas: locked 11.1 ms median, 11.1 ms p95 (90 Hz), one 22 ms frame in ~1300. Not pacing.
2. **Eye routing** — per-eye layer-masked markers land in the correct eyes, stable. Not view mapping.
3. **Depth declaration** — on r185 we monkeypatched `createProjectionLayer` to omit `depthStencilFormat` (r185 declares `depth24plus` but the per-view loop only consumes `colorTexture`, so layer depth is never written — the compositor was reprojecting from an unwritten depth buffer). Symptom unchanged, and dev (which no longer declares it) reproduces too. Not (only) depth.
4. **WebGL control** — same scene stable. Not scene/compositor/tracking.
### Remaining hypothesis
Frames are produced on time but reach the compositor out of sync with the pose they were rendered for. Reading the source: `queue.submit` is synchronous inside `finishRender` (in-rAF), so the race may live below three.js — in the browser's Dawn↔OpenXR shared-texture handoff — but engine-side sequencing (e.g. where in the frame the XR texture is written relative to rAF return) is the only lever available in JS, and three.js is currently the only engine exercising this path at all.
### Reproduction steps
Chrome flags: `#webxr-projection-layers`, `#webxr-webgpu-binding`, `#webxr-incubations` → restart → open the live repro on any desktop PCVR setup → ENTER VR → move your head. Compare with `?webgl=1`.
We're happy to test candidate patches on real hardware quickly — this rig (SteamVR + AMD Radeon, Windows) is available for fast iteration, and the repro page logs frame-cadence stats to the console.
### Reproduction repository/live example
https://github.com/octopusburrow/webxr-webgpu-xr-repro (live: https://raw.githack.com/octopusburrow/webxr-webgpu-xr-repro/main/index.html)
### Version
r185 (also reproduces on dev)
### Device
Desktop PCVR — SteamVR (OpenXR), Windows 11, AMD Radeon
### Browser
Chrome (with WebXR WebGPU binding flags; exact build to follow in a comment)
### OS
Windows 11
8 条评论