#renderer #direct-x #11 #imgui #imgui-rs

imgui-dx11-renderer

DirectX 11 renderer for the imgui crate

7 unstable releases

0.8.0 May 7, 2022
0.7.0 Apr 8, 2021
0.2.1 Oct 3, 2020
0.2.0 Sep 25, 2020
0.1.1 Jul 21, 2020

#446 in Graphics APIs

MIT license

29KB
556 lines

imgui-dx11-renderer

Documentation Version

DirectX 11 renderer for imgui-rs.

Usage

let device: ID3D11Device = ...;
let imgui: imgui::Context = ...;
let mut renderer = imgui_dx11_renderer::Renderer::new(&mut imgui, &device).expect("imgui dx11 renderer creation failed");

// rendering loop

let ui = imgui.frame();

// build your window via ui here
...

// then to render call
renderer.render(ui.render()).expect("imgui rendering failed");

The renderer backs up and reapplies the majority of the d3d11 rendering state when invoked.

Documentation

The crate is documented but imgui-rs doesn't currently build on docs.rs for the windows target. Due to this one has to either build it themselves or look into the source itself.

License

Licensed under the MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)

Dependencies

~166MB
~2.5M SLoC