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.

164 lines
5.7KB

  1. //------------------------------------------------------------------------
  2. // Project : VST SDK
  3. //
  4. // Category : Interfaces
  5. // Filename : pluginterfaces/vst/ivsthostapplication.h
  6. // Created by : Steinberg, 04/2006
  7. // Description : VST Host Interface
  8. //
  9. //-----------------------------------------------------------------------------
  10. // This file is part of a Steinberg SDK. It is subject to the license terms
  11. // in the LICENSE file found in the top-level directory of this distribution
  12. // and at www.steinberg.net/sdklicenses.
  13. // No part of the SDK, including this file, may be copied, modified, propagated,
  14. // or distributed except according to the terms contained in the LICENSE file.
  15. //-----------------------------------------------------------------------------
  16. #pragma once
  17. #include "pluginterfaces/vst/ivstmessage.h"
  18. //------------------------------------------------------------------------
  19. namespace Steinberg {
  20. namespace Vst {
  21. //------------------------------------------------------------------------
  22. /** Basic host callback interface: Vst::IHostApplication
  23. \ingroup vstIHost vst300
  24. - [host imp]
  25. - [passed as 'context' in to IPluginBase::initialize () ]
  26. - [released: 3.0.0]
  27. - [mandatory]
  28. Basic VST host application interface.
  29. */
  30. class IHostApplication : public FUnknown
  31. {
  32. public:
  33. //------------------------------------------------------------------------
  34. /** Gets host application name. */
  35. virtual tresult PLUGIN_API getName (String128 name) = 0;
  36. /** Creates host object (e.g. Vst::IMessage). */
  37. virtual tresult PLUGIN_API createInstance (TUID cid, TUID _iid, void** obj) = 0;
  38. //------------------------------------------------------------------------
  39. static const FUID iid;
  40. };
  41. DECLARE_CLASS_IID (IHostApplication, 0x58E595CC, 0xDB2D4969, 0x8B6AAF8C, 0x36A664E5)
  42. //------------------------------------------------------------------------
  43. /** Helper to allocate a message */
  44. inline IMessage* allocateMessage (IHostApplication* host)
  45. {
  46. TUID iid;
  47. IMessage::iid.toTUID (iid);
  48. IMessage* m = nullptr;
  49. if (host->createInstance (iid, iid, (void**)&m) == kResultOk)
  50. return m;
  51. return nullptr;
  52. }
  53. //------------------------------------------------------------------------
  54. /** VST 3 to VST 2 Wrapper interface: Vst::IVst3ToVst2Wrapper
  55. \ingroup vstIHost vst310
  56. - [host imp]
  57. - [passed as 'context' to IPluginBase::initialize () ]
  58. - [released: 3.1.0]
  59. - [mandatory]
  60. Informs the plug-in that a VST 3 to VST 2 wrapper is used between the plug-in and the real host.
  61. Implemented by the VST 2 Wrapper.
  62. */
  63. class IVst3ToVst2Wrapper : public FUnknown
  64. {
  65. public:
  66. //------------------------------------------------------------------------
  67. static const FUID iid;
  68. };
  69. DECLARE_CLASS_IID (IVst3ToVst2Wrapper, 0x29633AEC, 0x1D1C47E2, 0xBB85B97B, 0xD36EAC61)
  70. //------------------------------------------------------------------------
  71. /** VST 3 to AU Wrapper interface: Vst::IVst3ToAUWrapper
  72. \ingroup vstIHost vst310
  73. - [host imp]
  74. - [passed as 'context' to IPluginBase::initialize () ]
  75. - [released: 3.1.0]
  76. - [mandatory]
  77. Informs the plug-in that a VST 3 to AU wrapper is used between the plug-in and the real host.
  78. Implemented by the AU Wrapper.
  79. */
  80. class IVst3ToAUWrapper : public FUnknown
  81. {
  82. public:
  83. //------------------------------------------------------------------------
  84. static const FUID iid;
  85. };
  86. DECLARE_CLASS_IID (IVst3ToAUWrapper, 0xA3B8C6C5, 0xC0954688, 0xB0916F0B, 0xB697AA44)
  87. //------------------------------------------------------------------------
  88. /** VST 3 to AAX Wrapper interface: Vst::IVst3ToAAXWrapper
  89. \ingroup vstIHost vst368
  90. - [host imp]
  91. - [passed as 'context' to IPluginBase::initialize () ]
  92. - [released: 3.6.8]
  93. - [mandatory]
  94. Informs the plug-in that a VST 3 to AAX wrapper is used between the plug-in and the real host.
  95. Implemented by the AAX Wrapper.
  96. */
  97. class IVst3ToAAXWrapper : public FUnknown
  98. {
  99. public:
  100. //------------------------------------------------------------------------
  101. static const FUID iid;
  102. };
  103. DECLARE_CLASS_IID (IVst3ToAAXWrapper, 0x6D319DC6, 0x60C56242, 0xB32C951B, 0x93BEF4C6)
  104. //------------------------------------------------------------------------
  105. /** Wrapper MPE Support interface: Vst::IVst3WrapperMPESupport
  106. \ingroup vstIHost vst3612
  107. - [host imp]
  108. - [passed as 'context' to IPluginBase::initialize () ]
  109. - [released: 3.6.12]
  110. - [optional]
  111. Implemented on wrappers that support MPE to Note Expression translation.
  112. By default, MPE input processing is enabled, the masterChannel will be zero, the memberBeginChannel
  113. will be one and the memberEndChannel will be 14.
  114. As MPE is a subset of the VST3 Note Expression feature, mapping from the three MPE expressions is
  115. handled via the INoteExpressionPhysicalUIMapping interface.
  116. */
  117. class IVst3WrapperMPESupport : public FUnknown
  118. {
  119. public:
  120. //------------------------------------------------------------------------
  121. /** enable or disable MPE processing
  122. * @param state true to enable, false to disable MPE processing
  123. * @return kResultTrue on success */
  124. virtual tresult PLUGIN_API enableMPEInputProcessing (TBool state) = 0;
  125. /** setup the MPE processing
  126. * @param masterChannel MPE master channel (zero based)
  127. * @param memberBeginChannel MPE member begin channel (zero based)
  128. * @param memberEndChannel MPE member end channel (zero based)
  129. * @return kResultTrue on success */
  130. virtual tresult PLUGIN_API setMPEInputDeviceSettings (int32 masterChannel,
  131. int32 memberBeginChannel,
  132. int32 memberEndChannel) = 0;
  133. //------------------------------------------------------------------------
  134. static const FUID iid;
  135. };
  136. DECLARE_CLASS_IID (IVst3WrapperMPESupport, 0x44149067, 0x42CF4BF9, 0x8800B750, 0xF7359FE3)
  137. //------------------------------------------------------------------------
  138. } // namespace Vst
  139. } // namespace Steinberg