30 gettimeofday(&m_start, NULL);
37 gettimeofday(&m_start, NULL);
45 gettimeofday(&m_end, NULL);
46 return (m_end.tv_sec + m_end.tv_usec * 1e-6) -
47 (m_start.tv_sec + m_start.tv_usec * 1e-6);
50 struct timeval m_start, m_end;
A simple timer class.
Definition: timer.h:26
void start()
saves the current time as the start time.
Definition: timer.h:36
double elapsed()
determines the elapsed time since start time.
Definition: timer.h:44