getMappingForGuid static method

Pointer<Int8> getMappingForGuid(
  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.

\threadsafety It is safe to call this function from any thread.

\since This function is available since SDL 3.2.0.

\sa SDL_GetJoystickGUIDForID \sa SDL_GetJoystickGUID

extern SDL_DECLSPEC char * SDLCALL SDL_GetGamepadMappingForGUID(SDL_GUID guid)

{@category gamepad}

Implementation

static Pointer<Int8> getMappingForGuid(SdlGuid guid) =>
    sdlGetGamepadMappingForGuid(guid);