sdlJoystickGetDeviceGuid function

SdlGuid sdlJoystickGetDeviceGuid(
  1. int deviceIndex
)

Get the implementation-dependent GUID for the joystick at a given device index.

This function can be called before any joysticks are opened.

\param device_index the index of the joystick to query (the N'th joystick on the system \returns the GUID of the selected joystick. If called on an invalid index, this function returns a zero GUID

\since This function is available since SDL 2.0.0.

\sa SDL_JoystickGetGUID \sa SDL_JoystickGetGUIDString

extern DECLSPEC SDL_JoystickGUID SDLCALL SDL_JoystickGetDeviceGUID(int device_index)

Implementation

SdlGuid sdlJoystickGetDeviceGuid(int deviceIndex) {
  final sdlJoystickGetDeviceGuidLookupFunction = libSdl2.lookupFunction<
      SdlGuid Function(Int32 deviceIndex),
      SdlGuid Function(int deviceIndex)>('SDL_JoystickGetDeviceGUID');
  return sdlJoystickGetDeviceGuidLookupFunction(deviceIndex);
}