mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-09-05 19:08:12 +00:00
Fixing systimer
This commit is contained in:

committed by
Sam Lantinga

parent
4d82ceae0c
commit
10c14e78b6
@@ -34,6 +34,8 @@
|
||||
static uint64_t start;
|
||||
static SDL_bool ticks_started = SDL_FALSE;
|
||||
|
||||
static Uint64 BUSCLK_MS = (kBUSCLK / 1000);
|
||||
|
||||
void SDL_TicksInit(void)
|
||||
{
|
||||
if (ticks_started) {
|
||||
@@ -58,7 +60,7 @@ Uint64 SDL_GetTicks64(void)
|
||||
}
|
||||
|
||||
now = GetTimerSystemTime();
|
||||
return (Uint64)((now - start) / (kBUSCLK / CLOCKS_PER_SEC));
|
||||
return (Uint64)((now - start) / BUSCLK_MS);
|
||||
}
|
||||
|
||||
Uint64 SDL_GetPerformanceCounter(void)
|
||||
|
Reference in New Issue
Block a user