Expand description
Experimental Bevy-native backend for dear-imgui-rs.
This crate is the Bevy-side integration point for the Bevy Native Backend workstream. It is not
a wrapper around dear-imgui-winit or dear-imgui-wgpu: Bevy owns windows, input, WGPU device
state, render schedules, and camera targets. The backend owns only the Bevy plugin/resources that
adapt those systems to Dear ImGui.
§Compatibility and gates
The first proof target is Bevy 0.19.0-rc.2, which declares Rust 1.95.0. The root
dear-imgui-rs workspace currently remains on Rust 1.92, so this crate has a dedicated
rust-version = "1.95.0" and should be validated with an explicit Bevy gate, for example:
cargo +stable check -p dear-imgui-bevy --no-default-features
cargo +stable check -p dear-imgui-bevy --features render
cargo +stable check -p dear-imgui-bevy --target wasm32-unknown-unknown --no-default-features
cargo +stable check -p dear-imgui-bevy --target wasm32-unknown-unknown --features render
cargo +stable nextest run -p dear-imgui-bevyCore workspace gates should not silently rely on this crate until the repository-wide MSRV is
intentionally raised or CI has a dedicated Rust 1.95+ Bevy lane. The crate currently compiles
on wasm32-unknown-unknown for both the core and render feature sets; mobile targets remain a
platform-specific follow-on if a future Bevy target train needs a dedicated gate.
The crate also exposes configure_example_context for the shared example/editor ImGui setup
pattern so the backend examples do not repeat the same initialization boilerplate.
§Multi-viewport status
ImguiBackendConfig::multi_viewport records an explicit request for Dear ImGui platform
windows. With the multi-viewport and render features on native targets, the backend installs
the PlatformIO lifecycle bridge, all-window input/platform feedback, and per-window render
routing before advertising full multi-viewport support.
Re-exports§
pub use self::context::ImguiContexts;pub use self::context::ImguiFrameOutput;pub use self::context::ImguiFrameState;pub use self::helpers::configure_example_context;pub use self::schedule::ImguiBeginFrame;pub use self::schedule::ImguiEndFrame;pub use self::schedule::ImguiPrimaryContextPass;pub use self::texture::ImguiTextureFeedbackQueue;pub use self::viewport::ImguiViewportBridge;pub use self::viewport::ImguiViewportCamera;pub use self::viewport::ImguiViewportCommand;pub use self::viewport::ImguiViewportFeedback;pub use self::viewport::ImguiViewportId;pub use self::viewport::ImguiViewportSnapshot;pub use self::viewport::ImguiViewportWindow;
Modules§
- context
- Main-world Dear ImGui context lifecycle for Bevy.
- helpers
- Shared helper utilities for the backend’s example and editor-facing setup.
- input
- Window input mapping for the Bevy backend.
- schedule
- Bevy schedules used by the Dear ImGui backend.
- texture
- Texture interop resources for the Bevy backend.
- viewport
- Dear ImGui platform-viewport bridge for Bevy-owned windows.
Structs§
- Imgui
Backend Config - Static configuration for the Bevy backend.
- Imgui
Backend Status - Observable backend state installed by
ImguiPlugin. - Imgui
Context - Non-send Bevy resource that owns the Dear ImGui context.
- Imgui
Plugin - Bevy plugin that installs the minimal Dear ImGui resources.
Constants§
- BEVY_
TARGET_ COMMIT - Bevy reference commit used by the workstream.
- BEVY_
TARGET_ VERSION - First Bevy version targeted by this crate.
- RUST_
TARGET_ VERSION - Rust version required by the first Bevy target train.
- WGPU_
TARGET_ VERSION - WGPU version used by Bevy
0.19.0-rc.2.