1
0
mirror of https://github.com/emilk/egui.git synced 2026-08-30 13:20:05 -04:00

egui-wgpu: Show wgpu profiling scopes when using puffin profiler

This commit is contained in:
Emil Ernerfeldt
2023-12-19 12:45:20 +01:00
parent 9253cafedd
commit b6beba55d3
3 changed files with 31 additions and 13 deletions

View File

@@ -622,12 +622,9 @@ impl Painter {
};
// Submit the commands: both the main buffer and user-defined ones.
{
crate::profile_scope!("Queue::submit");
render_state
.queue
.submit(user_cmd_bufs.into_iter().chain([encoded]));
};
render_state
.queue
.submit(user_cmd_bufs.into_iter().chain([encoded]));
let screenshot = if capture {
let screen_capture_state = self.screen_capture_state.as_ref()?;
@@ -636,10 +633,8 @@ impl Painter {
None
};
{
crate::profile_scope!("present");
output_frame.present();
}
output_frame.present();
screenshot
}