Forum Discussion
CasperK
10 years agoHonored Guest
Check if the HMD is being used by Unity.
I'm creating an application that has optional VR support, I started out by just detecting if there's an HMD detected, and if so enabling the needed buttons to the menu.
Then I ran into a problem, when the app is launched through the direct-to-rift mode its only possible to use the Oculus camera rig. The default Unity camera just shows a blue screen, this means I can't use any of the main application in this mode.
This led me to create a simple VR menu to start the VR part that only shows when direct mode is used.
I did this by using
this works fine when direct or extended mode is used, or when the rift is not connected at all. But when the rift is connected in direct mode and the application is started with the default executable(not the direct-to-rift one). It still detects the Rift and that it's in direct mode but I couldn't find a way to check if the HMD is actually on which means that at the moment the VR menu is activated when it shouldn't be.
Is there a way to see if Unity is actually using the rift or if the display is on?
Are there any other methods to launch to the rift when the application is already running?
Then I ran into a problem, when the app is launched through the direct-to-rift mode its only possible to use the Oculus camera rig. The default Unity camera just shows a blue screen, this means I can't use any of the main application in this mode.
This led me to create a simple VR menu to start the VR part that only shows when direct mode is used.
I did this by using
OVRManager.display.isDirectMode
OVRManager.display.isPresent
this works fine when direct or extended mode is used, or when the rift is not connected at all. But when the rift is connected in direct mode and the application is started with the default executable(not the direct-to-rift one). It still detects the Rift and that it's in direct mode but I couldn't find a way to check if the HMD is actually on which means that at the moment the VR menu is activated when it shouldn't be.
Is there a way to see if Unity is actually using the rift or if the display is on?
Are there any other methods to launch to the rift when the application is already running?
Replies have been turned off for this discussion
Quick Links
- Horizon Developer Support
- Quest User Forums
- Troubleshooting Forum for problems with a game or app
- Quest Support for problems with your device
Other Meta Support
Related Content
- 3 years ago