Skip to main content

graphics_core/
lib.rs

1//! # graphics-core
2//!
3//! Shared low-level, host-agnostic WGPU graphics substrate with offscreen rendering,
4//! GPU-to-CPU readback, 2D/camera math, and reusable render pipelines.
5
6pub mod batch2d;
7pub mod camera;
8pub mod handles;
9pub mod math;
10pub mod pipelines;
11pub mod readback;
12pub mod renderer;
13pub mod targets;
14
15// Re-export glam and wgpu for convenient math and GPU type identity across ecosystem
16pub use glam;
17pub use wgpu;
18
19// Flat re-exports for high-frequency ergonomics
20pub use batch2d::*;
21pub use camera::*;
22pub use handles::*;
23pub use math::*;
24pub use pipelines::*;
25pub use readback::*;
26pub use renderer::*;
27pub use targets::*;
28
29/// Crate version string.
30pub const VERSION: &str = env!("CARGO_PKG_VERSION");
31
32#[cfg(test)]
33mod tests {
34    use super::*;
35
36    #[test]
37    fn test_version_exists() {
38        assert!(!VERSION.is_empty());
39    }
40}