安全上下文
此特征只可用于
安全上下文
(HTTPS),在某些或所有
支持浏览器
.
WebXR 设备 API
interface
XRReferenceSpaceEvent
represents an event sent to an
XRReferenceSpace
. Currently, the only event that uses this type is the
reset
事件。
XRReferenceSpaceEvent()
XRReferenceSpaceEvent
with the specified type and configured using the values in the given
XRReferenceSpaceEventInit
字典。
In addition to inheriting the properties available on the parent interface,
事件
,
XRReferenceSpaceEvent
objects include the following properties:
referenceSpace
只读
XRReferenceSpace
indicating the reference space that generated the event.
transform
只读
XRRigidTransform
object indicating the position and orientation of the specified
referenceSpace
's native origin after the event, defined relative to the coordinate system before the event.
While
XRReferenceSpaceEvent
does not define any methods, it inherits the methods of its parent interface,
事件
.
reset
reset
event is sent to a reference space when its native origin is changed due to a discontinuity, recalibration, or device reset. This is an opportunity for your app to update any stored transforms, position/orientation information, or the like—or to dump any cached values based on the reference's space's origin so you can recompute them as needed.
| 规范 | 状态 | 注释 |
|---|---|---|
|
WebXR 设备 API
The definition of 'XRReferenceSpaceEvent' in that specification. |
工作草案 | 初始定义。 |
The compatibility table in this page is generated from structured data. If you'd like to contribute to the data, please check out https://github.com/mdn/browser-compat-data and send us a pull request.
更新 GitHub 上的兼容性数据| 桌面 | 移动 | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
XRReferenceSpaceEvent
|
Chrome 79 | Edge 79 | Firefox No | IE No | Opera No | Safari No | WebView Android No | Chrome Android 79 | Firefox Android No | Opera Android No | Safari iOS No | Samsung Internet Android 11.2 |
XRReferenceSpaceEvent()
构造函数
|
Chrome 79 | Edge 79 | Firefox No | IE No | Opera No | Safari No | WebView Android No | Chrome Android 79 | Firefox Android No | Opera Android No | Safari iOS No | Samsung Internet Android 11.2 |
referenceSpace
|
Chrome 79 | Edge 79 | Firefox No | IE No | Opera No | Safari No | WebView Android No | Chrome Android 79 | Firefox Android No | Opera Android No | Safari iOS No | Samsung Internet Android 11.2 |
transform
|
Chrome 79 | Edge 79 | Firefox No | IE No | Opera No | Safari No | WebView Android No | Chrome Android 79 | Firefox Android No | Opera Android No | Safari iOS No | Samsung Internet Android 11.2 |
完整支持
不支持
XRReferenceSpaceEvent