2019-08-13 14:44:16 +00:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#ifndef timer_h__
|
|
|
|
#define timer_h__
|
|
|
|
|
|
|
|
#include "compat.h"
|
|
|
|
|
2019-08-14 14:26:48 +00:00
|
|
|
// for compatibility
|
|
|
|
#define timerUninit()
|
|
|
|
|
|
|
|
int timerInit(int const tickspersecond);
|
2019-08-13 14:44:16 +00:00
|
|
|
void timerUpdate(void);
|
2019-08-14 14:26:48 +00:00
|
|
|
int timerGetRate(void);
|
2019-08-13 14:44:16 +00:00
|
|
|
uint64_t timerGetTicksU64(void);
|
|
|
|
uint64_t timerGetFreqU64(void);
|
|
|
|
double timerGetHiTicks(void);
|
|
|
|
uint32_t timerGetTicks(void);
|
2019-08-14 14:26:48 +00:00
|
|
|
|
2019-08-13 14:44:16 +00:00
|
|
|
void (*timerSetCallback(void (*callback)(void)))(void);
|
|
|
|
|
|
|
|
#endif // timer_h__
|