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.

jclient.h 1.9KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. // ----------------------------------------------------------------------
  2. //
  3. // Copyright (C) 2010 Fons Adriaensen <fons@linuxaudio.org>
  4. // Modified by falkTX on Jan-Apr 2015 for inclusion in Carla
  5. //
  6. // This program is free software; you can redistribute it and/or modify
  7. // it under the terms of the GNU General Public License as published by
  8. // the Free Software Foundation; either version 2 of the License, or
  9. // (at your option) any later version.
  10. //
  11. // This program is distributed in the hope that it will be useful,
  12. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. // GNU General Public License for more details.
  15. //
  16. // You should have received a copy of the GNU General Public License
  17. // along with this program; if not, write to the Free Software
  18. // Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  19. //
  20. // ----------------------------------------------------------------------
  21. #ifndef __JCLIENT_H
  22. #define __JCLIENT_H
  23. #include <clthreads.h>
  24. #include "CarlaNativeJack.h"
  25. #include "global.h"
  26. #include "reverb.h"
  27. namespace REV1 {
  28. class Jclient : public A_thread
  29. {
  30. public:
  31. Jclient (jack_client_t *jclient, bool ambis);
  32. ~Jclient (void);
  33. Reverb *reverb (void) const { return (Reverb *) &_reverb; }
  34. private:
  35. void init_jack (void);
  36. void close_jack (void);
  37. void jack_shutdown (void);
  38. int jack_process (int nframes);
  39. virtual void thr_main (void) {}
  40. jack_client_t *_jack_client;
  41. jack_port_t *_inpports [2];
  42. jack_port_t *_outports [4];
  43. bool _active;
  44. unsigned int _fsamp;
  45. bool _ambis;
  46. int _fragm;
  47. int _nsamp;
  48. Reverb _reverb;
  49. static void jack_static_shutdown (void *arg);
  50. static int jack_static_process (jack_nframes_t nframes, void *arg);
  51. };
  52. }
  53. #endif