cancel
Showing results for 
Search instead for 
Did you mean: 

Converting a 5cm head movement into an arbitrarily large/small movement in-game

Anonymous
Not applicable
Hi,

I'm really new to developing games for the Oculus Rift using Unity so I don't really know what is and isn't possible, but I was just wondering if it would be possible to multiply the motion of a user's head in order to convert a 5cm movement to the left into an arbitrarily long/short movement in the same direction? The reason I'm asking is that I'm attempting to make a god game for a university project that will allow players to lean into the game world in order to observe the lives of their worshippers close-up and the current scale of the game means that the 1:1 replication of motion doesn't do much.

I honestly have no idea if this is something that can be easily changed using the standard Unity VR setting or if I'll have to write my own scripts to handle everything. Any help with this issue would be appreciated, thanks!
3 REPLIES 3

Anonymous
Not applicable
A rude way of doing this is to change the IPD on the fly. EDIT misunderstood question : E

vrdaveb
Oculus Staff
A much more comfortable way to do this is to make the Camera a child of another GameObject -- let's call it the tracking space object -- and then change the position and/or scale of that object. In the Oculus Utilities for Unity, we have a prefab called OVRCameraRig that includes a tracking space object. Anytime I need to change the head pose or scale each frame, I write a script with a handler for OVRCameraRig's UpdatedAnchors event, which fires at the right time to avoid stuttering or feedback due to Unity's tracking updates. There have been some other threads on this, such as https://forums.oculus.com/community/discussion/comment/338568#Comment_338568.

Anonymous
Not applicable

vrdaveb said:

A much more comfortable way to do this is to make the Camera a child of another GameObject -- let's call it the tracking space object -- and then change the position and/or scale of that object. In the Oculus Utilities for Unity, we have a prefab called OVRCameraRig that includes a tracking space object. Anytime I need to change the head pose or scale each frame, I write a script with a handler for OVRCameraRig's UpdatedAnchors event, which fires at the right time to avoid stuttering or feedback due to Unity's tracking updates. There have been some other threads on this, such as https://forums.oculus.com/community/discussion/comment/338568#Comment_338568.


Awesome, thanks. I'll give it a look when I have a chance to work on my game further.