Skip to content
OpenVR bindings for rust.
Rust
Branch: master
Clone or download
Pull request Compare This branch is 7 commits behind rust-openvr:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
examples
src
.gitignore
.travis.yml
Cargo.toml
LICENSE.md
Readme.md

Readme.md

rust-openvr

Build Status Join the chat at https://gitter.im/rust-openvr/rust-openvr

A high-level binding for OpenVR 1.0.10.

API documentation

High-level documentation can be found at the OpenVR wiki.

Using rust-openvr

Requirements

openvr-sys needs cmake and a C++ compiler so that it can compile and statically link the OpenVR client library.

Windows

Upstream OpenVR does not support MinGW. You must use an MSVC-targeted rust toolchain and C++ compiler.

Initializing

extern crate openvr;

fn main() {
    // Initialize OpenVR
    let context = unsafe { openvr::init(openvr::ApplicationType::Scene) }.unwrap();

    // accessing subsystems
    let system = context.system().unwrap();

    // ..
}

Examples

See examples/test.rs for a more detailed example.

You can’t perform that action at this time.