v0.6.0
Upgrade to Dear ImGui v1.92.5 (docking branch), adjust FFI and safe APIs for new return-by-value helpers, and refresh all C API submodules.
Added
-
Backends
- New
dear-imgui-sdl3backend crate:- Thin, safe wrapper around upstream
imgui_impl_sdl3.cpp+imgui_impl_opengl3.cpp. - Provides SDL3 platform integration for Dear ImGui and OpenGL3 rendering.
- Includes an SDL3 + OpenGL3 multi-viewport example:
cargo run -p dear-imgui-examples --bin sdl3_opengl_multi_viewport --features multi-viewport
- SDL3 + WGPU is supported via the Rust WGPU backend (
dear-imgui-wgpu) with a basic example:cargo run -p dear-imgui-examples --bin sdl3_wgpu- Multi-viewport remains disabled for WebGPU, matching upstream
imgui_impl_wgpuwhich does not yet support multi-viewport.
- Thin, safe wrapper around upstream
dear-imgui-glow:- Experimental multi-viewport support mirroring the upstream OpenGL3 renderer backend:
- Adds a
multi_viewporthelper module andmulti_viewport::enable(&mut GlowRenderer, &mut Context)API. - Clears secondary viewports using a configurable clear color via
GlowRenderer::set_viewport_clear_color. - Uses Dear ImGui’s
ImGuiPlatformIO::Renderer_RenderWindowcallback in the same way asimgui_impl_opengl3.
- Adds a
- When combined with SDL3 platform backend, provides a pure-Rust SDL3 + Glow multi-viewport stack:
- New helper
dear-imgui-sdl3::init_platform_for_openglto initialize only the SDL3 platform backend (no C++ OpenGL3 renderer). - New example using SDL3 + Glow multi-viewport:
cargo run -p dear-imgui-examples --bin sdl3_glow_multi_viewport --features multi-viewport,sdl3-backends
- New helper
- Experimental multi-viewport support mirroring the upstream OpenGL3 renderer backend:
- New
-
dear-imgui-rs 0.6.0
- New drag/drop flag
DragDropFlags::ACCEPT_DRAW_AS_HOVERED, wrappingImGuiDragDropFlags_AcceptDrawAsHovered. - New style color
StyleColor::DragDropTargetBg, exposingImGuiCol_DragDropTargetBg. - Experimental WebAssembly font atlas support behind
wasm-font-atlas-experimentalfeature (import-style provider only; APIs and behaviour may change).
- New drag/drop flag
-
dear-imgui-sys 0.6.0
- Updated to Dear ImGui v1.92.5 (docking branch).
- Updated cimgui submodule to
1.92.5dock(Dear ImGuiv1.92.5-docking). - Regenerated FFI bindings, including new enums/fields added in 1.92.5.
- Added pregenerated wasm bindings (
wasm_bindings_pregenerated.rs) importing from moduleimgui-sys-v0for import-style WASM builds.
-
Tooling / xtask
xtask wasm-bindgen imgui-sys-v0generates import-style wasm bindings fordear-imgui-syswithwasm-bindgen-cli 0.2.105.xtask web-demobuilds thedear-imgui-web-demowasm example, patches the wasm to import memory fromenv, and injects shared memory wiring into the JS glue.xtask build-cimgui-providerbuilds an Emscripten-basedimgui-sys-v0provider (imgui-sys-v0.js+.wasm) and injects an import map mappingimgui-sys-v0to./imgui-sys-v0-wrapper.js.
Changed
-
Adjusted FFI signatures and safe wrappers to follow upstream return-by-value helpers introduced in 1.92.x:
- Functions such as
igGetMousePos,igGetMouseDragDelta,igGetWindowPos/Size,
igGetCursorPos/CursorScreenPos/CursorStartPos,igGetItemRectMin/Max/Sizeand
igGetContentRegionAvailnow returnImVec2instead of writing through out-parameters. - Docking helpers now return
ImRectdirectly (e.g.ImGuiDockNode_Rect). - Text helpers such as
ImFont_CalcTextSizeAandigCalcTextSizenow return anImVec2result. - All affected safe APIs in
dear-imgui-rshave been updated to transparently use the new signatures.
- Functions such as
-
Inherited all bug fixes and behavior changes from Dear ImGui v1.92.5, including improved drag/drop,
navigation, InputText, and table behavior (see upstream release notes for details). -
Updated C API submodules for extensions to latest branches and regenerated bindings:
dear-implot-sys(cimplot, ImPlot C API).dear-implot3d-sys(cimplot3d, ImPlot3D C API).dear-imnodes-sys(cimnodes, ImNodes C API).dear-imguizmo-sys(cimguizmo, ImGuizmo C API).dear-imguizmo-quat-sys(cimguizmo_quat, ImGuIZMO.quat C API).- Safe wrappers for these crates have been adjusted as needed to match any signature changes reported by bindgen.
Multi-viewport notes (0.6.x)
- SDL3 + OpenGL3:
- Multi-viewport is provided by upstream C++ backends (
imgui_impl_sdl3.cpp+imgui_impl_opengl3.cpp) and considered stable for desktop use. - The
sdl3_opengl_multi_viewportexample shows how to:- Drive Dear ImGui via the official SDL3 platform backend;
- Render a user-provided OpenGL texture inside an ImGui window (
Game View) that can be dragged to secondary OS windows.
- Multi-viewport is provided by upstream C++ backends (
- SDL3 + Glow (experimental):
- Uses SDL3 platform backend (
dear-imgui-sdl3) + Rust Glow renderer backend (dear-imgui-glow). - Platform responsibilities (window creation, GL context switching, swap buffers) remain in the C++ SDL3 backend; rendering of all viewports is handled by
GlowRendererviamulti_viewport::enable. - The
sdl3_glow_multi_viewportexample demonstrates this stack:cargo run -p dear-imgui-examples --bin sdl3_glow_multi_viewport --features multi-viewport,sdl3-backends
- This path is intended as an experimental native OpenGL alternative to the C++
imgui_impl_opengl3renderer.
- Uses SDL3 platform backend (
- SDL3 + WGPU:
- Uses the SDL3 platform backend (
imgui_impl_sdl3) + Rust WGPU renderer (dear-imgui-wgpu). - The
sdl3_wgpuexample demonstrates SDL3 + WGPU integration (single window); multi-viewport remains disabled on this route for WebGPU, matching upstreamimgui_impl_wgpuwhich does not yet implement multi-viewport.
- Uses the SDL3 platform backend (
- Winit + WGPU:
- Experimental multi-viewport support exists in
dear-imgui-winit::multi_viewport+dear-imgui-wgpu::multi_viewport, and is exercised by themulti_viewport_wgpuexample. - This path is not supported in 0.6.x for production use and is known to be unstable on some platforms (especially macOS/winit).
- The example is kept as a testbed to illustrate the architecture:
- the platform backend owns OS windows and fills
ImGuiPlatformIOcallbacks (create/destroy/update window, event routing); - the renderer backend installs
Renderer_CreateWindow/Renderer_RenderWindow/Renderer_SwapBufferscallbacks to create per-viewport render targets and draw ImGui content into them.
- the platform backend owns OS windows and fills
- Experimental multi-viewport support exists in
Version Updates
All crates in the workspace have been upgraded to 0.6.0 due to the Dear ImGui v1.92.5 upgrade and C API refresh.
Core:
dear-imgui-sys→ 0.6.0dear-imgui-rs→ 0.6.0
Backends:
dear-imgui-wgpu→ 0.6.0dear-imgui-glow→ 0.6.0dear-imgui-winit→ 0.6.0
Application Framework:
dear-app→ 0.6.0
Extensions:
dear-imnodes→ 0.6.0 (+dear-imnodes-sys→ 0.6.0)dear-implot→ 0.6.0 (+dear-implot-sys→ 0.6.0)dear-implot3d→ 0.6.0 (+dear-implot3d-sys→ 0.6.0)dear-imguizmo→ 0.6.0 (+dear-imguizmo-sys→ 0.6.0)dear-imguizmo-quat→ 0.6.0 (+dear-imguizmo-quat-sys→ 0.6.0)dear-file-browser→ 0.6.0