SDL_acos(3)
β¨ SDL_acos β¨
okay bestie, welcome to the SDL3 FUNCTIONS corner of the manual, where we're about to get triggy with it π
this one's all about SDL_acos(3) and honestly? it's giving math girlie main character energy π
πΈ NAME πΈ
SDL_acos β compute the arc cosine of x.
π¦ SYNOPSIS π¦
#include <SDL3/SDL_stdinc.h>
double SDL_acos(double x);
π DESCRIPTION π
so like, the definition of y = acos(x) is literally x = cos(y). that's it, that's the vibe. π«Ά
Domain: -1 <= x <= 1
Range: 0 <= y <= Pi
this function is out here operating on double-precision floating point values, so if you're working with single-precision floats you gotta go use SDL_acosf instead, iykyk β¨
and listen β this function may use a different approximation across different versions, platforms and configurations. i.e., it can return a different value given the same input on different machines or operating systems, or if SDL is updated. no cap, that's just how it is π so don't come for her when your numbers look slightly off on another box, she warned you π
π§ FUNCTION PARAMETERS π§
xβ floating point value. that's the one, the only, the input π
π RETURN VALUE π
Returns arc cosine of x, in radians. periodt. π
π₯ THREAD SAFETY π₯
It is safe to call this function from any thread. yes bestie, any thread β go wild, she's built different π«Άβ¨
β AVAILABILITY β
This function is available since SDL 3.2.0. so if you're on something older... bestie, upgrade π
π SEE ALSO π
and that's the whole page, you ate that π mwah π
Simple Directmedia Layer β SDL 3.4.18 β written by the SDL girlies, delivered to you with love and a lil sparkle β¨ππ¦ bye bestie, go compute some angles π
π¦ 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