engine icon indicating copy to clipboard operation
engine copied to clipboard

WebXR error: The WebGL context was not marked as XR compatible.

Open Ramon-ES opened this issue 2 months ago • 2 comments

We are testing our webvr project but get some errors about the project not being marked as XR compatible.

We tested on a Quest 3(S)

Image

Ramon-ES avatar Nov 06 '25 10:11 Ramon-ES

It seems we call makeXRCompatible when the device is restored only, but not initially. We use xrCompatible as option when creating WebGL context .. but I'm not sure that's equivalent.

@Maksims - any thought on this?

mvaligursky avatar Nov 07 '25 14:11 mvaligursky

I believe we are already setting that option on WebGL2 context creation xrCompatible to true. Just checked when launching from Editor, it is passing that flag as supposed to.

Based on WebXR Specs, it is sufficient, and does not require to call explicitly makeXRCompatible, which can lead to context loss if context was initially created on different GPU btw.

I have seen this warning for a long time, and it might be false alarms. Worth having a simple vanilla webgl example with xrCompatible flag, to see if it still throws a warning, if it does - feel free to report that using Quest 3 features - by pressing Meta button 5 times on your controller, and then specify there that it is a Browser/WebXR related.

Maksims avatar Nov 14 '25 15:11 Maksims