Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

The Rust API

The nsi crate provides Rust wrappers for the ɴsɪ API. These are based on the low-level wrapper crate nsi-sys that contains autogenerated bindings on top of nsi.h.

Creating a Context

The core of these wrappers is the Context struct. Its construction triggers dynamic linking with the renderer.

#![allow(unused)]
fn main() {
let ctx = nsi::Context::new(None)?
}