I’m not sure how I managed this, but the XRSettings.stereoRenderingMode is always set to ‘Multipass’ while testing VR in the Unity Editor. My XR settings include “OpenVR Loader” and “Oculus” with the following:
Oculus PC: Single-pass instanced
Oculus Andriod: Multi-Pass
OpenVR PC: Single-pass instanced
Building the application on PC and Andriod returns the respective stereoRenderingMode, however, when running in the unity editor, the settings are always set to MulitPass. This was not the case until recently (as in it ran as expected).
I know when the application is set to PC in the build settings, the editor uses Single-pass instanced rendering, but the XRSettings value still reads ‘Multipass’. I’m using custom screen space rendering and it would be useful to have this value correct while testing different environments.
I’ve tried reinstalling the XR package, restarting the Editor in both Andriod and PC build states, and multiple combinations of connecting the headset and opening the editor.
In play mode, the editor is using whatever loader is set to be enabled for Standalone build target. That would be where that is coming from depending on what you have enabled for stand alone.
Yes, I am aware. By checking the XRSettings, I know that the device is loaded from the correct target and device. As stated above, the editor will render as expected (“using whatever loader is set to be enabled for Standalone build target”), BUT the XRSettings value still reads ‘Multipass’. The problem isn’t necessarily the rendering, but only with the XRSettings.stereoRenderingMode value in the settings.
I specifically need to know the render mode for specific camera texture manipulation (RenderTextures, Blit, Shaders…).
And what loader is being loaded from standalone? It’s technically the render passes generated by the display subsystem of the provider that is running that determines that value.
Interesting, that’s good to know. I’ve had this problem with:
Oculus PC: using the Oculus Quest 2
OpenVR PC: using the Oculus Quest 2
Again, this wasn’t a problem for a while but eventually got locked.
I’m working on getting the project tested on another computer as is. I suspect this issue was caused sometime around switching from pc to android back to pc, while doing work between each change.