sdlHidClose function hidapi

int sdlHidClose(
  1. Pointer<SdlHidDevice> dev
)

Close a HID device.

\param dev a device handle returned from SDL_hid_open(). \returns 0 on success or a negative error code on failure; call SDL_GetError() for more information.

\since This function is available since SDL 3.2.0.

extern SDL_DECLSPEC int SDLCALL SDL_hid_close(SDL_hid_device *dev)

Implementation

int sdlHidClose(Pointer<SdlHidDevice> dev) {
  final sdlHidCloseLookupFunction = _libSdl
      .lookupFunction<
        Int32 Function(Pointer<SdlHidDevice> dev),
        int Function(Pointer<SdlHidDevice> dev)
      >('SDL_hid_close');
  return sdlHidCloseLookupFunction(dev);
}