sdlEnumerateProperties function
bool
sdlEnumerateProperties(
- int props,
- Pointer<
NativeFunction< callback,SdlEnumeratePropertiesCallback> > - Pointer<
NativeType> userdata
Enumerate the properties contained in a group of properties.
The callback function is called for each property in the group of properties. The properties are locked during enumeration.
\param props the properties to query.
\param callback the function to call for each property.
\param userdata a pointer that is passed to callback
.
\returns true on success or false on failure; call SDL_GetError() for more
information.
\threadsafety It is safe to call this function from any thread.
\since This function is available since SDL 3.1.3.
extern SDL_DECLSPEC bool SDLCALL SDL_EnumerateProperties(SDL_PropertiesID props, SDL_EnumeratePropertiesCallback callback, void *userdata)
Implementation
bool sdlEnumerateProperties(
int props,
Pointer<NativeFunction<SdlEnumeratePropertiesCallback>> callback,
Pointer<NativeType> userdata) {
final sdlEnumeratePropertiesLookupFunction = libSdl3.lookupFunction<
Uint8 Function(
Uint32 props,
Pointer<NativeFunction<SdlEnumeratePropertiesCallback>> callback,
Pointer<NativeType> userdata),
int Function(
int props,
Pointer<NativeFunction<SdlEnumeratePropertiesCallback>> callback,
Pointer<NativeType> userdata)>('SDL_EnumerateProperties');
return sdlEnumeratePropertiesLookupFunction(props, callback, userdata) == 1;
}