INNER CODE UNIT · Rust

fps

wkwan/flo · src/fps_logger.rs:27

            let fps = self.fps_frame_count as f32 / time_since_last_fps;
            let frame_time_ms = time_since_last_fps * 1000.0 / self.fps_frame_count as f32;

            println!("FPS: {:.1} | Frame Time: {:.2}ms", fps, frame_time_ms);

            self.last_fps_time = current_time;
            self.fps_frame_count = 0;
        }
    }
}

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…