Forum Discussion
lukasseiler
12 years agoHonored Guest
NetworkView Camera Control
Hi,
I wanted to implement a solution for displaying an undistorted image of the Rift's view for other people to see what the person wearing the Rift is seeing.
Reading through different posts, it seems the best way to this in Unity is to set up a NetworkClient that is in "SpectatorMode" and thus only receives the camera transforms of the Rift (which is running on a seperate machine).
Being quite new to Unity I watched different tutorials on networking and I'm able to set up a simple scene where a camera follows a standard unity firstperson controller via network. - yay.
When I try to adapt that same scene for the Rift it doesn't work at all. It seems like no controls are being updated via NetworkView.
Any ideas on how to achieve this or anything similar?
Thanks!
Edit:
I think i should ask the question differently:
Right now I export the same Scene twice, once with the OVRPlayerController enabled, once disabled.
I do this to get the different views). It seems like as soon as I disable the OVRPlayerController for the "spectator" version, the transforms of the PlayerController dont update. Which makes perfect sense.
But I have no idea how to "choose" between the Rift-View and a normal camera without disabling the OVRPlayerController.
Any help appreciated!
I wanted to implement a solution for displaying an undistorted image of the Rift's view for other people to see what the person wearing the Rift is seeing.
Reading through different posts, it seems the best way to this in Unity is to set up a NetworkClient that is in "SpectatorMode" and thus only receives the camera transforms of the Rift (which is running on a seperate machine).
Being quite new to Unity I watched different tutorials on networking and I'm able to set up a simple scene where a camera follows a standard unity firstperson controller via network. - yay.
Any ideas on how to achieve this or anything similar?
Thanks!
Edit:
I think i should ask the question differently:
Right now I export the same Scene twice, once with the OVRPlayerController enabled, once disabled.
I do this to get the different views). It seems like as soon as I disable the OVRPlayerController for the "spectator" version, the transforms of the PlayerController dont update. Which makes perfect sense.
But I have no idea how to "choose" between the Rift-View and a normal camera without disabling the OVRPlayerController.
Any help appreciated!
2 Replies
Replies have been turned off for this discussion
- MikeFTrusteeJust a thought, but instead of having the entire player controller disabled at startup try having the left and right camera's disabled.
This way you should still get orientation and positional information from the camera controller, but no image output. - lukasseilerHonored GuestThanks Mike!
It's weird, I had tried what you suggested via script and it didn't work, after reading your suggestion I tried exporting two versions again by manually disabling only the camera component within the left and right camera (to keep the OVRcamera script still active) and it works like a charm!
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
- 8 months ago
- 3 years ago