WebXRDefaultExperience Icon error shows Error when clicked

Using the WebXRDefaultExperience. the VR button shows up in the lower right of my screen because I have the WebXR API Emulator installed in my browser, Edge and Chrome on Windows 11.
When I click on the Button, the word Error is display over the button and the experience does not go into XR.
image
what could be causing this and how to debug?
Thanks,
Michael

Summoning @RaananW the WebXR djinn :slight_smile:

2 Likes

there is nothing coming out of the console output that would provide a hint.
except this: when the scene initializes.
WebXR emulator extension overrides native WebXR API with polyfill.

Do you have the emulator open in the console? Can you make sure you have selected a device that fits the current requested session (vr or ar) and that it is running correctly?

Can I also ask - what scene are you trying to run? Any custom features that you are trying to initialize?

Also - hovering over the button should show you the error (it should be in the title of the image).

I am using BABYLON.GUI heavily but turn it off when going into VR -
I have tried all of the devices in the WebXR emulator.

the error message is: Error entering XR session - immersive-vr - local-floor

I think I figured it out - an uncaught exception in my code entering the VR state.

1 Like

Was it the exception, then? :smiley:

This is the promise failing. I’ll see what we can do in logging the rejection more clearly. It should be at least logging it in the console. Can you share the code that failed so I will see what went wrong?

1 Like