source:
abuse/trunk/src/imlib/timing.h
@
555
Last change on this file since 555 was 555, checked in by , 12 years ago | |
---|---|
|
|
File size: 751 bytes |
Line | |
---|---|
1 | /* |
2 | * Abuse - dark 2D side-scrolling platform game |
3 | * Copyright (c) 1995 Crack dot Com |
4 | * Copyright (c) 2005-2011 Sam Hocevar <sam@hocevar.net> |
5 | * |
6 | * This software was released into the Public Domain. As with most public |
7 | * domain software, no warranty is made or implied by Crack dot Com, by |
8 | * Jonathan Clark, or by Sam Hocevar. |
9 | */ |
10 | |
11 | #ifndef __TIMING_HPP_ |
12 | #define __TIMING_HPP_ |
13 | |
14 | class time_marker |
15 | { |
16 | public: |
17 | #if defined __CELLOS_LV2__ |
18 | uint64_t ticks; |
19 | #else |
20 | long seconds; |
21 | long micro_seconds; |
22 | #endif |
23 | void get_time(); |
24 | time_marker(); |
25 | double diff_time(time_marker *other); // return time diff in seconds |
26 | }; |
27 | |
28 | void milli_wait(unsigned int wait_time); // sleep for a millisecond |
29 | void timer_init(); |
30 | void timer_uninit(); |
31 | |
32 | #endif |
33 |
Note: See TracBrowser
for help on using the repository browser.