blob: 0de48bcb007e5d9b2b14e9aef13f2cc95d1ef236 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
// license:BSD-3-Clause
// copyright-holders:Aaron Giles
//============================================================
//
// minitime.c - Minimal core timing functions
//
//============================================================
#include "osdepend.h"
#include <time.h>
//============================================================
// osd_ticks
//============================================================
osd_ticks_t osd_ticks(void)
{
// use the standard library clock function
return clock();
}
//============================================================
// osd_ticks_per_second
//============================================================
osd_ticks_t osd_ticks_per_second(void)
{
return CLOCKS_PER_SEC;
}
//============================================================
// osd_sleep
//============================================================
void osd_sleep(osd_ticks_t duration)
{
// if there was a generic, cross-platform way to give up
// time, this is where we would do it
}
|