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.

100 lines
2.8KB

  1. /*
  2. * DISTRHO MVerb, a DPF'ied MVerb.
  3. * Copyright (c) 2010 Martin Eastwood
  4. * Copyright (C) 2014 Filipe Coelho <falktx@falktx.com>
  5. *
  6. * This program is free software; you can redistribute it and/or
  7. * modify it under the terms of the GNU General Public License as
  8. * published by the Free Software Foundation; either version 3 of
  9. * the License, or 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. * For a full copy of the GNU General Public License see the LICENSE file.
  17. */
  18. #ifndef DISTRHO_PLUGIN_MVERB_HPP_INCLUDED
  19. #define DISTRHO_PLUGIN_MVERB_HPP_INCLUDED
  20. #include "DistrhoPlugin.hpp"
  21. #include "MVerb.h"
  22. START_NAMESPACE_DISTRHO
  23. // -----------------------------------------------------------------------
  24. class DistrhoPluginMVerb : public Plugin
  25. {
  26. public:
  27. DistrhoPluginMVerb();
  28. protected:
  29. // -------------------------------------------------------------------
  30. // Information
  31. const char* d_getLabel() const noexcept override
  32. {
  33. return "MVerb";
  34. }
  35. const char* d_getMaker() const noexcept override
  36. {
  37. return "Martin Eastwood, falkTX";
  38. }
  39. const char* d_getLicense() const noexcept override
  40. {
  41. return "GPL v3+";
  42. }
  43. uint32_t d_getVersion() const noexcept override
  44. {
  45. return 0x1000;
  46. }
  47. int64_t d_getUniqueId() const noexcept override
  48. {
  49. return d_cconst('M', 'V', 'r', 'b');
  50. }
  51. // -------------------------------------------------------------------
  52. // Init
  53. void d_initParameter(uint32_t index, Parameter& parameter) override;
  54. void d_initProgramName(uint32_t index, d_string& programName) override;
  55. // -------------------------------------------------------------------
  56. // Internal data
  57. float d_getParameterValue(uint32_t index) const override;
  58. void d_setParameterValue(uint32_t index, float value) override;
  59. void d_setProgram(uint32_t index) override;
  60. // -------------------------------------------------------------------
  61. // Process
  62. void d_activate() override;
  63. void d_run(const float** inputs, float** outputs, uint32_t frames) override;
  64. // -------------------------------------------------------------------
  65. // Callbacks
  66. void d_sampleRateChanged(double newSampleRate) override;
  67. // -------------------------------------------------------------------
  68. private:
  69. MVerb<float> fVerb;
  70. DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(DistrhoPluginMVerb)
  71. };
  72. // -----------------------------------------------------------------------
  73. END_NAMESPACE_DISTRHO
  74. #endif // DISTRHO_PLUGIN_MVERB_HPP_INCLUDED