Assists music production by grouping standalone programs into sessions. Community version of "Non Session Manager".
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.

88 lines
2.8KB

  1. /*******************************************************************************/
  2. /* Copyright (C) 2009 Jonathan Moore Liles */
  3. /* */
  4. /* This program is free software; you can redistribute it and/or modify it */
  5. /* under the terms of the GNU General Public License as published by the */
  6. /* Free Software Foundation; either version 2 of the License, or (at your */
  7. /* option) any later version. */
  8. /* */
  9. /* This program is distributed in the hope that it will be useful, but WITHOUT */
  10. /* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */
  11. /* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for */
  12. /* more details. */
  13. /* */
  14. /* You should have received a copy of the GNU General Public License along */
  15. /* with This program; see the file COPYING. If not,write to the Free Software */
  16. /* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
  17. /*******************************************************************************/
  18. #pragma once
  19. class Fl_Box;
  20. class Fl_Browser;
  21. #include "Module.H"
  22. #include "JACK/Port.H"
  23. #include <vector>
  24. class JACK_Module : public Module
  25. {
  26. char *_prefix;
  27. protected:
  28. void prefix ( const char *s )
  29. {
  30. if ( _prefix )
  31. free( _prefix );
  32. _prefix = NULL;
  33. if ( s )
  34. _prefix = strdup( s );
  35. }
  36. Fl_Button * dec_button;
  37. Fl_Button * inc_button;
  38. Fl_Browser * connection_display;
  39. Fl_Box * input_connection_handle;
  40. Fl_Box * output_connection_handle;
  41. Fl_Box * output_connection2_handle;
  42. static void cb_button ( Fl_Widget *w, void *v );
  43. void cb_button ( Fl_Widget *w );
  44. protected:
  45. unsigned int _connection_handle_outputs[2][2];
  46. public:
  47. void update_connection_status ( void );
  48. JACK_Module ( bool log = true );
  49. virtual ~JACK_Module ( );
  50. virtual const char *basename ( void ) const { return "JACK"; }
  51. virtual const char *name ( void ) const { return "JACK"; }
  52. virtual bool initialize ( void );
  53. virtual void draw ( void );
  54. virtual int handle ( int m );
  55. virtual int can_support_inputs ( int );
  56. void remove_aux_audio_outputs ( void );
  57. virtual bool configure_inputs ( int n );
  58. virtual bool configure_outputs ( int n );
  59. virtual void handle_control_changed ( Port *p );
  60. LOG_CREATE_FUNC( JACK_Module );
  61. protected:
  62. virtual void process ( nframes_t nframes );
  63. };