Commit Graph

6 Commits

Author SHA1 Message Date
Donny Lawrence 28711814e7 device: Replace erroneous && with ||. 2020-01-15 16:04:37 -06:00
rdb 7ed8b01a84 Merge branch 'input-overhaul' 2018-11-30 22:04:13 +01:00
rdb 8edc019307 device: overhaul InputDevice API:
- Rename "controls" terminology for analog inputs to "axes"
- Change some naming of accessors
- Unexpose methods where they are available as properties
- Add serial_number field
- Put battery levels under a "battery" field
2018-09-16 20:22:22 +02:00
rdb ba2de46beb Merge branch 'master' into input-overhaul 2018-06-08 15:23:47 +02:00
rdb 8bd617c4ee input: new windows input manager based on raw input
The new implementation uses a message-only window to register raw input events.

XInput is still used when possible, but raw input is being used to handle device detection.  (XInput is only enabled when an XInput device is plugged in, which also prevents us from having to load and poll the XInput library unnecessarily.)

For raw devices, the Windows HID parser library is used to parse the raw data.  Unfortunately, the Windows 7.1 SDK does not ship hid.lib (which is in the WDK 7.1.0), so I am dynamically loading hid.dll to prevent pulling in a dependency on the WDK.  (But perhaps we can ship hid.lib in the thirdparty libraries?)

Input devices other than XInput gamepads and the 3D mouse have not been tested very well yet.  Adding keyboard and mouse support is still a TODO.

This also splits out the Windows implementation of InputDeviceManager into a separate subclass; it is intended that the other implementations will follow suit.
2018-01-22 22:05:14 +01:00
fireclawthefox ef7cc925c4 Add data graph node for devices
Add the new inputDeviceNode class to be used in the data graph
Add config variable for low batery level
2016-07-21 23:09:09 +02:00