Restructured everything to make profiling a feature of iced_winit.

This commit is contained in:
bungoboingo 2022-12-20 20:41:09 -08:00 committed by Héctor Ramón Jiménez
parent c5cd236b73
commit 4b6d3797d4
No known key found for this signature in database
GPG key ID: 140CC052C94F138E
23 changed files with 184 additions and 254 deletions

View file

@ -8,7 +8,6 @@ publish = false
[dependencies]
iced_winit = { path = "../../winit" }
iced_wgpu = { path = "../../wgpu", features = ["webgl"] }
iced_profiling = { path = "../../profiling", features = ["tracing-chrome"]}
env_logger = "0.8"
[target.'cfg(target_arch = "wasm32")'.dependencies]

View file

@ -16,8 +16,6 @@ use winit::{
event_loop::{ControlFlow, EventLoop},
};
use iced_profiling::info_span;
#[cfg(target_arch = "wasm32")]
use wasm_bindgen::JsCast;
#[cfg(target_arch = "wasm32")]
@ -41,9 +39,6 @@ pub fn main() {
#[cfg(not(target_arch = "wasm32"))]
env_logger::init();
// Initialize tracing
let _guard = iced_profiling::init();
// Initialize winit
let event_loop = EventLoop::new();
@ -203,8 +198,6 @@ pub fn main() {
}
}
Event::RedrawRequested(_) => {
let _ = info_span!("Integration_WGPU", "DRAW").entered();
if resized {
let size = window.inner_size();