cancel
Showing results for 
Search instead for 
Did you mean: 

Camera zoom with Unity built-in VR

jules43
Explorer
With the old Oculus integration I have been applying an adjustment to the OVRCameraRig camera field of views to handle a zoom function. Simulating something like the player using binoculars.

I've upgraded to Unity 5.2.1 but if I switch to using the built-in integration with the OVR utilities, there doesn't seem to be a way to adjust the camera FoV as it is readonly and bound to the optics of the headset.

How can I implement camera zoom with the new integration?

Thanks

Jules
5 REPLIES 5

vrdaveb
Oculus Staff
Changing the FOV isn't supported because it breaks the correspondence between the user's FOV, head motion, and IPD, which will always cause discomfort. To implement zoom I would recommend one of the following options:
1) Render to a texture with a custom FOV and then show the texture in binoculars, etc. @drash did this in his Telescopic app: https://www.youtube.com/watch?t=1&v=jIHfTHGSFcY
2) Dolly the camera toward the content. @drash has also done this in Ethereal Village: https://www.youtube.com/watch?v=evarhDDR9zI

kideternal
Protege
"vrdaveb" wrote:
Changing the FOV isn't supported because it breaks the correspondence between the user's FOV, head motion, and IPD, which will always cause discomfort. To implement zoom I would recommend one of the following options:
1) Render to a texture with a custom FOV and then show the texture in binoculars, etc. @drash did this in his Telescopic app: https://www.youtube.com/watch?t=1&v=jIHfTHGSFcY
2) Dolly the camera toward the content. @drash has also done this in Ethereal Village: https://www.youtube.com/watch?v=evarhDDR9zI

While I appreciate this response and the intention behind it (protecting the wearer from discomfort), I respectfully disagree with the decision on grounds of it "will always cause discomfort". As proof I offer how both solutions you propose effectively modify the FOV and tracking in direct contradiction to your previous statement. Truly, if handled correctly, adjusting the FOV is a very useful feature that does not introduce anything uncomfortable for the wearer. Too often I see people blindly parroting this stance without having actually experimented with it themselves.

I have an exciting and innovative telescope in my upcoming title that I'm quite proud of. It is an absolute joy to use and not in the slightest bit uncomfortable for users. The move to native-mode w/0.7 made the method I had employed no longer possible, so I had to rework it into something similar to your example #1 above. The end result is almost as nice as the original (I'm happy to say), but has the unfortunate side-effect of reduced performance and a lot of extra code due to the overhead of an additional camera and corresponding RenderTexture(s).

I know that decisions like this get made from a place of good intentions, but in this case it was a short-sighted mistake. People easily use things like telescopes and binoculars in the real world. Why can't they in VR?

Constellation
Expert Protege
I'm in a situation fairly similar to @kideternal and I'm really hoping you'll reconsider and expose some way to control the zoom. In situations such as ours it won't cause discomfort and it hurts to have to pay the performance cost of an extra RTT camera. There's a lot of mistakes that developers can make that might cause discomfort but that's no reason to take away all their sharp knives and leave them with only spoons! :smile: 

ThatOtherVRGuy
Protege
Any update on this?

I wonder this too. I'm really disappointed in this developer-unfriendly stance on the part of Oculus. Or whatever they call themselves today.