SDL_NS_PER_SECOND(3)
β¨ SDL_NS_PER_SECOND β¨
okay bestie, welcome to SDL_NS_PER_SECOND(3) β it's one of those pages from the SDL3 FUNCTIONS crew, and it's literally a single number that runs the whole clock situation π
πΈ NAME πΈ
SDL_NS_PER_SECOND β how many nanoseconds are chillin' in one single second. that's it. that's the whole job. π
π SYNOPSIS π
#include <SDL3/SDL_timer.h>
#define SDL_NS_PER_SECOND 1000000000LL
like. it's a macro. it's already defined for you. you literally just say the name and it's there. no function call, no setup, no drama. π¦
π DESCRIPTION π
this value is always 1000000000.
not "usually". not "on most platforms". not "if you're lucky". it is always 1000000000, forever, no cap. so if you're out here doing math with nanoseconds and you need to divide or multiply by the second, this is your girl. use her. she's constant. she's consistent. she's giving main character energy and she never switches up on you. πβ¨
π AVAILABILITY π
this macro has been around since SDL 3.2.0, so if you're on anything older, bestie... it's not there. upgrade era fr fr. π«Ά
ngl this is the shortest manpage you will ever read and honestly? iconic. no warnings, no bugs, no deprecated nonsense, no exit statuses, no environment variables. just a number. a really big number. and we love her for it. ππ
mwah, that's the whole page, ty for coming to my ted talk πΈ this little love letter came to you from Simple Directmedia Layer, sitting pretty at SDL 3.4.18, and it lives under the name SDL_NS_PER_SECOND(3) β see you in the next one, bestie, stay constant πβ¨
π¦ 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