#include <Duration.h>
Public Member Functions | |
| Duration () | |
| virtual | ~Duration () |
| void | Start (void) |
| void | Stop (void) |
| double | GetDuration (void) const |
| double | GetDurationInMs (void) const |
Protected Attributes | |
| TIMEVAL | m_liStart |
| TIMEVAL | m_liStop |
Definition at line 29 of file Duration.h.
|
|
Definition at line 56 of file Duration.h. References m_liStart, m_liStop, Start(), and Stop(). 00057 { 00058 #ifdef WIN32 00059 LARGE_INTEGER liFrequency; 00060 00061 QueryPerformanceFrequency(&liFrequency); 00062 m_llFrequency = liFrequency.QuadPart; 00063 00064 // Calibration 00065 Start(); 00066 Stop(); 00067 00068 m_llCorrection = m_liStop.QuadPart-m_liStart.QuadPart; 00069 #else 00070 // Calibration 00071 // Start(); 00072 // Stop(); 00073 00074 // m_llCorrection = GetDuration(); 00075 #endif 00076 }
Here is the call graph for this function: ![]() |
|
|
Definition at line 33 of file Duration.h.
|
|
|
Definition at line 102 of file Duration.h. References ELAPSED_TIME_SEC, m_liStart, and m_liStop. 00103 { 00104 #ifdef WIN32 00105 return (double)(m_liStop.QuadPart-m_liStart.QuadPart-m_llCorrection)*1000000.0 / m_llFrequency; 00106 #else 00107 return ELAPSED_TIME_SEC(m_liStart, m_liStop); 00108 #endif 00109 }
|
|
|
not sure !!! Definition at line 111 of file Duration.h. References ELAPSED_TIME_SEC, m_liStart, and m_liStop. 00112 { 00113 #ifdef WIN32 00114 return (double)(m_liStop.QuadPart-m_liStart.QuadPart-m_llCorrection)*1000000.0 / m_llFrequency /1000.0; 00115 #else 00116 return ELAPSED_TIME_SEC(m_liStart, m_liStop)*1000.0; 00117 #endif 00118 }
|
|
|
Definition at line 78 of file Duration.h. References GET_TIME, and m_liStart. Referenced by Duration(). 00079 { 00080 00081 #ifdef WIN32 00082 // Ensure we will not be interrupted by any other thread for a while 00083 Sleep(0); 00084 QueryPerformanceCounter(&m_liStart); 00085 #else 00086 GET_TIME(m_liStart); 00087 #endif 00088 00089 00090 }
|
|
|
Definition at line 92 of file Duration.h. References GET_TIME, and m_liStop. Referenced by Duration(). 00093 { 00094 #ifdef WIN32 00095 QueryPerformanceCounter(&m_liStop); 00096 #else 00097 GET_TIME(m_liStop); 00098 #endif 00099 00100 }
|
|
|
Definition at line 49 of file Duration.h. Referenced by Duration(), GetDuration(), GetDurationInMs(), and Start(). |
|
|
Definition at line 50 of file Duration.h. Referenced by Duration(), GetDuration(), GetDurationInMs(), and Stop(). |
1.4.5