| Crates.io | dear-imgui-wgpu |
| lib.rs | dear-imgui-wgpu |
| version | 0.8.0 |
| created_at | 2025-09-13 17:33:54.878392+00 |
| updated_at | 2026-01-02 18:02:14.070247+00 |
| description | WGPU renderer backend for dear-imgui-rs (native + WebAssembly) |
| homepage | https://github.com/Latias94/dear-imgui-rs |
| repository | https://github.com/Latias94/dear-imgui-rs |
| max_upload_size | |
| id | 1837952 |
| size | 312,881 |
WGPU renderer for Dear ImGui.
use dear_imgui_rs::Context;
use dear_imgui_wgpu::{WgpuRenderer, WgpuInitInfo, GammaMode};
// device, queue, surface_format prepared ahead
let mut renderer = WgpuRenderer::new(WgpuInitInfo::new(device, queue, surface_format), &mut imgui)?;
// Optional: unify gamma policy across backends
renderer.set_gamma_mode(GammaMode::Auto); // Auto | Linear | Gamma22
// per-frame
renderer.render_draw_data(&imgui.render(), &mut render_pass)?;
GammaMode::Auto: picks gamma=2.2 for sRGB targets and 1.0 for linear targets.Linear (1.0) or Gamma22 (2.2).| Item | Version |
|---|---|
| Crate | 0.8.x |
| dear-imgui-rs | 0.8.x |
| wgpu | 28 (0.8.x), 27 (0.7.x) |
See also: docs/COMPATIBILITY.md for the full workspace matrix.
webgl/webgpu features mapped to wgpu features).webgl: forwards to wgpu/webgl (WASM + WebGL)webgpu: forwards to wgpu/webgpu (WASM + WebGPU)Pick exactly one of webgl or webgpu for browser targets; for native leave both off.