1 #ifndef MSP_INPUT_INPUTHUB_H_
2 #define MSP_INPUT_INPUTHUB_H_
10 The Hub device collects events from multiple input devices and presents an
11 aggregate of them. Button and axis numbers are mapped to unique values.
13 class Hub: public Device
16 std::vector<Device *> devices;
21 /** Attaches an input device to the hub. Returns the index of the device
23 unsigned attach(Device &dev);
25 virtual std::string get_button_name(unsigned) const;
26 virtual std::string get_axis_name(unsigned) const;
28 void button_press(unsigned, unsigned);
29 void button_release(unsigned, unsigned);
30 void axis_motion(unsigned, float, float, unsigned);