Audio plugin host https://kx.studio/carla
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.

54 lines
1.2KB

  1. #ifndef NIO_H
  2. #define NIO_H
  3. #include <string>
  4. #include <set>
  5. class WavFile;
  6. class Master;
  7. struct SYNTH_T;
  8. class oss_devs_t;
  9. /**Interface to Nio Subsystem
  10. *
  11. * Should be only externally included header */
  12. namespace Nio
  13. {
  14. void init(const SYNTH_T &synth, const oss_devs_t &oss_devs, Master *master);
  15. bool start(void);
  16. void stop(void);
  17. void setDefaultSource(std::string name);
  18. void setDefaultSink(std::string name);
  19. bool setSource(std::string name);
  20. bool setSink(std::string name);
  21. void setPostfix(std::string post);
  22. std::string getPostfix(void);
  23. std::set<std::string> getSources(void);
  24. std::set<std::string> getSinks(void);
  25. std::string getSource(void);
  26. std::string getSink(void);
  27. //Get the prefered sample rate from jack (if running)
  28. void preferedSampleRate(unsigned &rate);
  29. //Complete Master Swaps to ONLY BE CALLED FROM RT CONTEXT
  30. void masterSwap(Master *master);
  31. //Wave writing
  32. void waveNew(class WavFile *wave);
  33. void waveStart(void);
  34. void waveStop(void);
  35. void waveEnd(void);
  36. extern bool autoConnect;
  37. extern bool pidInClientName;
  38. extern std::string defaultSource;
  39. extern std::string defaultSink;
  40. };
  41. #endif