sdlGetGamepadMappingForGuid function

Pointer<Int8> sdlGetGamepadMappingForGuid(
  1. SdlGuid guid
)

Get the gamepad mapping string for a given GUID.

\param guid a structure containing the GUID for which a mapping is desired. \returns a mapping string or NULL on failure; call SDL_GetError() for more information. This should be freed with SDL_free() when it is no longer needed.

\since This function is available since SDL 3.1.3.

\sa SDL_GetJoystickGUIDForID \sa SDL_GetJoystickGUID

extern SDL_DECLSPEC char * SDLCALL SDL_GetGamepadMappingForGUID(SDL_GUID guid)

Implementation

Pointer<Int8> sdlGetGamepadMappingForGuid(SdlGuid guid) {
  final sdlGetGamepadMappingForGuidLookupFunction = libSdl3.lookupFunction<
      Pointer<Int8> Function(SdlGuid guid),
      Pointer<Int8> Function(SdlGuid guid)>('SDL_GetGamepadMappingForGUID');
  return sdlGetGamepadMappingForGuidLookupFunction(guid);
}