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.

76 lines
2.2KB

  1. /*
  2. * Wobble Juice Plugin
  3. * Copyright (C) 2014 Andre Sklenar <andre.sklenar@gmail.com>, www.juicelab.cz
  4. *
  5. * This program is free software; you can redistribute it and/or
  6. * modify it under the terms of the GNU General Public License as
  7. * published by the Free Software Foundation; either version 2 of
  8. * the License, or any later version.
  9. *
  10. * This program is distributed in the hope that it will be useful,
  11. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. * GNU General Public License for more details.
  14. *
  15. * For a full copy of the GNU General Public License see the doc/GPL.txt file.
  16. */
  17. #ifndef WOBBLEJUICEUI_HPP_INCLUDED
  18. #define WOBBLEJUICEUI_HPP_INCLUDED
  19. #include "DistrhoUI.hpp"
  20. #include "ImageWidgets.hpp"
  21. #include "WobbleJuiceArtwork.hpp"
  22. using DGL::Image;
  23. using DGL::ImageAboutWindow;
  24. using DGL::ImageButton;
  25. using DGL::ImageKnob;
  26. START_NAMESPACE_DISTRHO
  27. // -----------------------------------------------------------------------
  28. class WobbleJuiceUI : public UI,
  29. public ImageButton::Callback,
  30. public ImageKnob::Callback
  31. {
  32. public:
  33. WobbleJuiceUI();
  34. protected:
  35. // -------------------------------------------------------------------
  36. // DSP Callbacks
  37. void parameterChanged(uint32_t index, float value) override;
  38. void programLoaded(uint32_t index) override;
  39. // -------------------------------------------------------------------
  40. // Widget Callbacks
  41. void imageButtonClicked(ImageButton* button, int) override;
  42. void imageKnobDragStarted(ImageKnob* knob) override;
  43. void imageKnobDragFinished(ImageKnob* knob) override;
  44. void imageKnobValueChanged(ImageKnob* knob, float value) override;
  45. void onDisplay() override;
  46. private:
  47. Image fImgBackground;
  48. ImageAboutWindow fAboutWindow;
  49. ScopedPointer<ImageButton> fButtonAbout;
  50. ScopedPointer<ImageKnob> fKnobDivision, fKnobResonance, fKnobRange;
  51. ScopedPointer<ImageKnob> fKnobPhase, fKnobWave, fKnobDrive;
  52. DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(WobbleJuiceUI)
  53. };
  54. // -----------------------------------------------------------------------
  55. END_NAMESPACE_DISTRHO
  56. #endif // WOBBLEJUICEUI_HPP_INCLUDED