cancel
Showing results for 
Search instead for 
Did you mean: 

Running the Unity Editor Playback on Virtual Desktop

Grirvaldr
Honored Guest
Hello all!

I have been working on making myself completely remote with my VR work. I have managed to decouple everything to a remote system via Parsec and Virtual Desktop (w/ sideloaded add-on) save for one thing. I am trying to make it so that when I press the Play button in Unity, it will go to my Quest like it can with any SteamVR game.

Is there a way to maybe get SteamVR to notice Unity playback and allow for passthrough?

Any suggestions are helpful!
2 REPLIES 2

BeardOrDie
Honored Guest

I know this is an old post, but I had this issue over the last few days. I still have Play Mode crashing using Oculus Link and Air Link. But here's what IS working: I purchased the Virtual Desktop app for Quest 2, and by default the Unity editor's play button will not trigger full screen VR, but the following forum post has instructions that worked for me with an admittedly hacky batch file to launch everything in the right order using the command line and specific command line argument(s). When I exit all programs, then use this Batch file, it will launch Virtual Desktop Streamer on my PC and wait for me to put the headset on and start the Virtual Desktop app on my Quest 2. Once the Virtual Desktop app on my Quest 2 connects to my PC, it will see the Unity editor which it has just launched. Then I can press Edit -> Play (for some reason the actual Play button still won't click) and it will enter Play Mode and correctly go fullscreen VR with spatialized audio, controllers, etc. I'm also using VRIF as the author of the post is, but I don't think that's related to why this is working. Best part of this is that it's completely wireless, no Link cable needed, and more performant than out-of-the-box Air Link in my experience. Here's the post URL: https://forum.unity.com/posts/6792485/

 

Of course, I hope that upcoming software updates will refine and stabilize the roundtrip workflow for Unity development, without the need for command line batch files and the third party Virtual Desktop app.

Everything worked when I tested the solution in the post using Unity 2020.3.16f1 and a default Sample VR Project, but I can't get this to work for my own project. 

 

When I hit the Unity preview button inside the Oculus VD, the scene is not playing on my headset, but stays on the Unity preview window and headset tracking isn't working.

 

I'm using Unity 2020.3.27f1 and Oculus integration, with OVRCameraRig set up in my scene.

When I build the project to my Oculus using cable everything works, so I'm not sure that the problem is with my project settings.

 

Can you please help?

 

**

Procedure

  1. !!! Neither launch Oculus nor Steam VR and make sure Unity Hub and all your Unity instances are closed!!!
  2. PC: Launch Virtual Desktop Streamer
  3. Quest 2: Start Virtual Desktop app and connect with PC (PC and Quest 2 have to be on the same Wifi!)
  4. Execute this command in cmd.exe (make sure to adapt the paths!)
    "C:\Program Files\Virtual Desktop Streamer\VirtualDesktop.Streamer.exe" "C:\Program Files\Unity\Hub\Editor\2020.2.2f1\Editor\Unity.exe" -projectpath "C:\Repos\proj-stardew-vr-health -cloudEnvironment"

    Hint: the parameter [-cloudEnvironment] is needed, as otherwise, Unity won't accept input from the Quest (via Virtual Desktop) the first time. So you would have to close Unity and start it via the command again
  5. Inside Quest 2 press Unity's Play-button (Make sure you have a scene open where the XR rig is set up correctly)

**