sdlFabsf function stdinc
Compute the absolute value of x
Domain: -INF <= x <= INF
Range: 0 <= y <= INF
This function operates on single-precision floating point values, use SDL_fabs for double-precision floats.
\param x floating point value to use as the magnitude.
\returns the absolute value of x
.
\threadsafety It is safe to call this function from any thread.
\since This function is available since SDL 3.2.0.
\sa SDL_fabs
extern SDL_DECLSPEC float SDLCALL SDL_fabsf(float x)
Implementation
double sdlFabsf(double x) {
final sdlFabsfLookupFunction = _libSdl
.lookupFunction<Float Function(Float x), double Function(double x)>(
'SDL_fabsf',
);
return sdlFabsfLookupFunction(x);
}