mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-09-16 08:18:13 +00:00
Updated source to match SDL function prototype style
This commit is contained in:
@@ -565,8 +565,7 @@ void SDL_QuitTicks(void)
|
||||
tick_start = 0;
|
||||
}
|
||||
|
||||
Uint64
|
||||
SDL_GetTicksNS(void)
|
||||
Uint64 SDL_GetTicksNS(void)
|
||||
{
|
||||
Uint64 starting_value, value;
|
||||
|
||||
|
@@ -22,15 +22,13 @@
|
||||
|
||||
#if defined(SDL_TIMER_DUMMY) || defined(SDL_TIMERS_DISABLED)
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceCounter(void)
|
||||
Uint64 SDL_GetPerformanceCounter(void)
|
||||
{
|
||||
SDL_Unsupported();
|
||||
return 0;
|
||||
}
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceFrequency(void)
|
||||
Uint64 SDL_GetPerformanceFrequency(void)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
@@ -25,14 +25,12 @@
|
||||
#include <kernel/OS.h>
|
||||
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceCounter(void)
|
||||
Uint64 SDL_GetPerformanceCounter(void)
|
||||
{
|
||||
return system_time();
|
||||
}
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceFrequency(void)
|
||||
Uint64 SDL_GetPerformanceFrequency(void)
|
||||
{
|
||||
return SDL_US_PER_SECOND;
|
||||
}
|
||||
|
@@ -25,14 +25,12 @@
|
||||
#include <3ds.h>
|
||||
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceCounter(void)
|
||||
Uint64 SDL_GetPerformanceCounter(void)
|
||||
{
|
||||
return svcGetSystemTick();
|
||||
}
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceFrequency(void)
|
||||
Uint64 SDL_GetPerformanceFrequency(void)
|
||||
{
|
||||
return SYSCLOCK_ARM11;
|
||||
}
|
||||
|
@@ -32,15 +32,13 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceCounter(void)
|
||||
Uint64 SDL_GetPerformanceCounter(void)
|
||||
{
|
||||
/* FIXME: Need to account for 32-bit wrapping */
|
||||
return (Uint64)User::TickCount();
|
||||
}
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceFrequency(void)
|
||||
Uint64 SDL_GetPerformanceFrequency(void)
|
||||
{
|
||||
return SDL_US_PER_SECOND;
|
||||
}
|
||||
|
@@ -29,14 +29,12 @@
|
||||
#include <sys/time.h>
|
||||
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceCounter(void)
|
||||
Uint64 SDL_GetPerformanceCounter(void)
|
||||
{
|
||||
return GetTimerSystemTime();
|
||||
}
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceFrequency(void)
|
||||
Uint64 SDL_GetPerformanceFrequency(void)
|
||||
{
|
||||
return kBUSCLK;
|
||||
}
|
||||
|
@@ -29,8 +29,7 @@
|
||||
#include <pspthreadman.h>
|
||||
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceCounter(void)
|
||||
Uint64 SDL_GetPerformanceCounter(void)
|
||||
{
|
||||
Uint64 ticks;
|
||||
struct timeval now;
|
||||
@@ -42,8 +41,7 @@ SDL_GetPerformanceCounter(void)
|
||||
return ticks;
|
||||
}
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceFrequency(void)
|
||||
Uint64 SDL_GetPerformanceFrequency(void)
|
||||
{
|
||||
return SDL_US_PER_SECOND;
|
||||
}
|
||||
|
@@ -82,8 +82,7 @@ static void CheckMonotonicTime(void)
|
||||
checked_monotonic_time = SDL_TRUE;
|
||||
}
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceCounter(void)
|
||||
Uint64 SDL_GetPerformanceCounter(void)
|
||||
{
|
||||
Uint64 ticks;
|
||||
|
||||
@@ -116,8 +115,7 @@ SDL_GetPerformanceCounter(void)
|
||||
return ticks;
|
||||
}
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceFrequency(void)
|
||||
Uint64 SDL_GetPerformanceFrequency(void)
|
||||
{
|
||||
if (!checked_monotonic_time) {
|
||||
CheckMonotonicTime();
|
||||
|
@@ -29,14 +29,12 @@
|
||||
#include <psp2/kernel/processmgr.h>
|
||||
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceCounter(void)
|
||||
Uint64 SDL_GetPerformanceCounter(void)
|
||||
{
|
||||
return sceKernelGetProcessTimeWide();
|
||||
}
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceFrequency(void)
|
||||
Uint64 SDL_GetPerformanceFrequency(void)
|
||||
{
|
||||
return SDL_US_PER_SECOND;
|
||||
}
|
||||
|
@@ -25,8 +25,7 @@
|
||||
#include "../../core/windows/SDL_windows.h"
|
||||
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceCounter(void)
|
||||
Uint64 SDL_GetPerformanceCounter(void)
|
||||
{
|
||||
LARGE_INTEGER counter;
|
||||
const BOOL rc = QueryPerformanceCounter(&counter);
|
||||
@@ -34,8 +33,7 @@ SDL_GetPerformanceCounter(void)
|
||||
return (Uint64)counter.QuadPart;
|
||||
}
|
||||
|
||||
Uint64
|
||||
SDL_GetPerformanceFrequency(void)
|
||||
Uint64 SDL_GetPerformanceFrequency(void)
|
||||
{
|
||||
LARGE_INTEGER frequency;
|
||||
const BOOL rc = QueryPerformanceFrequency(&frequency);
|
||||
|
Reference in New Issue
Block a user