sdl3/generated/lib_sdl_stdinc
library
Functions
-
sdlAbs(int x)
→ int
-
Compute the absolute value of
x
.
-
sdlAcos(double x)
→ double
-
Compute the arc cosine of
x
.
-
sdlAcosf(double x)
→ double
-
Compute the arc cosine of
x
.
-
sdlAlignedAlloc(int alignment, int size)
→ Pointer<NativeType>
-
Allocate memory aligned to a specific alignment.
-
sdlAlignedFree(Pointer<NativeType> mem)
→ void
-
Free memory allocated by SDL_aligned_alloc().
-
sdlAsin(double x)
→ double
-
Compute the arc sine of
x
.
-
sdlAsinf(double x)
→ double
-
Compute the arc sine of
x
.
-
sdlAsprintf(Pointer<Pointer<Int8>> strp, String? fmt, Pointer<NativeType> arg2)
→ int
-
extern SDL_DECLSPEC int SDLCALL SDL_asprintf(char **strp, SDL_PRINTF_FORMAT_STRING const char *fmt, ...) SDL_PRINTF_VARARG_FUNC(2)
-
sdlAtan(double x)
→ double
-
Compute the arc tangent of
x
.
-
sdlAtan2(double y, double x)
→ double
-
Compute the arc tangent of
y / x
, using the signs of x and y to adjust
the result's quadrant.
-
sdlAtan2f(double y, double x)
→ double
-
Compute the arc tangent of
y / x
, using the signs of x and y to adjust
the result's quadrant.
-
sdlAtanf(double x)
→ double
-
Compute the arc tangent of
x
.
-
sdlAtof(String? str)
→ double
-
Parse a
double
from a string.
-
sdlAtoi(String? str)
→ int
-
Parse an
int
from a string.
-
sdlBsearch(Pointer<NativeType> key, Pointer<NativeType> base, int nmemb, int size, Pointer<NativeFunction<SdlCompareCallback>> compare)
→ Pointer<NativeType>
-
Perform a binary search on a previously sorted array.
-
sdlBsearchR(Pointer<NativeType> key, Pointer<NativeType> base, int nmemb, int size, Pointer<NativeFunction<SdlCompareCallbackR>> compare, Pointer<NativeType> userdata)
→ Pointer<NativeType>
-
Perform a binary search on a previously sorted array, passing a userdata
pointer to the compare function.
-
sdlCeil(double x)
→ double
-
Compute the ceiling of
x
.
-
sdlCeilf(double x)
→ double
-
Compute the ceiling of
x
.
-
sdlCopysign(double x, double y)
→ double
-
Copy the sign of one floating-point value to another.
-
sdlCopysignf(double x, double y)
→ double
-
Copy the sign of one floating-point value to another.
-
sdlCos(double x)
→ double
-
Compute the cosine of
x
.
-
sdlCosf(double x)
→ double
-
Compute the cosine of
x
.
-
sdlCrc16(int crc, Pointer<NativeType> data, int len)
→ int
-
Calculate a CRC-16 value.
-
sdlCrc32(int crc, Pointer<NativeType> data, int len)
→ int
-
Calculate a CRC-32 value.
-
sdlCreateEnvironment(bool populated)
→ Pointer<SdlEnvironment>
-
Create a set of environment variables
-
sdlDestroyEnvironment(Pointer<SdlEnvironment> env)
→ void
-
Destroy a set of environment variables.
-
sdlExp(double x)
→ double
-
Compute the exponential of
x
.
-
sdlExpf(double x)
→ double
-
Compute the exponential of
x
.
-
sdlFabs(double x)
→ double
-
Compute the absolute value of
x
-
sdlFabsf(double x)
→ double
-
Compute the absolute value of
x
-
sdlFloor(double x)
→ double
-
Compute the floor of
x
.
-
sdlFloorf(double x)
→ double
-
Compute the floor of
x
.
-
sdlFmod(double x, double y)
→ double
-
Return the floating-point remainder of
x / y
-
sdlFmodf(double x, double y)
→ double
-
Return the floating-point remainder of
x / y
-
sdlFree(Pointer<NativeType> mem)
→ void
-
Free allocated memory.
-
sdlGetenv(String? name)
→ String?
-
Get the value of a variable in the environment.
-
sdlGetEnvironment()
→ Pointer<SdlEnvironment>
-
Get the process environment.
-
sdlGetEnvironmentVariable(Pointer<SdlEnvironment> env, String? name)
→ String?
-
Get the value of a variable in the environment.
-
sdlGetEnvironmentVariables(Pointer<SdlEnvironment> env)
→ Pointer<Pointer<Int8>>
-
Get all variables in the environment.
-
sdlGetenvUnsafe(String? name)
→ String?
-
Get the value of a variable in the environment.
-
sdlGetMemoryFunctions(Pointer<Pointer<NativeFunction<SdlMallocFunc>>> mallocFunc, Pointer<Pointer<NativeFunction<SdlCallocFunc>>> callocFunc, Pointer<Pointer<NativeFunction<SdlReallocFunc>>> reallocFunc, Pointer<Pointer<NativeFunction<SdlFreeFunc>>> freeFunc)
→ void
-
Get the current set of SDL memory functions.
-
sdlGetNumAllocations()
→ int
-
Get the number of outstanding (unfreed) allocations.
-
sdlGetOriginalMemoryFunctions(Pointer<Pointer<NativeFunction<SdlMallocFunc>>> mallocFunc, Pointer<Pointer<NativeFunction<SdlCallocFunc>>> callocFunc, Pointer<Pointer<NativeFunction<SdlReallocFunc>>> reallocFunc, Pointer<Pointer<NativeFunction<SdlFreeFunc>>> freeFunc)
→ void
-
Get the original set of SDL memory functions.
-
sdlIconv(Pointer<SdlIconvT> cd, Pointer<Pointer<Int8>> inbuf, Pointer<Uint32> inbytesleft, Pointer<Pointer<Int8>> outbuf, Pointer<Uint32> outbytesleft)
→ int
-
This function converts text between encodings, reading from and writing to
a buffer.
-
sdlIconvClose(Pointer<SdlIconvT> cd)
→ int
-
This function frees a context used for character set conversion.
-
sdlIconvOpen(String? tocode, String? fromcode)
→ Pointer<SdlIconvT>
-
This function allocates a context for the specified character set
conversion.
-
sdlIconvString(String? tocode, String? fromcode, String? inbuf, int inbytesleft)
→ Pointer<Int8>
-
Helper function to convert a string's encoding in one call.
-
sdlIsalnum(int x)
→ int
-
Query if a character is alphabetic (a letter) or a number.
-
sdlIsalpha(int x)
→ int
-
Query if a character is alphabetic (a letter).
-
sdlIsblank(int x)
→ int
-
Report if a character is blank (a space or tab).
-
sdlIscntrl(int x)
→ int
-
Report if a character is a control character.
-
sdlIsdigit(int x)
→ int
-
Report if a character is a numeric digit.
-
sdlIsgraph(int x)
→ int
-
Report if a character is any "printable" except space.
-
sdlIsinf(double x)
→ int
-
Return whether the value is infinity.
-
sdlIsinff(double x)
→ int
-
Return whether the value is infinity.
-
sdlIslower(int x)
→ int
-
Report if a character is lower case.
-
sdlIsnan(double x)
→ int
-
Return whether the value is NaN.
-
sdlIsnanf(double x)
→ int
-
Return whether the value is NaN.
-
sdlIsprint(int x)
→ int
-
Report if a character is "printable".
-
sdlIspunct(int x)
→ int
-
Report if a character is a punctuation mark.
-
sdlIsspace(int x)
→ int
-
Report if a character is whitespace.
-
sdlIsupper(int x)
→ int
-
Report if a character is upper case.
-
sdlIsxdigit(int x)
→ int
-
Report if a character is a hexadecimal digit.
-
sdlItoa(int value, Pointer<Int8> str, int radix)
→ Pointer<Int8>
-
Convert an integer into a string.
-
sdlLltoa(Pointer<NativeType> value, Pointer<Int8> str, int radix)
→ Pointer<Int8>
-
Convert a long long integer into a string.
-
sdlLog10(double x)
→ double
-
Compute the base-10 logarithm of
x
.
-
sdlLog10f(double x)
→ double
-
Compute the base-10 logarithm of
x
.
-
sdlLogf(double x)
→ double
-
Compute the natural logarithm of
x
.
-
sdlLround(double x)
→ int
-
Round
x
to the nearest integer representable as a long
-
sdlLroundf(double x)
→ int
-
Round
x
to the nearest integer representable as a long
-
sdlLtoa(int value, Pointer<Int8> str, int radix)
→ Pointer<Int8>
-
Convert a long integer into a string.
-
sdlMalloc(int size)
→ Pointer<NativeType>
-
Allocate uninitialized memory.
-
sdlMemcmp(Pointer<NativeType> s1, Pointer<NativeType> s2, int len)
→ int
-
Clear an array's memory to zero.
-
sdlMemcpy(Pointer<NativeType> arg0, Pointer<NativeType> arg1, int len)
→ Pointer<NativeType>
-
Copy non-overlapping memory.
-
sdlMemmove(Pointer<NativeType> arg0, Pointer<NativeType> arg1, int len)
→ Pointer<NativeType>
-
Copy memory ranges that might overlap.
-
sdlMemset(Pointer<NativeType> arg0, int c, int len)
→ Pointer<NativeType>
-
Initialize all bytes of buffer of memory to a specific value.
-
sdlMemset4(Pointer<NativeType> dst, int val, int dwords)
→ Pointer<NativeType>
-
Initialize all 32-bit words of buffer of memory to a specific value.
-
sdlModf(double x, Pointer<Double> y)
→ double
-
Split
x
into integer and fractional parts
-
sdlModff(double x, Pointer<Float> y)
→ double
-
Split
x
into integer and fractional parts
-
sdlMurmur332(Pointer<NativeType> data, int len, int seed)
→ int
-
Calculate a 32-bit MurmurHash3 value for a block of data.
-
sdlPow(double x, double y)
→ double
-
Raise
x
to the power y
-
sdlPowf(double x, double y)
→ double
-
Raise
x
to the power y
-
sdlQsort(Pointer<NativeType> base, int nmemb, int size, Pointer<NativeFunction<SdlCompareCallback>> compare)
→ void
-
Sort an array.
-
sdlQsortR(Pointer<NativeType> base, int nmemb, int size, Pointer<NativeFunction<SdlCompareCallbackR>> compare, Pointer<NativeType> userdata)
→ void
-
Sort an array, passing a userdata pointer to the compare function.
-
sdlRand(int n)
→ int
-
Generate a pseudo-random number less than n for positive n
-
sdlRandBits()
→ int
-
Generate 32 pseudo-random bits.
-
sdlRandBitsR(Pointer<Uint64> state)
→ int
-
Generate 32 pseudo-random bits.
-
sdlRandf()
→ double
-
Generate a uniform pseudo-random floating point number less than 1.0
-
sdlRandfR(Pointer<Uint64> state)
→ double
-
Generate a uniform pseudo-random floating point number less than 1.0
-
sdlRandR(Pointer<Uint64> state, int n)
→ int
-
Generate a pseudo-random number less than n for positive n
-
sdlRound(double x)
→ double
-
Round
x
to the nearest integer.
-
sdlRoundf(double x)
→ double
-
Round
x
to the nearest integer.
-
sdlScalbn(double x, int n)
→ double
-
Scale
x
by an integer power of two.
-
sdlScalbnf(double x, int n)
→ double
-
Scale
x
by an integer power of two.
-
sdlSetEnvironmentVariable(Pointer<SdlEnvironment> env, String? name, String? value, bool overwrite)
→ bool
-
Set the value of a variable in the environment.
-
sdlSetenvUnsafe(String? name, String? value, int overwrite)
→ int
-
Set the value of a variable in the environment.
-
sdlSetMemoryFunctions(Pointer<NativeFunction<SdlMallocFunc>> mallocFunc, Pointer<NativeFunction<SdlCallocFunc>> callocFunc, Pointer<NativeFunction<SdlReallocFunc>> reallocFunc, Pointer<NativeFunction<SdlFreeFunc>> freeFunc)
→ bool
-
Replace SDL's memory allocation functions with a custom set.
-
sdlSin(double x)
→ double
-
Compute the sine of
x
.
-
sdlSinf(double x)
→ double
-
Compute the sine of
x
.
-
sdlSnprintf(Pointer<NativeType> arg0, int maxlen, String? fmt, Pointer<NativeType> arg3)
→ int
-
extern SDL_DECLSPEC int SDLCALL SDL_snprintf(SDL_OUT_Z_CAP(maxlen) char *text, size_t maxlen, SDL_PRINTF_FORMAT_STRING const char *fmt, ...) SDL_PRINTF_VARARG_FUNC(3)
-
sdlSqrt(double x)
→ double
-
Compute the square root of
x
.
-
sdlSqrtf(double x)
→ double
-
Compute the square root of
x
.
-
sdlSrand(int seed)
→ void
-
Seeds the pseudo-random number generator.
-
sdlSscanf(String? text, String? fmt, Pointer<NativeType> arg2)
→ int
-
extern SDL_DECLSPEC int SDLCALL SDL_sscanf(const char *text, SDL_SCANF_FORMAT_STRING const char *fmt, ...) SDL_SCANF_VARARG_FUNC(2)
-
sdlStepBackUtf8(String? start, Pointer<Pointer<Int8>> pstr)
→ int
-
Decode a UTF-8 string in reverse, one Unicode codepoint at a time.
-
sdlStepUtf8(Pointer<Pointer<Int8>> pstr, Pointer<Uint32> pslen)
→ int
-
Decode a UTF-8 string, one Unicode codepoint at a time.
-
sdlStrcasecmp(String? str1, String? str2)
→ int
-
Compare two null-terminated UTF-8 strings, case-insensitively.
-
sdlStrcasestr(String? haystack, String? needle)
→ Pointer<Int8>
-
Search a UTF-8 string for the first instance of a specific substring,
case-insensitively.
-
sdlStrchr(String? str, int c)
→ Pointer<Int8>
-
Search a string for the first instance of a specific byte.
-
sdlStrcmp(String? str1, String? str2)
→ int
-
Compare two null-terminated UTF-8 strings.
-
sdlStrdup(String? str)
→ Pointer<Int8>
-
extern SDL_DECLSPEC SDL_MALLOC char * SDLCALL SDL_strdup(const char *str)
-
sdlStrlcat(Pointer<NativeType> arg0, String? src, int maxlen)
→ int
-
Concatenate strings.
-
sdlStrlcpy(Pointer<NativeType> arg0, String? src, int maxlen)
→ int
-
Copy a string.
-
sdlStrlen(String? str)
→ int
-
This works exactly like strlen() but doesn't require access to a C runtime.
-
sdlStrlwr(Pointer<Int8> str)
→ Pointer<Int8>
-
Convert a string to lowercase.
-
sdlStrncasecmp(String? str1, String? str2, int maxlen)
→ int
-
Compare two UTF-8 strings, case-insensitively, up to a number of bytes.
-
sdlStrncmp(String? str1, String? str2, int maxlen)
→ int
-
Compare two UTF-8 strings up to a number of bytes.
-
sdlStrndup(String? str, int maxlen)
→ Pointer<Int8>
-
extern SDL_DECLSPEC SDL_MALLOC char * SDLCALL SDL_strndup(const char *str, size_t maxlen)
-
sdlStrnlen(String? str, int maxlen)
→ int
-
This works exactly like strnlen() but doesn't require access to a C
runtime.
-
sdlStrnstr(String? haystack, String? needle, int maxlen)
→ Pointer<Int8>
-
Search a string, up to n bytes, for the first instance of a specific
substring.
-
sdlStrpbrk(String? str, String? breakset)
→ Pointer<Int8>
-
Searches a string for the first occurence of any character contained in a
breakset, and returns a pointer from the string to that character.
-
sdlStrrchr(String? str, int c)
→ Pointer<Int8>
-
Search a string for the last instance of a specific byte.
-
sdlStrrev(Pointer<Int8> str)
→ Pointer<Int8>
-
extern SDL_DECLSPEC char * SDLCALL SDL_strrev(char *str)
-
sdlStrstr(String? haystack, String? needle)
→ Pointer<Int8>
-
Search a string for the first instance of a specific substring.
-
sdlStrtod(String? str, Pointer<Pointer<Int8>> endp)
→ double
-
Parse a
double
from a string.
-
sdlStrtokR(Pointer<Int8> str, String? delim, Pointer<Pointer<Int8>> saveptr)
→ Pointer<Int8>
-
This works exactly like strtok_r() but doesn't require access to a C
runtime.
-
sdlStrtol(String? str, Pointer<Pointer<Int8>> endp, int base)
→ int
-
Parse a
long
from a string.
-
sdlStrtoll(String? str, Pointer<Pointer<Int8>> endp, int base)
→ Pointer<NativeType>
-
Parse a
long long
from a string.
-
sdlStrtoul(String? str, Pointer<Pointer<Int8>> endp, int base)
→ int
-
Parse an
unsigned long
from a string.
-
sdlStrtoull(String? str, Pointer<Pointer<Int8>> endp, int base)
→ Pointer<NativeType>
-
Parse an
unsigned long long
from a string.
-
sdlStrupr(Pointer<Int8> str)
→ Pointer<Int8>
-
Convert a string to uppercase.
-
sdlSwprintf(Pointer<NativeType> arg0, int maxlen, Pointer<Int16> fmt, Pointer<NativeType> arg3)
→ int
-
extern SDL_DECLSPEC int SDLCALL SDL_swprintf(SDL_OUT_Z_CAP(maxlen) wchar_t *text, size_t maxlen, SDL_PRINTF_FORMAT_STRING const wchar_t *fmt, ...) SDL_WPRINTF_VARARG_FUNC(3)
-
sdlTan(double x)
→ double
-
Compute the tangent of
x
.
-
sdlTanf(double x)
→ double
-
Compute the tangent of
x
.
-
sdlTolower(int x)
→ int
-
Convert low-ASCII English letters to lowercase.
-
sdlToupper(int x)
→ int
-
Convert low-ASCII English letters to uppercase.
-
sdlTrunc(double x)
→ double
-
Truncate
x
to an integer.
-
sdlTruncf(double x)
→ double
-
Truncate
x
to an integer.
-
sdlUcs4ToUtf8(int codepoint, Pointer<Int8> dst)
→ Pointer<Int8>
-
Convert a single Unicode codepoint to UTF-8.
-
sdlUitoa(int value, Pointer<Int8> str, int radix)
→ Pointer<Int8>
-
Convert an unsigned integer into a string.
-
sdlUlltoa(Pointer<NativeType> value, Pointer<Int8> str, int radix)
→ Pointer<Int8>
-
Convert an unsigned long long integer into a string.
-
sdlUltoa(int value, Pointer<Int8> str, int radix)
→ Pointer<Int8>
-
Convert an unsigned long integer into a string.
-
sdlUnsetEnvironmentVariable(Pointer<SdlEnvironment> env, String? name)
→ bool
-
Clear a variable from the environment.
-
sdlUnsetenvUnsafe(String? name)
→ int
-
Clear a variable from the environment.
-
sdlUtf8strlcpy(Pointer<NativeType> arg0, String? src, int dstBytes)
→ int
-
Copy an UTF-8 string.
-
sdlUtf8strlen(String? str)
→ int
-
Count the number of codepoints in a UTF-8 string.
-
sdlUtf8strnlen(String? str, int bytes)
→ int
-
Count the number of codepoints in a UTF-8 string, up to n bytes.
-
sdlVasprintf(Pointer<Pointer<Int8>> strp, String? fmt, Pointer<NativeType> arg2)
→ int
-
extern SDL_DECLSPEC int SDLCALL SDL_vasprintf(char **strp, SDL_PRINTF_FORMAT_STRING const char *fmt, va_list ap) SDL_PRINTF_VARARG_FUNCV(2)
-
sdlVsnprintf(Pointer<NativeType> arg0, int maxlen, String? fmt, Pointer<NativeType> arg3)
→ int
-
extern SDL_DECLSPEC int SDLCALL SDL_vsnprintf(SDL_OUT_Z_CAP(maxlen) char *text, size_t maxlen, SDL_PRINTF_FORMAT_STRING const char *fmt, va_list ap) SDL_PRINTF_VARARG_FUNCV(3)
-
sdlVsscanf(String? text, String? fmt, Pointer<NativeType> arg2)
→ int
-
extern SDL_DECLSPEC int SDLCALL SDL_vsscanf(const char *text, SDL_SCANF_FORMAT_STRING const char *fmt, va_list ap) SDL_SCANF_VARARG_FUNCV(2)
-
sdlVswprintf(Pointer<NativeType> arg0, int maxlen, Pointer<Int16> fmt, Pointer<NativeType> arg3)
→ int
-
extern SDL_DECLSPEC int SDLCALL SDL_vswprintf(SDL_OUT_Z_CAP(maxlen) wchar_t *text, size_t maxlen, SDL_PRINTF_FORMAT_STRING const wchar_t *fmt, va_list ap) SDL_WPRINTF_VARARG_FUNCV(3)
-
sdlWcscasecmp(Pointer<Int16> str1, Pointer<Int16> str2)
→ int
-
Compare two null-terminated wide strings, case-insensitively.
-
sdlWcscmp(Pointer<Int16> str1, Pointer<Int16> str2)
→ int
-
Compare two null-terminated wide strings.
-
sdlWcsdup(Pointer<Int16> wstr)
→ Pointer<Int16>
-
extern SDL_DECLSPEC wchar_t * SDLCALL SDL_wcsdup(const wchar_t *wstr)
-
sdlWcslcat(Pointer<NativeType> arg0, Pointer<Int16> src, int maxlen)
→ int
-
Concatenate wide strings.
-
sdlWcslcpy(Pointer<NativeType> arg0, Pointer<Int16> src, int maxlen)
→ int
-
Copy a wide string.
-
sdlWcslen(Pointer<Int16> wstr)
→ int
-
extern SDL_DECLSPEC size_t SDLCALL SDL_wcslen(const wchar_t *wstr)
-
sdlWcsncasecmp(Pointer<Int16> str1, Pointer<Int16> str2, int maxlen)
→ int
-
Compare two wide strings, case-insensitively, up to a number of wchar_t.
-
sdlWcsncmp(Pointer<Int16> str1, Pointer<Int16> str2, int maxlen)
→ int
-
Compare two wide strings up to a number of wchar_t values.
-
sdlWcsnlen(Pointer<Int16> wstr, int maxlen)
→ int
-
extern SDL_DECLSPEC size_t SDLCALL SDL_wcsnlen(const wchar_t *wstr, size_t maxlen)
-
sdlWcsnstr(Pointer<Int16> haystack, Pointer<Int16> needle, int maxlen)
→ Pointer<Int16>
-
extern SDL_DECLSPEC wchar_t * SDLCALL SDL_wcsnstr(const wchar_t *haystack, const wchar_t *needle, size_t maxlen)
-
sdlWcsstr(Pointer<Int16> haystack, Pointer<Int16> needle)
→ Pointer<Int16>
-
extern SDL_DECLSPEC wchar_t * SDLCALL SDL_wcsstr(const wchar_t *haystack, const wchar_t *needle)
-
sdlWcstol(Pointer<Int16> str, Pointer<Pointer<Int16>> endp, int base)
→ int
-
Parse a
long
from a wide string.