Sync web-platform-tests PR 30096 into mozilla-central (this bug is closed when the sync is complete).
Reland "Refactor XR mojo API to directly send array of views"
This is a reland of 6aa36ea5b2abd250d763a94016235441b3c9c823.
In addition to the original change, this fixes XRViewTest.ViewMatrices.
This test creates an XRViewData on the stack and passes it into XRView
to be stored as a Member. An assertion was firing because Member expects
the object to be on the heap.
Original change's description:
Refactor XR mojo API to directly send array of views
This change sends the array of views directly from the XR process to
Blink and the browser process, instead of sending individual
head-from-eye and head-from-local poses. With this change, Blink
and the browser process no longer have to manually calculate the
transforms and can instead use the transforms directly from the XR
runtime. This also allows the XR runtime to send an arbitrary number
of views in the case where WebXR requests secondary views.
This change also improves OpenXR stability. Requesting head-from-eye
and head-from-local poses requires two separate calls to OpenXR,
which uses slightly different timestamps. As a result, the final
transform calculated by Blink and passed to WebXR is slightly off
from the transform OpenXR use, resulting in some jittering in
Commit-Queue: Patrick To \<firstname.lastname@example.org>
Reviewed-by: Sam McNally \<email@example.com>
Reviewed-by: Alexander Cooper \<firstname.lastname@example.org>