SHARE
TWEET

Untitled

a guest Jan 23rd, 2015 242 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. extern crate gl_generator;    // <-- this is your build dependency
  2. extern crate khronos_api;    // included by gl_generator
  3.  
  4. use std::os;
  5. use std::io::File;
  6.  
  7. fn main() {
  8. let dest = Path::new(os::getenv("OUT_DIR").unwrap());
  9.  
  10. let mut file = File::create(&dest.join("gl_bindings.rs")).unwrap();
  11.  
  12. // This generates bindsings for OpenGL ES v3.1
  13. gl_generator::generate_bindings(gl_generator::GlobalGenerator,
  14.                                 gl_generator::registry::Ns::Gles2,
  15.                                 khronos_api::GL_XML,
  16.                                 vec![],
  17.                                 "3.1", "core", &mut file).unwrap();
  18. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top