From 3525db52992d47e860beee6c1effea37073153ba Mon Sep 17 00:00:00 2001 From: Mwa Date: Tue, 24 Mar 2026 23:16:33 +0100 Subject: [PATCH] added a warn when frame lag --- simu/src/main.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/simu/src/main.rs b/simu/src/main.rs index 9a4feb0..e2c7db1 100644 --- a/simu/src/main.rs +++ b/simu/src/main.rs @@ -261,6 +261,7 @@ impl<'a> ApplicationHandler for App<'a> { let now = Instant::now(); if next < now { next = now + Duration::from_secs_f64(1. / 30.); + println!("Warning: rendering is lagging!") } event_loop.set_control_flow(winit::event_loop::ControlFlow::WaitUntil(next)); if let Some(w) = self.w.as_ref() {