103#ifndef _NB_STOPWATCH_H
104#define _NB_STOPWATCH_H
106#include <constants.h>
139 unsigned long long ref_start;
140 unsigned long long elapsed;
239 void Start(
bool clear_count =
false);
High-resolution stopwatch timer for precise event timing and performance measurement.
Definition stopwatch.h:138
double Convert(unsigned long long ticks)
Convert timer ticks to seconds.
unsigned long long GetTime()
Get the current elapsed time without stopping the timer.
void Clear()
Clear the accumulated elapsed time.
void Start(bool clear_count=false)
Start or resume the stopwatch timer.
StopWatch(int timer_number=FIRST_UNUSED_TIMER)
Construct a stopwatch object with optional timer selection.
unsigned long long Stop()
Stop the stopwatch and return elapsed time.
double CountResolution()
Get the resolution of a single timer tick in seconds.