sdlGameControllerMappingForGuid function

Pointer<Int8> sdlGameControllerMappingForGuid(
  1. SdlGuid guid
)

Get the game controller mapping string for a given GUID.

The returned string must be freed with SDL_free().

\param guid a structure containing the GUID for which a mapping is desired \returns a mapping string or NULL on error; call SDL_GetError() for more information.

\since This function is available since SDL 2.0.0.

\sa SDL_JoystickGetDeviceGUID \sa SDL_JoystickGetGUID

extern DECLSPEC char * SDLCALL SDL_GameControllerMappingForGUID(SDL_JoystickGUID guid)

Implementation

Pointer<Int8> sdlGameControllerMappingForGuid(SdlGuid guid) {
  final sdlGameControllerMappingForGuidLookupFunction = libSdl2.lookupFunction<
      Pointer<Int8> Function(SdlGuid guid),
      Pointer<Int8> Function(SdlGuid guid)>('SDL_GameControllerMappingForGUID');
  return sdlGameControllerMappingForGuidLookupFunction(guid);
}