Logging & timeSDL 3.2
SDL_GetPerformanceFrequency
How many SDL_GetPerformanceCounter ticks make one second on this machine.
Signature
Uint64 SDL_GetPerformanceFrequency(void);
How it works
It does not change while the program runs, so you can read it once. Divide a counter difference by it to turn ticks into seconds.
Return value
Ticks per second.
Example
example.cpp
1const double toSeconds = 1.0 / double(SDL_GetPerformanceFrequency());
2double elapsed = double(end - start) * toSeconds;