SDL_TimeToWindows(3)
π SDL_TimeToWindows(3) π
okay so bestie, welcome to the SDL3 FUNCTIONS section of the manual, and today's main character is SDL_TimeToWindows π
β¨ NAME β¨
SDL_TimeToWindows β no cap, this one converts an SDL time into a Windows FILETIME, and a FILETIME is measured in 100-nanosecond intervals since January 1, 1601. yes, 1601. the Windows girlies have been counting for a minute. β³π
πΈ SYNOPSIS πΈ
#include <SDL3/SDL_time.h>
void SDL_TimeToWindows(SDL_Time ticks, Uint32 *dwLowDateTime, Uint32 *dwHighDateTime);
π¦ DESCRIPTION π¦
so like, this function fills in the two 32-bit values of the FILETIME structure. that's it, that's the whole vibe. you hand it a time, it hands you back the low half and the high half. it's giving split the number, deliver the goods β¨
π FUNCTION PARAMETERS π
ticksβ the time to convert. just your regular time, minding its own business, waiting to be transmuted π§dwLowDateTimeβ a pointer that gets filled in with the low portion of the WindowsFILETIMEvalue. lower half, holding it down πdwHighDateTimeβ a pointer that gets filled in with the high portion of the WindowsFILETIMEvalue. upper half, doing the most π
π₯ THREAD SAFETY π₯
it is safe to call this function from any thread. every thread. all at once. no drama, no locking, no "wait your turn." the multitasking queen we deserve π
β AVAILABILITY β
this function is available since SDL 3.2.0. if you're on anything older, sorry bestie, it's not there yet π
π reminder: FILETIME is a Windows thing, so the whole point here is translating your nice portable SDL time into that 1601-era Windows counting system. the two 32-bit halves are the whole structure. no more, no less. periodt.
and that's the page!! thanks for coming to my ted talk, brought to you by Simple Directmedia Layer, version SDL 3.4.18, of the SDL_TimeToWindows(3) manual. mwah π go convert some times bestie π«Άβ¨
π¦ where this page comes from
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms