|
PEBL 2.2
Psychology Experiment Building Language - Cross-platform psychological experiment development system
|
#include <PlatformTimer.h>
Public Member Functions | |
| PlatformTimer () | |
| The Standard constructor. | |
| virtual | ~PlatformTimer () |
| The Standard destructor. | |
| virtual void | Wait (unsigned long int msecs) |
| virtual void | Sleep (unsigned long int msecs) |
| virtual unsigned long int | GetTime () const |
| virtual void | GetTimeOfDay (unsigned long &secs, unsigned long &msecs) |
| virtual int | GetState (int iface) const |
| PlatformTimer () | |
| virtual | ~PlatformTimer () |
| virtual void | Wait (unsigned long int msecs) |
| virtual void | Sleep (unsigned long int msecs) |
| virtual unsigned long int | GetTime () const |
| virtual void | GetTimeOfDay (unsigned long &secs, unsigned long &msecs) |
| virtual int | GetState (int iface) const |
Public Member Functions inherited from PTimer | |
| PTimer () | |
| The Standard constructor. | |
| virtual | ~PTimer () |
| The Standard destructor. | |
| virtual PEBL_DEVICE_TYPE | GetDeviceType () |
Public Member Functions inherited from PDevice | |
| PDevice () | |
| The Standard constructor. | |
| virtual | ~PDevice () |
| The Standard destructor. | |
This device is the SDL-Specific interface for two types of platform functions: Querying the actual time, in msec, since the program started (which will wrap after a while) and waiting a specified period of time. It uses SDL function calls for this. For better accuracy, use system-specific timer calls,
Headless platform timer implementation using C++ chrono library This is a real implementation, not a stub, since timing is platform-independent
Definition at line 41 of file sdl/PlatformTimer.h.
| PlatformTimer::PlatformTimer | ( | ) |
The Standard constructor.
This is the standard PlatformTimer constructor.
Definition at line 57 of file sdl/PlatformTimer.cpp.
|
virtual |
The Standard destructor.
This is the standard pNode destructor.
Definition at line 63 of file sdl/PlatformTimer.cpp.
| PlatformTimer::PlatformTimer | ( | ) |
|
virtual |
|
virtual |
Implements PTimer.
Definition at line 158 of file sdl/PlatformTimer.cpp.
|
virtual |
Implements PTimer.
|
virtual |
Implements PTimer.
Definition at line 153 of file sdl/PlatformTimer.cpp.
Referenced by PEBLEnvironment::GetTime(), PEBLEnvironment::PlayMovie(), PEBLEnvironment::Wait(), PEBLEnvironment::WaitForAnyKeyDownWithTimeout(), PEBLEnvironment::WaitForAnyKeyPressWithTimeout(), PEBLEnvironment::WaitForListKeyPressWithTimeout(), and PEBLEnvironment::WaitForMouseButtonWithTimeout().
|
virtual |
Implements PTimer.
|
virtual |
Implements PTimer.
Definition at line 171 of file sdl/PlatformTimer.cpp.
References NULL.
Referenced by PEBLEnvironment::GetTimeOfDay().
|
virtual |
Implements PTimer.
|
virtual |
Sleep using OS-specific sleep functions (yields CPU, unlike Wait which busy-waits) This is appropriate for polling loops, avoiding CPU burn
Implements PTimer.
Definition at line 132 of file sdl/PlatformTimer.cpp.
Referenced by PEventLoop::Loop(), and PEBLObjects::RecordToBuffer().
|
virtual |
Implements PTimer.
|
virtual |
Implements PTimer.
Definition at line 73 of file sdl/PlatformTimer.cpp.
|
virtual |
Implements PTimer.