AR Session Start/Stop events?

Any way to register a listener for AR Starting or Stopping?

Original Post on Discord

by user 103054507105067008

You can use the static methods on WebXR to register callbacks i think

Sorted this in start via:

    WebXR.addEventListener(WebXREvent.XRStarted, this.onXRStarted.bind(this));
    WebXR.addEventListener(WebXREvent.XRStopped, this.onXRStopped.bind(this));

With functions like:

    onXRStarted()
    {
        console.log("XR Started!");
    }

    onXRStopped()
    {
        console.log("XR Stopped!");
    }

by user 103054507105067008