mirror of
https://github.com/neovide/neovide.git
synced 2026-09-10 07:16:25 -04:00
feat: move profiling on windows platform - [10/20]
- add a new module `profiling` to the `src/platform/windows/` directory - create a new file `profiling.rs` in the `src/platform/windows/` directory - refactor the `d3d` module in the `profiling` directory to be accessed from the `platform/windows` module
This commit is contained in:
parent
05ba4fdd6b
commit
ca5e41c0fb
|
|
@ -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"))]
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
pub mod bridge;
|
||||
pub mod profiling;
|
||||
pub mod renderer;
|
||||
pub mod settings;
|
||||
pub mod vsync;
|
||||
|
|
|
|||
3
src/platform/windows/profiling.rs
Normal file
3
src/platform/windows/profiling.rs
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
#[cfg(feature = "gpu_profiling")]
|
||||
#[path = "../../profiling/d3d.rs"]
|
||||
pub mod d3d;
|
||||
|
|
@ -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;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue