De-Panther / unity-webxr-export

Develop and export WebXR experiences using Unity WebGL
https://de-panther.github.io/unity-webxr-export/
Apache License 2.0
1.04k stars 110 forks source link

Getting started with Oculus in Unity #256

Closed GaryFrewin closed 1 year ago

GaryFrewin commented 1 year ago

Sorry, perhaps a stupid question, but I can't figure it out.

I am trying to give my user the choice of VR or not in my webgl project. Initially, the app loads and they are presented with Scene1, where they can use the app as they always have in a desktop/browser mode.

If they click on a VR button on my unity UI, it takes them to scene 2, where there is a WebXRCameraSet, so I'd like it to launch in the headset. But nothing happens in the Oculus Headset when I go to scene 2.

If I run scene 2 in play mode in Unity, it fires up on the headset. It's just when I build and deploy to my webhost, going to scene 2 doesn't trigger any launch in the headset.

Am I missing something here?

I've tried deploying the VR scene separately and deploying it online. I then use firefox reality from my quest to browse to the page. When I click the launch VR button, the screen shows a sbs view, but it doesn't actually go to VR, it's a square screen with 2 sbs views, and it doesn't move when the headset moves.

Thanks

art3miz18 commented 1 year ago

@GaryFrewin did you see any errors while firing up VR module ? In chrome or Firefox console

As it might actually be memory allocation to load another scene Or maybe headset fails to initialize with WebXR camera set

GaryFrewin commented 1 year ago

Thanks for getting back to me. :)

When I run it on quest 2 from firefox reality, I cannot seem to find the log...

When I run it on quest 2 using link cable / rift, I press the enter VR button on my laptop, the headset starts the loading screen, but then the console on my laptop browser says the following:

Warning: Unrecognised feature requested. Hand Tracking and Could not create session because an unknown error occurred. Here is a screen shot image

Presumably these are the same errors that are preventing it from loading in firefox reality too... perhaps?

I removed hand tracking (although I do need it) in the project manager, and the first error goes away but the second one remains. This occurs on chrome, on firefox the enter VR button is always greyed out.

De-Panther commented 1 year ago

Lot's of related and unrelated issues.

Also, please follow the Getting Started guide and play with the Sample desert scene. It'll help you to better figure out how this package works and pinpoint errors. https://github.com/De-Panther/unity-webxr-export/blob/master/Documentation/Getting-Started.md

De-Panther commented 1 year ago

Closing as there were no new comments in a while