mirror of
https://github.com/wiiu-env/wut.git
synced 2025-01-06 14:48:17 +01:00
coreinit: Move time macros from systeminfo.h to time.h
This commit is contained in:
parent
9871c06e67
commit
623661a39c
@ -25,10 +25,6 @@ CHECK_OFFSET(OSSystemInfo, 0x0, clockSpeed);
|
||||
CHECK_OFFSET(OSSystemInfo, 0x8, baseTime);
|
||||
CHECK_SIZE(OSSystemInfo, 0x20);
|
||||
|
||||
|
||||
#define OSOneSecond ((OSGetSystemInfo()->clockSpeed) / 4)
|
||||
#define OSMilliseconds(val) ((((uint64_t)(val)) * (uint64_t)(OSOneSecond)) / 1000ull)
|
||||
|
||||
OSSystemInfo *
|
||||
OSGetSystemInfo();
|
||||
|
||||
|
@ -33,6 +33,11 @@ CHECK_OFFSET(OSCalendarTime, 0x10, tm_mon);
|
||||
CHECK_OFFSET(OSCalendarTime, 0x14, tm_year);
|
||||
CHECK_SIZE(OSCalendarTime, 0x18);
|
||||
|
||||
#define OSOneSecond ((OSGetSystemInfo()->clockSpeed) / 4)
|
||||
#define OSMilliseconds(val) ((((uint64_t)(val)) * (uint64_t)(OSOneSecond)) / 1000ull)
|
||||
#define OSMicroseconds(val) ((((uint64_t)(val)) * (uint64_t)(OSOneSecond)) / 1000000ull)
|
||||
#define OSNanoseconds(val) ((((uint64_t)(val)) * (uint64_t)(OSOneSecond)) / 1000000000ull)
|
||||
|
||||
OSTime
|
||||
OSGetTime();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user