rust-webvr 0.5.1

Safe rust API that provides a way to interact with Virtual Reality headsets and integration with vendor specific SDKs like OpenVR and Oculus. The API is inspired on the easy to use WebVR API but adapted to Rust design patterns
Documentation
extern crate gl_generator;

use std::env;
use std::fs::File;
use std::path::Path;
use gl_generator::{Registry, Api, Profile, Fallbacks};

fn main() {

    if !cfg!(feature = "googlevr") {
        return;
    }

    let dest = env::var("OUT_DIR").unwrap();

    let mut file = File::create(&Path::new(&dest).join("gles_bindings.rs")).unwrap();

    // GLES 2.0 bindings
    let gles_reg = Registry::new(Api::Gles2, (3, 0), Profile::Core, Fallbacks::All, []);
    gles_reg.write_bindings(gl_generator::StaticGenerator, &mut file)
            .unwrap();
}