Visualization Library v1.0.3A lightweight C++ OpenGL middleware for 2D/3D graphics |
[Download] [Tutorials] [All Classes] [Grouped Classes] |
Simple class to be used as a timer and to retrieve the current time and date. More...
#include <Time.hpp>
Public Member Functions | |
Time () | |
int | year () const |
int | month () const |
int | dayOfWeek () const |
int | dayOfMonth () const |
int | hour () const |
int | minute () const |
int | second () const |
int | microsecond () const |
void | start (int index=0) |
void | stop (int index=0) |
bool | isStarted (int index=0) const |
real | elapsed (int index=0) const |
Static Public Member Functions | |
static real | currentTime () |
Seconds passed from an arbitrary origin QueryPerformanceFrequency should be called only once in the application lifetime. | |
static void | sleep (unsigned int milliseconds) |
Protected Attributes | |
int | mYear |
int | mMonth |
int | mDayOfWeek |
int | mDayOfMonth |
int | mHour |
int | mMinute |
int | mSecond |
int | mMicrosecond |
real | mStart [VL_MAX_TIMERS] |
Simple class to be used as a timer and to retrieve the current time and date.
Definition at line 49 of file Time.hpp.
Time::Time | ( | ) |
Definition at line 46 of file Time.cpp.
References mDayOfMonth, mDayOfWeek, mHour, mMicrosecond, mMinute, mMonth, mSecond, mStart, mYear, NULL, VL_DEBUG_SET_OBJECT_NAME, and VL_MAX_TIMERS.
int vl::Time::year | ( | ) | const [inline] |
Definition at line 56 of file Time.hpp.
Referenced by vl::Applet::keyReleaseEvent().
int vl::Time::month | ( | ) | const [inline] |
Definition at line 58 of file Time.hpp.
Referenced by vl::Applet::keyReleaseEvent().
int vl::Time::dayOfMonth | ( | ) | const [inline] |
Definition at line 62 of file Time.hpp.
Referenced by vl::Applet::keyReleaseEvent().
int vl::Time::hour | ( | ) | const [inline] |
Definition at line 64 of file Time.hpp.
Referenced by vl::Applet::keyReleaseEvent().
int vl::Time::second | ( | ) | const [inline] |
Definition at line 68 of file Time.hpp.
Referenced by vl::Applet::keyReleaseEvent().
real Time::currentTime | ( | ) | [static] |
Seconds passed from an arbitrary origin QueryPerformanceFrequency should be called only once in the application lifetime.
Definition at line 114 of file Time.cpp.
References vl::gStartTime, vl::initStartTime(), NULL, and VL_CHECK.
Referenced by vl::Applet::Applet(), vl::GhostCameraManipulator::updateEvent(), and vl::Applet::updateEvent().
void Time::sleep | ( | unsigned int | milliseconds ) | [static] |
Definition at line 144 of file Time.cpp.
Referenced by vl::abort_vl(), and vlGLUT::GLUTWindow::glut_idle_func().
void vl::Time::start | ( | int | index = 0 ) |
[inline] |
Definition at line 76 of file Time.hpp.
Referenced by main(), vl::DoubleVertexRemover::removeDoubles(), and vl::PolygonSimplifier::simplify().
real vl::Time::elapsed | ( | int | index = 0 ) |
const [inline] |
Definition at line 82 of file Time.hpp.
Referenced by main(), vl::DoubleVertexRemover::removeDoubles(), and vl::PolygonSimplifier::simplify().
int vl::Time::mYear [protected] |
int vl::Time::mMonth [protected] |
int vl::Time::mDayOfWeek [protected] |
int vl::Time::mDayOfMonth [protected] |
int vl::Time::mHour [protected] |
int vl::Time::mMinute [protected] |
int vl::Time::mSecond [protected] |
int vl::Time::mMicrosecond [protected] |
real vl::Time::mStart[VL_MAX_TIMERS] [protected] |