All Projects → ChristophHaag → openvr_api-libre

ChristophHaag / openvr_api-libre

Licence: other
Very early proof of concept implementation of libopenvr_api on top of OpenHMD or OSVR. Not useful for running anything but hellovr_opengl and getting some undistorted output.

Programming Languages

C++
36643 projects - #6 most used programming language
c
50402 projects - #5 most used programming language
CMake
9771 projects

Projects that are alternatives of or similar to openvr api-libre

Simple-OpenVR-Driver-Tutorial
A sample OpenVR Driver for you to learn from
Stars: ✭ 157 (+881.25%)
Mutual labels:  openvr
Revive
Play Oculus-exclusive games on the HTC Vive or Valve Index, scroll down for downloads and installation instructions.
Stars: ✭ 3,151 (+19593.75%)
Mutual labels:  openvr
MixedRealityToolkit
Evergine.MRTK provides a set of components and features to accelerate cross-platform XR application development in Evergine.
Stars: ✭ 32 (+100%)
Mutual labels:  openvr
thedarkmodvr
VR support for The Dark Mod
Stars: ✭ 49 (+206.25%)
Mutual labels:  openvr
TJUCam
SteamVR Compatible Motion Controller with ESP8266 and Raspberry Pi
Stars: ✭ 29 (+81.25%)
Mutual labels:  openvr
Alvr
ALVR is an open source remote VR display for Gear VR and Oculus Go. With it, you can play SteamVR games in your standalone headset.
Stars: ✭ 1,774 (+10987.5%)
Mutual labels:  openvr
vr-python-quickstart-hg1
VR Headset Controller Tutorial, get started with virtual reality in Python
Stars: ✭ 29 (+81.25%)
Mutual labels:  openvr
IMU-VR-Full-Body-Tracker
Inertial Measurement Unit (IMU) based full body tracker for Steam VR.
Stars: ✭ 46 (+187.5%)
Mutual labels:  openvr
openvr-input-recorder
🔴 Record and ▶️ playback OpenVR device tracking/input data
Stars: ✭ 20 (+25%)
Mutual labels:  openvr
hobo vr
SteamVR driver prototyping tool
Stars: ✭ 44 (+175%)
Mutual labels:  openvr
EasyOpenVRUtil
EasyOpenVRUtilは、Steam VR for Unityのちょっと足りないところを埋め合わせるためのライブラリです。特に、コントローラやトラッカーの座標を直接取得したり、非VRだけど位置情報は使いたいといった用途に向いています。その他あると便利な機能も実装しています。
Stars: ✭ 37 (+131.25%)
Mutual labels:  openvr
orkid
Orkid Media Engine (C++/Lua/Python3/Linux/MacOs/OpenVR/Qt5)
Stars: ✭ 20 (+25%)
Mutual labels:  openvr
zephyr
Mirror Android notifications to VR
Stars: ✭ 78 (+387.5%)
Mutual labels:  openvr
openvr widgets
SteamVR overlay widgets
Stars: ✭ 20 (+25%)
Mutual labels:  openvr
TurnSignal
An anti-cable-twisting management utility for SteamVR.
Stars: ✭ 73 (+356.25%)
Mutual labels:  openvr
SlicerVirtualReality
A Slicer extension that enables user to interact with a Slicer scene using virtual reality.
Stars: ✭ 70 (+337.5%)
Mutual labels:  openvr
Mixedrealitytoolkit Unity
Mixed Reality Toolkit (MRTK) provides a set of components and features to accelerate cross-platform MR app development in Unity.
Stars: ✭ 4,817 (+30006.25%)
Mutual labels:  openvr
Joy2OpenVR
Interface to OpenVR Input Emulator to translate any Direct Input controllers commands into VR Controller commands
Stars: ✭ 25 (+56.25%)
Mutual labels:  openvr
KinectToVR
KinectToVR EX (Official)
Stars: ✭ 163 (+918.75%)
Mutual labels:  openvr
godot-openvr-asset
Godot asset for the openvr module
Stars: ✭ 52 (+225%)
Mutual labels:  openvr

What is this

The aim is to implement libopenvr_api.dll/libopenvr_api.so on top of a libre runtime like OpenHMD or OSVR SDK.

Games and applications using the OpenVR API ship the libopenvr_api.so library or rely on it to be present in /usr/lib/.

Valve's libopenvr_api.so is a wrapper. It loads the implementation of the OpenVR classes from their closed source and x86-only SteamVR runtime. However, libopenvr_api is documented and "open source", so other backends than SteamVR can be implemented like OpenHMD or OSVR.

Once this library is finished, the libopenvr_api shipped in any SteamVR application or game can be swapped out with this one and the application can be used with only the OSVR or OpenHMD drivers, Steam and SteamVR are not needed.

Status

Note: hellovr_opengl draws upside down in its preview window. That's not a bug of this libopenvr_api, hellovr_opengl upstream should fix that.

OpenHMD

Rendering

Creates fullscreen window with the HMD's resolution via SDL and displays the textures side by side.

Orientation Tracking

The HMD is hardcoded as deviceindex 0, controller support has to wait until the HMD tracking works.

Three matrices are used by hellovr_opengl:

General setup: GetProjectionMatrix() is glm::perspective() GetEyeToHeadTransform() - currently identity matrix

HMD orientation that gets updated every frame: WaitGetPoses() - hmd quaternion converted to matrix

TODO

  • apply OpenHMD's distortion shader before displaying the textures
  • Check all the matrices (I think the cubes are too big but could be coincidence)
  • Controllers, wait for OpenHMD's controller API

OSVR

Rendering

not much yet

Orientation Tracking

TODO

Check positional tracking in WaitGetPoses.

How to use and hack it

git clone --recursive https://github.com/ChristophHaag/openvr_api-libre
cd openvr_api-libre
cmake .
make -j12
./hellovr_opengl

hellovr_opengl is linked to libopenvr_api.so in the same directory, no special setup needed when you already have it in /usr/lib.

You can customize the build with cmake -DOPENHMD_LIBOPENVR=OFF and cmake -DOSVR_LIBOPENVR=OFF. At runtime you can choose one of the backends with the environment variable OPENVR_BACKEND=OPENHMD or OPENVR_BACKEND=OSVR.

openvr_api_public.cpp is the main file of the library. The implementation of the classes is in openvr_osvr.h and openvr_openhmd.h. Not all classes and many methods are not implemented.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].