's picture

Joystick buttons

I'm using OpenTK as input interface for joystick. But I use a 32 buttons and 8 axis device. Why I can't detect all buttons? In OpenTK.Input.JoystickButton class there are only 16 buttons declared. Why? I think the problem is not only what classes I need to change to use 32 buttons?
Thanks in advance!


Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
the Fiddler's picture

There is no architectural limitation for >16 buttons, it's just that I don't have any devices to test with.

For up to 32 buttons, simply add the missing values to the JoystickButton enumeration, and change JoystickButton.Last to Button31 instead of Button15.

If you do so, please send a pull request to so everyone can benefit.