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.

89 lines
3.4KB

  1. //------------------------------------------------------------------------
  2. // Project : VST SDK
  3. // Version : 3.6.7
  4. //
  5. // Category : Interfaces
  6. // Filename : pluginterfaces/vst/ivstprefetchablesupport.h
  7. // Created by : Steinberg, 02/2015
  8. // Description : VST Prefetchable Support Interface
  9. //
  10. //-----------------------------------------------------------------------------
  11. // This file is part of a Steinberg SDK. It is subject to the license terms
  12. // in the LICENSE file found in the top-level directory of this distribution
  13. // and at www.steinberg.net/sdklicenses.
  14. // No part of the SDK, including this file, may be copied, modified, propagated,
  15. // or distributed except according to the terms contained in the LICENSE file.
  16. //-----------------------------------------------------------------------------
  17. #pragma once
  18. #include "pluginterfaces/vst/vsttypes.h"
  19. #include "pluginterfaces/vst/ivstattributes.h"
  20. //------------------------------------------------------------------------
  21. #include "pluginterfaces/base/falignpush.h"
  22. //------------------------------------------------------------------------
  23. //------------------------------------------------------------------------
  24. namespace Steinberg {
  25. namespace Vst {
  26. typedef uint32 PrefetchableSupport;
  27. enum ePrefetchableSupport
  28. {
  29. kIsNeverPrefetchable = 0, ///< every instance of the plug does not support prefetch processing
  30. kIsYetPrefetchable, ///< in the current state the plug support prefetch processing
  31. kIsNotYetPrefetchable, ///< in the current state the plug does not support prefetch processing
  32. kNumPrefetchableSupport
  33. };
  34. //------------------------------------------------------------------------
  35. // IPrefetchableSupport Interface
  36. //------------------------------------------------------------------------
  37. /** Indicates that the Plug-in could or not support Prefetch (dynamically).
  38. \ingroup vstIPlug vst365
  39. - [plug imp]
  40. - [extends IComponent]
  41. - [released: 3.6.5]
  42. - [optional]
  43. The Plug-in should implement this interface if it needs to dynamically change between Prefetchable or not.
  44. By default (without implementing this interface) the host will decide in which mode the Plug-in will be process.
  45. For more info about Prefetch processing mode check ProcessModes::kPrefetch documentation.
  46. \section IPrefetchableSupportExample Example
  47. \code
  48. tresult PLUGIN_API myPlug::getPrefetchableSupport (PrefetchableSupport& prefetchable)
  49. {
  50. prefetchable = kIsNeverPrefetchable;
  51. switch (myPrefetchableMode)
  52. {
  53. case 0: prefetchable = kIsNeverPrefetchable; break;
  54. case 1: prefetchable = kIsYetPrefetchable; break;
  55. case 2: prefetchable = kIsNotYetPrefetchable; break;
  56. }
  57. return kResultOk;
  58. }
  59. \endcode */
  60. class IPrefetchableSupport : public FUnknown
  61. {
  62. public:
  63. //------------------------------------------------------------------------
  64. /** retrieve the current prefetch support. Use IComponentHandler::restartComponent (kPrefetchableSupportChanged)
  65. to inform the host that this support has changed. */
  66. virtual tresult PLUGIN_API getPrefetchableSupport (PrefetchableSupport& prefetchable /*out*/) = 0;
  67. //------------------------------------------------------------------------
  68. static const FUID iid;
  69. };
  70. DECLARE_CLASS_IID (IPrefetchableSupport, 0x8AE54FDA, 0xE93046B9, 0xA28555BC, 0xDC98E21E)
  71. } // namespace Vst
  72. } // namespace Steinberg
  73. //------------------------------------------------------------------------
  74. #include "pluginterfaces/base/falignpop.h"
  75. //------------------------------------------------------------------------