Timer.h

Go to the documentation of this file.
00001 
00002 //Luke Lenhart, 2007
00003 //See /docs/License.txt for details on how this code may be used.
00004 
00005 #pragma once
00006 
00007 #if defined(_WIN32) || defined(_WIN64)
00008     //windows.h drags too much in and causes conflicts, so moved to .cpp
00009     #include "Types.h"
00010 #else
00011     #include <sys/time.h>
00012 #endif
00013 
00014 namespace MPMA
00015 {
00017     class Timer
00018     {
00019     public:
00020         Timer();
00021         
00023         double Step(bool updateStartTime=true);
00024         
00025     private:
00026         #if defined(_WIN32) || defined(_WIN64)
00027             uint64 lastTime64;
00028         #else
00029             timeval lastTime;
00030         #endif
00031     
00032     };
00033 }
00034 
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends