Maintained at https://github.com/OSVR/SteamVR-OSVR
For details, see http://osvr.github.io
For support, see http://support.osvr.com
This is a SteamVR driver for allowing applications written against that API to work with hardware and software running with the OSVR software framework.
Note that despite similar goals, the internal models of the two systems are not the same (in most cases, OSVR has a more flexible, descriptive model), so if you're writing an application from scratch, be sure to evaluate that. This driver exists primarily for compatibility reasons (a bit like the Unity or Unreal integration, but more general), so existing software using the SteamVR system can run on OSVR. OSVR ClientKit itself (along with its wrappers/engine integrations) is and remains the first-class preferred API for working with OSVR.
If you'd just like to try this out with pre-compiled binaries on Windows, the link above contains a compressed file with the 32- and 64-bit builds in it. (Other platforms will have to build from source at this time.) This is not the only way to use the binaries, but it's the simplest way to use them with commercially-released SteamVR games.
The default locations are as follows:
If you accepted defaults, Steam's nested SteamVR directory is installed in
"%ProgramFiles(x86)%\Steam\steamapps\common\SteamVR" - you can paste that into the Windows Run dialog and it should open the right folder. You can also find SteamVR in the Library, Tools section of Steam, right-click it, choose Properties, then Local Files, then "Browse local files..."
Upon extracting the OSVR driver, you'll get a
SteamVR-OSVR directory. Drill down through
SteamVR-OSVR/lib/openvr until you find an
You'll want to drag the
drivers directory you found previously. If you are upgrading from an earlier version of the driver, merge its contents with the existing contents of the
To know if you got it right, do the same Windows Run (or other way of opening a folder by its name) as above, with the path
"%ProgramFiles(x86)%\Steam\steamapps\common\SteamVR\drivers\osvr\bin\win32" instead. (Make changes as appropriate to suit your Steam install location.) If you got it right, you should see a number of files, including one called
In all cases, hook up your hardware and launch OSVR Server first.
"%ProgramFiles(x86)%\Steam\steamapps\common\SteamVR\demo\bin\win32\hellovr_sdl.exe" into the Windows Run dialog and click run to start the SteamVR simple demo app - you should get a command-prompt window with some text, the screen might flicker, then you should get a split-screen display that reacts to the movement of the HMD by changing your view of a world with infinite cubes of test patterns. (You might need to click to bring the demo window to the foreground.)
Real game: You may wish to open the "VRMonitor" - the SteamVR status window, that should be accessible through the Start Menu. At this time, it appears to also launch Steam in VR or "Big Picture" mode, which may or may not be what you want, but you can close that interface and keep the VR Monitor open. It might say "Not Ready", but if you hover over the HMD icon it should say "HMD Connected, but not ready" - that's normal.
Different games have different ways of turning on VR mode - some you right-click on them in Steam and specify in the options to pass
/vr to launch in VR mode. You might find info about this on the Internet - many of these sources are outdated: for example, no command line switch is required for TF2 to run in VR.
In this example, we'll use TF2, which has it accessible in its menu: go to "Options", then "Video" and change "Virtual Reality Mode" to "Enabled". You'll have to save that setting and restart the game before you'll see a new entry on the game's main menu called "Activate Virtual Reality". Selecting "Activate Virtual Reality" should flip the game into VR mode and you're ready to play. (Might be best to use a gamepad, as WASD and mouselook don't go well with VR, the mouselook portion in particular.)
git submodule update --init --recursiveto download the OpenVR SDK.
Use CMake to configure/generate your build. You'll essentially use CMake just as any other project - that is, something like:
mkdir build cd build cmake ..
is a start for the command-line-oriented. Or, if you prefer a GUI, this screencast demonstrates configurating and building with CMake's GUI.
The one detail is that you'll want to add the variable
CMAKE_PREFIX_PATH and set it to the root directories/"prefixes" (semicolon-separated) where the dependency binaries are (the directory that immediately contains bin, include, and so on.)
Another configuration setting you'll want to consider is
CMAKE_INSTALL_PREFIX - you'll probably want to set this to a local directory (like a directory on your desktop), or to the root of a SteamVR/OpenVR tree, since when building the
INSTALL project (VS) or the
install target (all other build systems), the driver will get installed into the
drivers/[platform]/ subdirectory of the install prefix. The system-wide SteamVR install directory on Windows is usually something like
C:/Program Files (x86)/Steam/steamapps/common/SteamVR though install there at your own risk!
Use your native build tool - open the generated Visual Studio solution, run
As mentioned above, the
install target will place the driver binary in a specific directory. If that's not a standard directory, or if you don't re-configure SteamVR/OpenVR to look there, you'll need to copy the driver to such a directory manually.
This project: Licensed under the Apache License, Version 2.0.
Vendored projects included in the source tree:
/vendor/eigen-3.2.4 - Unpacked release from http://eigen.tuxfamily.org/ - header-only library under the MPL2 (a file-level copyleft, compatible with proprietary software), used with the preprocessor definition
EIGEN_MPL2_ONLY to exclude modules with other license from the build.
/vendor/libcxx - Extracted files from libc++ - dual-licensed under the MIT and the University of Illinois "BSD-Like" licenses. See that directory for full copyright, license, and credits.
/vendor/util-headers - Select header files from util-headers - licensed under the Boost Software License v1.0.
/vendor/OSVR-Display - Used for detecting display parameters. Licensed under Apache 2.0.
/vendor/googletest - A unit-test framework. Licensed under the New BSD License.