mirror of
https://github.com/AquariaOSE/Aquaria.git
synced 2025-08-07 22:59:50 +00:00
initial commit. This is icculus version 5542b94cae02a6333845854bbbd1abe0a259f1a4
This commit is contained in:
commit
3096eaf5e2
2519 changed files with 816064 additions and 0 deletions
21
ExternalLibs/iprof/prof_win32.c
Normal file
21
ExternalLibs/iprof/prof_win32.c
Normal file
|
@ -0,0 +1,21 @@
|
|||
#define WIN32_LEAN_AND_MEAN
|
||||
#define WIN32_EXTRA_LEAN
|
||||
#include <windows.h>
|
||||
#include <assert.h>
|
||||
|
||||
double Prof_get_time(void)
|
||||
{
|
||||
LARGE_INTEGER freq;
|
||||
LARGE_INTEGER time;
|
||||
|
||||
BOOL ok = QueryPerformanceFrequency(&freq);
|
||||
assert(ok == TRUE);
|
||||
|
||||
freq.QuadPart = freq.QuadPart;
|
||||
|
||||
ok = QueryPerformanceCounter(&time);
|
||||
assert(ok == TRUE);
|
||||
|
||||
return time.QuadPart / (double) freq.QuadPart;
|
||||
}
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue