LuanRoger / xinput_gamepad

🎮 Add support to XInput controllers with Win32 API.
https://pub.dev/packages/xinput_gamepad
MIT License
6 stars 2 forks source link

Add Linux support #8

Open natandiasm opened 1 year ago

natandiasm commented 1 year ago

Add Linux support for this lib?

LuanRoger commented 1 year ago

The lib is using the Win32 API to get XInput commands, so it's not supported Linux at all. A way to implement Linux support is adding some other API/library to act side-by-side with the Windows one, but this can be hard to maintain.

So a better way to make the things work is implementing a lib that support both, and a lib that can fit the job is SDL. This approach will not only implement Linux support, but MacOS and even Android. For now I'm not plaining to implement more OSs support, but I'm not gonna close this issue because some day I'm will implement.