diff --git a/src/cmd_line.rs b/src/cmd_line.rs index c652a735..a7b6d78e 100644 --- a/src/cmd_line.rs +++ b/src/cmd_line.rs @@ -8,7 +8,6 @@ use clap::{ ArgAction, Parser, }; use winit::window::CursorIcon; - #[cfg(target_os = "windows")] pub const SRGB_DEFAULT: &str = "1"; #[cfg(not(target_os = "windows"))] diff --git a/src/platform/windows/mod.rs b/src/platform/windows/mod.rs index d938a730..5bbc01a5 100644 --- a/src/platform/windows/mod.rs +++ b/src/platform/windows/mod.rs @@ -1,4 +1,5 @@ pub mod bridge; +pub mod profiling; pub mod renderer; pub mod settings; pub mod vsync; diff --git a/src/platform/windows/profiling.rs b/src/platform/windows/profiling.rs new file mode 100644 index 00000000..4a4caa22 --- /dev/null +++ b/src/platform/windows/profiling.rs @@ -0,0 +1,3 @@ +#[cfg(feature = "gpu_profiling")] +#[path = "../../profiling/d3d.rs"] +pub mod d3d; diff --git a/src/profiling/mod.rs b/src/profiling/mod.rs index 3b06e46b..a180ba66 100644 --- a/src/profiling/mod.rs +++ b/src/profiling/mod.rs @@ -1,10 +1,14 @@ +#[cfg(all(feature = "gpu_profiling", target_os = "windows"))] +use crate::platform::windows; #[cfg(not(feature = "profiling"))] mod profiling_disabled; #[cfg(feature = "profiling")] mod profiling_enabled; #[cfg(all(feature = "gpu_profiling", target_os = "windows"))] -pub mod d3d; +pub mod d3d { + pub use crate::platform::windows::profiling::d3d::*; +} #[cfg(feature = "gpu_profiling")] pub mod opengl;