How to build XR-only Components
How to make components only activate during XR sessions.
Many components are only needed once a VR or AR sesion is entered.
To ensure components don’t update outside of xr sessions, you can use the following code snippet.
|
|
(De-)Activate other Components
If you want to disable/enable other components based on the session state,
without changing their code, you can use the vr-active-mode-switch
components,
which will disable/enable components depending on whether the user is in an XR session or not.
Last Update: August 4, 2021