When can I select Oculus VR and DirectX 12 and hit the play button without Unity crashing?

,

The title says it all… (You’ll see)

I run the HDRP wizard to resolve any/all conflicts/mistakes in configuration. To enable RayTracing support in the project I need to have DX12 … but if I want to have VR in the project I have to choose to either (well,) not use VR after all or to not use Unity.

Apparently those are the only options. Hmmm… :frowning:

Trying to use DX12 in your project and use Oculus in the same project causes Unity to crash as soon as you hit play. Every time. The only way to NOT crash Unity is to disable the toggle to activate Oculus on startup.

So, as I said above, don’t use VR and then you can use Unity… Or use Oculus and Unity will crash as soon as you hit play (i.e. you can’t use Unity for your VR project) …or don’t use DirectX12 (whether you use RayTracing features or not, just don’t choose DX12 if you want to do VR)

So… TLDR version:
When can I have DirectX12 selected and Oculus installed via the XR manager and NOT have Unity crashing a soon as I hit the play button?

See? Told you the title said it all :wink: :stuck_out_tongue:

Thanks

(P.s. Tried this up to 2020.1)

It might be related - but here the Editor will hard crash occasionally (1 out 10 times) when pressing Play with a VR device connected. I’ve submitted a bug a few times

It was about 1 out of 3 times on Unitys own HDRP Alchemy Lab demo

1 out of 10? I consider you lucky. My VR device is connected all the time and Unity hard crashes 100% of the time.

For us, steps to reproduce:
Start Unity from the HUB, wait for it to load, press Play, close the bug reporting window, repeat.

That is why I started this thread to ask if Unity is aware of this and if they have this on their roadmap of bug fixes or not.

If you have submitted a bug (multiple times, even) then sweet! Now to wait for U2021.1 and we should be good to go! :smile: Thanks

EDIT:
Curious… Since we have a 100% crash ratio and your vary between 10% and 33%, I wonder what’s different between our setups. My project is a clean project I created especially to test HDRP and RayTracing. VR was just an afterthought. Point is, my scene has only a single mesh at the moment and then nothing other than the volumes and VR character proxy thingy.

Are you using the Oculus or OpenVR system? On our side I set it up with Oculus and have a Rift S connected. Would you mind sharing your setup, just out of curiosity? Thanks again

Yes, but most got a response with:
"
If you haven’t tried all the workarounds listed below before, please try them all, since they usually solve these kinds of issues:
-Update your GPU drivers
-Uninstall GeForce Experience
-Disable any app used to monitor framerate
-Uninstall or reinstall NVIDIA Audio drivers
Some users recently reported that turning off Image Sharpening helped with similar crashes:
Steps to disable it:
1. Open the NVIDIA Control Panel, and click on Manage 3D settings.
2. Scroll down the Global Settings tab to Image Sharpening.
3. Select the “Off” option
"

Oculus Rift CV and no special VR plugins outside of the ones that Unity provide. PC is 1080Ti, 32g, i5.