HID: use AnalogDevice

This commit is contained in:
wwylele 2017-01-20 23:58:03 +02:00
parent 1d1329af23
commit 70420272ca
3 changed files with 30 additions and 2 deletions

View file

@ -100,4 +100,11 @@ std::unique_ptr<InputDeviceType> CreateDevice(const std::string& params) {
*/
using ButtonDevice = InputDevice<bool>;
/**
* An analog device is an input device that returns a tuple of x and y coordinates as status. The
* coordinates are within the unit circle. x+ is defined as right direction, and y+ is defined as up
* direction
*/
using AnalogDevice = InputDevice<std::tuple<float, float>>;
} // namespace Input