cancel
Showing results for 
Search instead for 
Did you mean: 

Need to disable movement completely

virtualroadside
Honored Guest
Here's what we're trying to do:

We've mounted a physical camera device on the oculus, and we just want to show the output of the camera on a texture on the scene, and overlay various indicators/whatever on the scene. So we've got that working nicely, but the camera rig keeps changing its position when the user moves their head -- which is definitely not what we want (since it's showing the outside camera output... don't need it).

Basically, we don't want it to be a VR headset right now, just want the oculus to be a nice passthrough display.

Using unity pro and the latest sdk... 0.4.3 I think?

I've seen previous suggestions to disable the UpdateAnchors() function, but that just makes the game view shake a LOT. Using the various options on the rig doesn't seem to make any difference either (disable position tracking, etc). Any thoughts on how to do this?
83 REPLIES 83

cybereality
Grand Champion
Are you trying to disable just position or both position and orientation?

virtualroadside
Honored Guest
I would like to disable both.

The camera in the scene should stay completely stationary, and only look in the direction that it was originally placed.

cybereality
Grand Champion
OK, so open OVRCameraRig.cs and add this near the top of the class definition (around line 59):

public bool disableTracking = false;


Then at the beginning of UpdateAnchors() (around line 102) add:

if(disableTracking) return;


Now, in the Unity inspector, click the disable tracking check box on the OVRCameraRig. You will also need to uncheck time warp in the OVRManager component on the OVRCameraRig.

UnityNoTrack.jpg

Hope that helps.

andrewtek
Expert Protege
Off Topic, but when did the attachment feature start working?
If it was just enabled... thanks!

cybereality
Grand Champion
The attachment thing was fixed maybe a month ago.

virtualroadside
Honored Guest
Thanks for the response. I don't have the oculus with me now, but I'll try it the next time I'm near it.

However, I definitely *did* comment out UpdateAnchors, and it didn't seem to fix the problem (I had the jitter problem instead). But I tried a lot of things, and it's possible that I had tried it without disabling TimeWarp/etc.

cybereality
Grand Champion
Yes, you have to disable timewarp to avoid the jumpiness when you don't have tracking enabled.

virtualroadside
Honored Guest
Sorry for the delay, but this fixed the problem. Thanks so much!

cybereality
Grand Champion
Great!