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.

DistrhoUI3BandEQ.hpp 2.6KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. /*
  2. * DISTRHO 3BandEQ Plugin, based on 3BandEQ by Michael Gruhn
  3. * Copyright (C) 2012-2014 Filipe Coelho <falktx@falktx.com>
  4. *
  5. * This program is free software; you can redistribute it and/or
  6. * modify it under the terms of the GNU Lesser General Public
  7. * License as published by the Free Software Foundation.
  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 Lesser General Public License for more details.
  13. *
  14. * For a full copy of the license see the LICENSE file.
  15. */
  16. #ifndef DISTRHO_UI_3BANDEQ_HPP_INCLUDED
  17. #define DISTRHO_UI_3BANDEQ_HPP_INCLUDED
  18. #include "DistrhoUI.hpp"
  19. #include "ImageAboutWindow.hpp"
  20. #include "ImageButton.hpp"
  21. #include "ImageKnob.hpp"
  22. #include "ImageSlider.hpp"
  23. #include "DistrhoArtwork3BandEQ.hpp"
  24. using DGL::Image;
  25. using DGL::ImageAboutWindow;
  26. using DGL::ImageButton;
  27. using DGL::ImageKnob;
  28. using DGL::ImageSlider;
  29. START_NAMESPACE_DISTRHO
  30. // -----------------------------------------------------------------------
  31. class DistrhoUI3BandEQ : public UI,
  32. public ImageButton::Callback,
  33. public ImageKnob::Callback,
  34. public ImageSlider::Callback
  35. {
  36. public:
  37. DistrhoUI3BandEQ();
  38. protected:
  39. // -------------------------------------------------------------------
  40. // DSP Callbacks
  41. void d_parameterChanged(uint32_t index, float value) override;
  42. void d_programChanged(uint32_t index) override;
  43. // -------------------------------------------------------------------
  44. // Widget Callbacks
  45. void imageButtonClicked(ImageButton* button, int) override;
  46. void imageKnobDragStarted(ImageKnob* knob) override;
  47. void imageKnobDragFinished(ImageKnob* knob) override;
  48. void imageKnobValueChanged(ImageKnob* knob, float value) override;
  49. void imageSliderDragStarted(ImageSlider* slider) override;
  50. void imageSliderDragFinished(ImageSlider* slider) override;
  51. void imageSliderValueChanged(ImageSlider* slider, float value) override;
  52. void onDisplay() override;
  53. private:
  54. Image fImgBackground;
  55. ImageAboutWindow fAboutWindow;
  56. ScopedPointer<ImageButton> fButtonAbout;
  57. ScopedPointer<ImageKnob> fKnobLowMid, fKnobMidHigh;
  58. ScopedPointer<ImageSlider> fSliderLow, fSliderMid, fSliderHigh, fSliderMaster;
  59. DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(DistrhoUI3BandEQ)
  60. };
  61. // -----------------------------------------------------------------------
  62. END_NAMESPACE_DISTRHO
  63. #endif // DISTRHO_UI_3BANDEQ_HPP_INCLUDED