00001 00007 #ifndef _TIMER_H_ 00008 #define _TIMER_H_ 00009 00010 00011 class Timer { 00012 00013 public: 00014 00020 int getFrameRate(); 00021 00026 void setStartTime(); 00027 00032 float getSecondsSinceStart(); 00033 00039 float getNumTicksPerMs(); 00040 00045 void calcFrameCount(); 00046 00053 float getFrameDt(); 00054 00055 00060 Timer(); 00061 00066 ~Timer(); 00067 00068 private: 00069 00074 int time_FrameRate; 00075 00080 INT64 time_Frequency; 00081 00086 INT64 time_StartTime; 00087 00092 int time_FrameCount; 00093 00097 float time_LastFrame; 00098 00099 }; 00100 00101 #endif 00102 00103