You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

bridge.hpp 732B

6 years ago
12345678910111213141516171819202122232425262728293031
  1. #pragma once
  2. #include "bridgeprotocol.hpp"
  3. #include "audio.hpp"
  4. #include "midi.hpp"
  5. namespace rack {
  6. struct BridgeMidiInputDevice : MidiInputDevice {
  7. };
  8. struct BridgeMidiDriver : MidiDriver {
  9. BridgeMidiInputDevice devices[16];
  10. std::string getName() override {return "Bridge";}
  11. std::vector<int> getInputDeviceIds() override;
  12. std::string getInputDeviceName(int deviceId) override;
  13. MidiInputDevice *subscribeInputDevice(int deviceId, MidiInput *midiInput) override;
  14. void unsubscribeInputDevice(int deviceId, MidiInput *midiInput) override;
  15. };
  16. void bridgeInit();
  17. void bridgeDestroy();
  18. void bridgeAudioSubscribe(int channel, AudioIO *audio);
  19. void bridgeAudioUnsubscribe(int channel, AudioIO *audio);
  20. } // namespace rack