Search Unity

  1. Looking for a job or to hire someone for a project? Check out the re-opened job forums.
    Dismiss Notice
  2. Unity wants to learn about your experiences working on a Unity project today. We'd like to hear from you via this survey.
    Dismiss Notice
  3. Unity 2020 LTS & Unity 2021.1 have been released.
    Dismiss Notice
  4. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice
  5. Read here for Unity's latest plans on OpenXR.
    Dismiss Notice

Help Wanted Loss of WebXR Headset Tracking after Addressable Loading

Discussion in 'AR/VR (XR) Discussion' started by Bwavo, Sep 15, 2020.

  1. Bwavo

    Bwavo

    Joined:
    Feb 22, 2017
    Posts:
    4
    Hello everyone.
    I'm creating an experience for WebXR and I'm running into a really interesting issue. Here's the problem (copied from my GitHub issue):
    While playing my experience in WebXR, my headset will lose tracking after loading in certain addressable scenes. By lose tracking, I mean that the current orientation becomes fixed onto the screen. It is a very similar effect to disabling the CameraMain game object in the editor. After this occurs in WebXR though, I am still able to teleport, snap turn, and otherwise see the game changing. Controllers are still tracked. The headset's image just doesn't move to match the rotation of my head. I know that no cameras are being disabled, I created a console log that would notify me if this were the case.
    I've begun to suspect that I may be running out of memory, which is causing this loss of tracking. I'm getting no errors, warnings, or anything else that would show that this is the cause, though. Here's a screenshot of the console, showing that everything is successfully being stored in the cache and no errors are appearing (most of this is related to the addressable loading):

    There are a few things that make me unsure that it is truly memory related, though. Some large bundles (40+mb) load fine and don't result in a loss of tracking, whereas other smaller scenes (~24mb) do. In addition, sometimes the loss of tracking occurs immediately when the bundle is downloaded, other times it occurs a few minutes after the download, regardless of where I am or what I am doing within the experience. Also, this only occurs in an actual browser, not within the Unity Editor, so I'm led to believe it isn't caused by a buggy script. The server I'm loading the files from is definitely fast enough as well.

    Specs:
    Unity Editor: 2019.3.15f1
    Browser: Occurs on both Firefox Developer Edition 81 and Firefox 80
    OS: Windows 10
    Headset: Oculus Rift CV1

    Thanks for reading, hopefully someone will have some insight as to what is happening here.
    Bwavo
     
unityunity