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.

ivsttestplugprovider.h 4.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. //-----------------------------------------------------------------------------
  2. // Flags : clang-format SMTGSequencer
  3. // Project : VST SDK
  4. //
  5. // Category : Validator
  6. // Filename : public.sdk/source/vst/testsuite/iplugprovider.h
  7. // Created by : Steinberg, 04/2005
  8. // Description : VST Test Suite
  9. //
  10. //-----------------------------------------------------------------------------
  11. // LICENSE
  12. // (c) 2020, Steinberg Media Technologies GmbH, All Rights Reserved
  13. //-----------------------------------------------------------------------------
  14. // Redistribution and use in source and binary forms, with or without modification,
  15. // are permitted provided that the following conditions are met:
  16. //
  17. // * Redistributions of source code must retain the above copyright notice,
  18. // this list of conditions and the following disclaimer.
  19. // * Redistributions in binary form must reproduce the above copyright notice,
  20. // this list of conditions and the following disclaimer in the documentation
  21. // and/or other materials provided with the distribution.
  22. // * Neither the name of the Steinberg Media Technologies nor the names of its
  23. // contributors may be used to endorse or promote products derived from this
  24. // software without specific prior written permission.
  25. //
  26. // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
  27. // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
  28. // WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  29. // IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
  30. // INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
  31. // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  32. // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
  33. // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
  34. // OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
  35. // OF THE POSSIBILITY OF SUCH DAMAGE.
  36. //-----------------------------------------------------------------------------
  37. #pragma once
  38. #include "pluginterfaces/base/istringresult.h"
  39. #include "pluginterfaces/vst/ivstcomponent.h"
  40. #include "pluginterfaces/vst/ivsteditcontroller.h"
  41. //------------------------------------------------------------------------
  42. namespace Steinberg {
  43. namespace Vst {
  44. //------------------------------------------------------------------------
  45. /** Test Helper.
  46. * \ingroup TestClass
  47. *
  48. * This class provides access to the component and the controller of a plug-in when running a unit
  49. * test (see ITest).
  50. * You get this interface as the context argument in the ITestFactory::createTests method.
  51. */
  52. //------------------------------------------------------------------------
  53. class ITestPlugProvider : public FUnknown
  54. {
  55. public:
  56. //------------------------------------------------------------------------
  57. /** get the component of the plug-in.
  58. *
  59. * The reference count of the component is increased in this function and you need to call
  60. * releasePlugIn when done with the component.
  61. */
  62. virtual IComponent* PLUGIN_API getComponent () = 0;
  63. /** get the controller of the plug-in.
  64. *
  65. * The reference count of the controller is increased in this function and you need to call
  66. * releasePlugIn when done with the controller.
  67. */
  68. virtual IEditController* PLUGIN_API getController () = 0;
  69. /** release the component and/or controller */
  70. virtual tresult PLUGIN_API releasePlugIn (IComponent* component,
  71. IEditController* controller) = 0;
  72. /** get the sub categories of the plug-in */
  73. virtual tresult PLUGIN_API getSubCategories (IStringResult& result) const = 0;
  74. /** get the component UID of the plug-in */
  75. virtual tresult PLUGIN_API getComponentUID (FUID& uid) const = 0;
  76. //------------------------------------------------------------------------
  77. static const FUID iid;
  78. };
  79. DECLARE_CLASS_IID (ITestPlugProvider, 0x86BE70EE, 0x4E99430F, 0x978F1E6E, 0xD68FB5BA)
  80. //------------------------------------------------------------------------
  81. /** Test Helper extension.
  82. * \ingroup TestClass
  83. */
  84. class ITestPlugProvider2 : public ITestPlugProvider
  85. {
  86. public:
  87. /** get the plugin factory.
  88. *
  89. * The reference count of the returned factory object is not increased when calling this
  90. * function.
  91. */
  92. virtual IPluginFactory* PLUGIN_API getPluginFactory () = 0;
  93. //------------------------------------------------------------------------
  94. static const FUID iid;
  95. };
  96. DECLARE_CLASS_IID (ITestPlugProvider2, 0xC7C75364, 0x7B8343AC, 0xA4495B0A, 0x3E5A46C7)
  97. //------------------------------------------------------------------------
  98. } // Vst
  99. } // Steinberg