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.

100 lines
3.3KB

  1. /* SpiralPlugin
  2. * Copyleft (C) 2000 David Griffiths <dave@pawfal.org>
  3. *
  4. * This program is free software; you can redistribute it and/or modify
  5. * it under the terms of the GNU General Public License as published by
  6. * the Free Software Foundation; either version 2 of the License, or
  7. * (at your option) any later version.
  8. *
  9. * This program is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. * GNU General Public License for more details.
  13. *
  14. * You should have received a copy of the GNU General Public License
  15. * along with this program; if not, write to the Free Software
  16. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  17. */
  18. #include <FL/Fl_Check_Button.H>
  19. #include <FL/Fl_Pixmap.H>
  20. #include <FL/Fl_Slider.H>
  21. #include <FL/Fl_Output.H>
  22. #include <FL/Fl_Box.H>
  23. #include "../Widgets/Fl_Knob.H"
  24. #include "../SpiralPluginGUI.h"
  25. #include "WaveTablePlugin.h"
  26. #ifndef SCOPEGUI
  27. #define SCOPEGUI
  28. class WaveTablePluginGUI : public SpiralPluginGUI
  29. {
  30. public:
  31. WaveTablePluginGUI(int w, int h, SpiralPlugin *o, ChannelHandler *ch, const HostInfo *Info);
  32. virtual void UpdateValues(SpiralPlugin* o);
  33. protected:
  34. const string GetHelpText(const string &loc);
  35. private:
  36. Fl_Check_Button *ShapeSquare;
  37. Fl_Pixmap pixmap_Square;
  38. Fl_Check_Button *ShapeSaw;
  39. Fl_Pixmap pixmap_Saw;
  40. Fl_Check_Button *ShapeRevSaw;
  41. Fl_Pixmap pixmap_RevSaw;
  42. Fl_Check_Button *ShapeTri;
  43. Fl_Pixmap pixmap_Tri;
  44. Fl_Check_Button *ShapeSine;
  45. Fl_Pixmap pixmap_Sine;
  46. Fl_Check_Button *Pulse1;
  47. Fl_Pixmap pixmap_Pulse1;
  48. Fl_Check_Button *Pulse2;
  49. Fl_Pixmap pixmap_Pulse2;
  50. Fl_Check_Button *ShapeInvSine;
  51. Fl_Pixmap pixmap_InvSine;
  52. Fl_Knob *Freq;
  53. Fl_Knob *ModAmount;
  54. Fl_Knob *FineTune;
  55. Fl_Button *m_pop;
  56. Fl_Output *m_out_freq;
  57. Fl_Output *m_out_mod;
  58. float m_FineFreq;
  59. int m_Octave;
  60. //// Callbacks ////
  61. inline void cb_Freq_i(Fl_Knob* o, void* v);
  62. static void cb_Freq(Fl_Knob*, void*);
  63. inline void cb_FineTune_i(Fl_Knob* o, void* v);
  64. static void cb_FineTune(Fl_Knob* o, void* v);
  65. inline void cb_ModAmount_i(Fl_Knob* o, void* v);
  66. static void cb_ModAmount(Fl_Knob* o, void* v);
  67. inline void cb_Square_i(Fl_Check_Button* o, void* v);
  68. static void cb_Square(Fl_Check_Button*, void*);
  69. inline void cb_Saw_i(Fl_Check_Button* o, void* v);
  70. static void cb_Saw(Fl_Check_Button*, void*);
  71. inline void cb_Sine_i(Fl_Check_Button* o, void* v);
  72. static void cb_Sine(Fl_Check_Button* o, void* v);
  73. inline void cb_RevSaw_i(Fl_Check_Button* o, void* v);
  74. static void cb_RevSaw(Fl_Check_Button* o, void* v);
  75. inline void cb_Tri_i(Fl_Check_Button* o, void* v);
  76. static void cb_Tri(Fl_Check_Button* o, void* v);
  77. inline void cb_Pulse1_i(Fl_Check_Button* o, void* v);
  78. static void cb_Pulse1(Fl_Check_Button* o, void* v);
  79. inline void cb_Pulse2_i(Fl_Check_Button* o, void* v);
  80. static void cb_Pulse2(Fl_Check_Button* o, void* v);
  81. inline void cb_InvSine_i(Fl_Check_Button* o, void* v);
  82. static void cb_InvSine(Fl_Check_Button* o, void* v);
  83. inline void cb_pop_i(Fl_Button* o, void*);
  84. static void cb_pop(Fl_Button* o, void*);
  85. };
  86. #endif