RenderingPipeline

from geometry to pixels

Using the Oculus Rift on Linux

While there is no official support from Oculus yet, the Rift can be used under Linux:

  • Get the C API from the Oculus forum user ‘nsb’ (posting here), the latest version is 0.0.2
  • After plugin your Rift in, configure the screen (e.g. clone mode, whatever fits your needs), the Rift is just an external 1280*800 monitor (that can also handle FullHD but it will down sample it, I recommend using it at native resolution and oversample via software).
  • After plugging in the USB cable, a new file ( /dev/hidrawN where N is a number depending on what other USB devices you have plugged in) will appear. You need read and write access. A quick&dirty way to do so is sudo chmod 666 /dev/hidraw*, this will give all users read and write access to all devices. Note that you have to do that each time the Rift gets unplugged/replugged. So a better way to do it is to add a rule to your udev settings (check your /etc/udev folder): SUBSYSTEM==”hidraw”,ATTRS{idVendor}==”2833″,ATTRS{idProduct}==”0001″,MODE=”0666″ don’t forget to restart udev via sudo /etc/init.d/udev restart¬†.

You should look into the OpenGL example gltest1.c as this shows how to access the sensors and run the update in a separate thread. Shaders for the distortion can be taken from the official SDKs MacOS X examples.

I noticed that the tracking using the official SDK is smoother than this solution (but as we are talking about different operating systems and different code to access the SDKs, there might be other influences to this), but it’s a way to get started on Linux.

I still hope there will be official support from Oculus soon.

Update 7/3/13: Today Oculus released the Rift SDK version 0.2.3 with native Linux support :-)

, ,

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

*