04-09-2024 08:06 AM
Configuration:
Meta Quest 3
UE5.3.2 (Windows x64)
Mixed Reality Utility Kit Plugin 63.0
MetaXR Plugin 63.0
I just started using the MR Utility Kit and am having some problems with the sample project. The demo attempts to load the Scene description stored on the headset, and if that fails, it loads a random room from a JSON data table asset. The headset has a Scene already setup, and I found that while playing VR in the UE Editor, I could get the Scene to load after enabling "Spatial Data over Meta Quest Link" in the Oculus desktop app. At this point my room would load properly, but would soon start slowly "floating away" uncontrollably. So I turned off the World Locking feature in the MR Utility Kit plugin, and now the room stays in place (this drifting is probably a separate issue?). I packaged the project for Windows and played in PCVR, and the Scene loads correctly. But the main problem is when I package the APK and deploy to the headset, the Scene does not load in the standalone app and falls back to one of the random JSON rooms. The app has permission to use spatial data, so I don't know what's going on or how to troubleshoot this. Any thoughts or help would be greatly appreciated!
Solved! Go to Solution.
04-11-2024 05:56 AM
I'm using the sample project that comes zipped up in the Utility Kit v63 download. I also added the Meta plugins (MetaXR and MRUK) to a brand new VR Template project, and it behaves the same way (Scene data loads in VR Preview and PCVR, but not with APK). I tried rolling back both plugins to v62, and still the same behavior. Permissions seem to be fine; Unreal just fails to load the Scene data. I have not had the need to debug an APK on the headset before, so that is a bit new to me. Haven't really figured out where to find the relevant information that might explain the load failure.
Glad the delegate helped! I modified mine slightly to let it work with VR Preview. It was hanging at the delegate because the Permissions dialog does not appear while working via Link, so this let it bypass the delegate in VR Preview, which apparently doesn't need permission, probably because "Spatial Data over Meta Quest Link" is enabled in the Oculus client app.
04-11-2024 06:08 AM
Super strange man. Yeah, might be time to bring out debugging the headset. Easiest way I've found is to install the developer hub (https://developer.oculus.com/meta-quest-developer-hub/). You probably already know how but just in case, go to the Devices tab and click the Device Logs button on the right and then start the app on the headset. You can filter the logs by the app name and see what's going on. Hope you get some resolution here.
04-11-2024 07:28 AM
Long story short, it is working now!
I have used the MQDH before and looked at the device logs, but didn't know you could filter by app name, so hadn't found these logs very helpful in the past. So thanks for that!
Using the MQDH device logs and filtering on my app name, I noticed that there was some kind of trust issue with the app, which made me think maybe it was needing to connect to a Meta or Unreal server online. I develop in an environment where the headset is offline. So I went down to our lab, connected it to WIFI, and ran the sample project app and my VRTemplate app. After launching them multiple times, both failed to load the Scene, same as before. Disappointed, I went back to my desk to continue working offline. The headset had lost its Boundary, so I had to create a new one. I launched my test app, and voila, the Scene suddenly loaded. I reinstalled the app to start over fresh and see if I would need to go back to the lab and get online or recreate the Boundary again, but the Scene loaded fine without having to resort to any tricks. So not exactly sure which action fixed the problem, but I'm guessing it was launching the app while connected to the internet. Hopefully my journey here can help some other poor soul out there. 🙂
I appreciate you helping me think through this. It was very helpful!
04-11-2024 07:38 AM
Super sweet! That's great. I'm not sure about the connected to internet thing though, but I can comment that sometimes my app on the headset wont even start unless I'm inside my boundary. Doesn't sound like the same issue since your app would start but not load the scene but maybe? Anyhow, good job getting it worked out.
05-10-2024 05:45 AM
After requesting permission, add node "launch scene capture" connected to MRUKSubsystem. This will trigger Scene API on OS of the headset and will ask you if you want to modify your space setup. When you return to your app, Spatial related stuff will work without restarting the app. This is not optimal but it works.