|
|
@@ -117,232 +117,391 @@ var searchBox = new SearchBox("searchBox", "search",false,'Search'); |
|
|
|
<div class="line"><a name="l00028"></a><span class="lineno"> 28</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00029"></a><span class="lineno"> 29</span> <span class="comment"> DISTRHO %Plugin Framework (or @b DPF for short)</span></div> |
|
|
|
<div class="line"><a name="l00030"></a><span class="lineno"> 30</span> <span class="comment"> is a plugin framework designed to make development of new plugins an easy and enjoyable task.@n</span></div> |
|
|
|
<div class="line"><a name="l00031"></a><span class="lineno"> 31</span> <span class="comment"> It allows developers to create plugins with custom UIs using a simple C++ API.</span></div> |
|
|
|
<div class="line"><a name="l00032"></a><span class="lineno"> 32</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00033"></a><span class="lineno"> 33</span> <span class="comment"> @section Macros</span></div> |
|
|
|
<div class="line"><a name="l00034"></a><span class="lineno"> 34</span> <span class="comment"> You start by creating a "DistrhoPluginInfo.h" file describing the plugin via macros, see @ref PluginMacros.@n</span></div> |
|
|
|
<div class="line"><a name="l00035"></a><span class="lineno"> 35</span> <span class="comment"> This file is included in the main DPF code to figure out which features for each plugin format to export.</span></div> |
|
|
|
<div class="line"><a name="l00031"></a><span class="lineno"> 31</span> <span class="comment"> It allows developers to create plugins with custom UIs using a simple C++ API.@n</span></div> |
|
|
|
<div class="line"><a name="l00032"></a><span class="lineno"> 32</span> <span class="comment"> The framework facilitates exporting various different plugin formats from the same code-base.</span></div> |
|
|
|
<div class="line"><a name="l00033"></a><span class="lineno"> 33</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00034"></a><span class="lineno"> 34</span> <span class="comment"> DPF can build for LADSPA, DSSI, LV2 and VST2 formats.@n</span></div> |
|
|
|
<div class="line"><a name="l00035"></a><span class="lineno"> 35</span> <span class="comment"> A JACK/Standalone mode is also available, allowing you to quickly test plugins.</span></div> |
|
|
|
<div class="line"><a name="l00036"></a><span class="lineno"> 36</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00037"></a><span class="lineno"> 37</span> <span class="comment"> For example, a plugin (with %UI) that use states will require LV2 hosts to support Atom and Worker extensions for</span></div> |
|
|
|
<div class="line"><a name="l00038"></a><span class="lineno"> 38</span> <span class="comment"> message passing from the %UI to the plugin.@n</span></div> |
|
|
|
<div class="line"><a name="l00039"></a><span class="lineno"> 39</span> <span class="comment"> If your plugin does not make use of states, the Worker extension is not set as a required feature.</span></div> |
|
|
|
<div class="line"><a name="l00037"></a><span class="lineno"> 37</span> <span class="comment"> @section Macros</span></div> |
|
|
|
<div class="line"><a name="l00038"></a><span class="lineno"> 38</span> <span class="comment"> You start by creating a "DistrhoPluginInfo.h" file describing the plugin via macros, see @ref PluginMacros.@n</span></div> |
|
|
|
<div class="line"><a name="l00039"></a><span class="lineno"> 39</span> <span class="comment"> This file is included in the main DPF code to select which features to activate for each plugin format.</span></div> |
|
|
|
<div class="line"><a name="l00040"></a><span class="lineno"> 40</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00041"></a><span class="lineno"> 41</span> <span class="comment"> @section Plugin</span></div> |
|
|
|
<div class="line"><a name="l00042"></a><span class="lineno"> 42</span> <span class="comment"> The next step is to create your plugin code by subclassing DPF's Plugin class.@n</span></div> |
|
|
|
<div class="line"><a name="l00043"></a><span class="lineno"> 43</span> <span class="comment"> You need to pass the number of parameters in the constructor and also the number of programs and states, if any.</span></div> |
|
|
|
<div class="line"><a name="l00041"></a><span class="lineno"> 41</span> <span class="comment"> For example, a plugin (with %UI) that use states will require LV2 hosts to support Atom and Worker extensions for</span></div> |
|
|
|
<div class="line"><a name="l00042"></a><span class="lineno"> 42</span> <span class="comment"> message passing from the %UI to the plugin.@n</span></div> |
|
|
|
<div class="line"><a name="l00043"></a><span class="lineno"> 43</span> <span class="comment"> If your plugin does not make use of states, the Worker extension is not set as a required feature.</span></div> |
|
|
|
<div class="line"><a name="l00044"></a><span class="lineno"> 44</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00045"></a><span class="lineno"> 45</span> <span class="comment"> Here's an example of an audio plugin that simply mutes the host output:</span></div> |
|
|
|
<div class="line"><a name="l00046"></a><span class="lineno"> 46</span> <span class="comment"> @code</span></div> |
|
|
|
<div class="line"><a name="l00047"></a><span class="lineno"> 47</span> <span class="comment"> class MutePlugin : public Plugin</span></div> |
|
|
|
<div class="line"><a name="l00048"></a><span class="lineno"> 48</span> <span class="comment"> {</span></div> |
|
|
|
<div class="line"><a name="l00049"></a><span class="lineno"> 49</span> <span class="comment"> public:</span></div> |
|
|
|
<div class="line"><a name="l00050"></a><span class="lineno"> 50</span> <span class="comment"> MutePlugin()</span></div> |
|
|
|
<div class="line"><a name="l00051"></a><span class="lineno"> 51</span> <span class="comment"> : Plugin(0, 0, 0) // 0 parameters, 0 programs and 0 states</span></div> |
|
|
|
<div class="line"><a name="l00052"></a><span class="lineno"> 52</span> <span class="comment"> {</span></div> |
|
|
|
<div class="line"><a name="l00053"></a><span class="lineno"> 53</span> <span class="comment"> }</span></div> |
|
|
|
<div class="line"><a name="l00054"></a><span class="lineno"> 54</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00055"></a><span class="lineno"> 55</span> <span class="comment"> protected:</span></div> |
|
|
|
<div class="line"><a name="l00056"></a><span class="lineno"> 56</span> <span class="comment"> const char* getLabel() const override</span></div> |
|
|
|
<div class="line"><a name="l00057"></a><span class="lineno"> 57</span> <span class="comment"> {</span></div> |
|
|
|
<div class="line"><a name="l00058"></a><span class="lineno"> 58</span> <span class="comment"> return "Mute";</span></div> |
|
|
|
<div class="line"><a name="l00059"></a><span class="lineno"> 59</span> <span class="comment"> }</span></div> |
|
|
|
<div class="line"><a name="l00060"></a><span class="lineno"> 60</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00061"></a><span class="lineno"> 61</span> <span class="comment"> const char* getMaker() const override</span></div> |
|
|
|
<div class="line"><a name="l00062"></a><span class="lineno"> 62</span> <span class="comment"> {</span></div> |
|
|
|
<div class="line"><a name="l00063"></a><span class="lineno"> 63</span> <span class="comment"> return "DPF";</span></div> |
|
|
|
<div class="line"><a name="l00064"></a><span class="lineno"> 64</span> <span class="comment"> }</span></div> |
|
|
|
<div class="line"><a name="l00045"></a><span class="lineno"> 45</span> <span class="comment"> @section Plugin</span></div> |
|
|
|
<div class="line"><a name="l00046"></a><span class="lineno"> 46</span> <span class="comment"> The next step is to create your plugin code by subclassing DPF's Plugin class.@n</span></div> |
|
|
|
<div class="line"><a name="l00047"></a><span class="lineno"> 47</span> <span class="comment"> You need to pass the number of parameters in the constructor and also the number of programs and states, if any.</span></div> |
|
|
|
<div class="line"><a name="l00048"></a><span class="lineno"> 48</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00049"></a><span class="lineno"> 49</span> <span class="comment"> Here's an example of an audio plugin that simply mutes the host output:</span></div> |
|
|
|
<div class="line"><a name="l00050"></a><span class="lineno"> 50</span> <span class="comment"> @code</span></div> |
|
|
|
<div class="line"><a name="l00051"></a><span class="lineno"> 51</span> <span class="comment"> class MutePlugin : public Plugin</span></div> |
|
|
|
<div class="line"><a name="l00052"></a><span class="lineno"> 52</span> <span class="comment"> {</span></div> |
|
|
|
<div class="line"><a name="l00053"></a><span class="lineno"> 53</span> <span class="comment"> public:</span><span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00054"></a><span class="lineno"> 54</span> <span class="comment"> /**</span></div> |
|
|
|
<div class="line"><a name="l00055"></a><span class="lineno"> 55</span> <span class="comment"> Plugin class constructor.</span></div> |
|
|
|
<div class="line"><a name="l00056"></a><span class="lineno"> 56</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00057"></a><span class="lineno"> 57</span>  MutePlugin()</div> |
|
|
|
<div class="line"><a name="l00058"></a><span class="lineno"> 58</span>  : Plugin(0, 0, 0) // 0 parameters, 0 programs and 0 states</div> |
|
|
|
<div class="line"><a name="l00059"></a><span class="lineno"> 59</span>  {</div> |
|
|
|
<div class="line"><a name="l00060"></a><span class="lineno"> 60</span>  }</div> |
|
|
|
<div class="line"><a name="l00061"></a><span class="lineno"> 61</span> </div> |
|
|
|
<div class="line"><a name="l00062"></a><span class="lineno"> 62</span>  protected:</div> |
|
|
|
<div class="line"><a name="l00063"></a><span class="lineno"> 63</span>  /* ----------------------------------------------------------------------------------------</div> |
|
|
|
<div class="line"><a name="l00064"></a><span class="lineno"> 64</span>  * Information */</div> |
|
|
|
<div class="line"><a name="l00065"></a><span class="lineno"> 65</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00066"></a><span class="lineno"> 66</span> <span class="comment"> const char* getLicense() const override</span></div> |
|
|
|
<div class="line"><a name="l00067"></a><span class="lineno"> 67</span> <span class="comment"> {</span></div> |
|
|
|
<div class="line"><a name="l00068"></a><span class="lineno"> 68</span> <span class="comment"> return "MIT";</span></div> |
|
|
|
<div class="line"><a name="l00069"></a><span class="lineno"> 69</span> <span class="comment"> }</span></div> |
|
|
|
<div class="line"><a name="l00070"></a><span class="lineno"> 70</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00071"></a><span class="lineno"> 71</span> <span class="comment"> uint32_t getVersion() const override</span></div> |
|
|
|
<div class="line"><a name="l00072"></a><span class="lineno"> 72</span> <span class="comment"> {</span></div> |
|
|
|
<div class="line"><a name="l00073"></a><span class="lineno"> 73</span> <span class="comment"> return 0x1000;</span></div> |
|
|
|
<div class="line"><a name="l00074"></a><span class="lineno"> 74</span> <span class="comment"> }</span></div> |
|
|
|
<div class="line"><a name="l00075"></a><span class="lineno"> 75</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00076"></a><span class="lineno"> 76</span> <span class="comment"> int64_t getUniqueId() const override</span></div> |
|
|
|
<div class="line"><a name="l00077"></a><span class="lineno"> 77</span> <span class="comment"> {</span></div> |
|
|
|
<div class="line"><a name="l00078"></a><span class="lineno"> 78</span> <span class="comment"> return cconst('M', 'u', 't', 'e');</span></div> |
|
|
|
<div class="line"><a name="l00079"></a><span class="lineno"> 79</span> <span class="comment"> }</span></div> |
|
|
|
<div class="line"><a name="l00080"></a><span class="lineno"> 80</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00081"></a><span class="lineno"> 81</span> <span class="comment"> void run(const float**, float** outputs, uint32_t frames) override</span></div> |
|
|
|
<div class="line"><a name="l00082"></a><span class="lineno"> 82</span> <span class="comment"> {</span></div> |
|
|
|
<div class="line"><a name="l00083"></a><span class="lineno"> 83</span> <span class="comment"> // get the left and right audio outputs</span></div> |
|
|
|
<div class="line"><a name="l00084"></a><span class="lineno"> 84</span> <span class="comment"> float* const outL = outputs[0];</span></div> |
|
|
|
<div class="line"><a name="l00085"></a><span class="lineno"> 85</span> <span class="comment"> float* const outR = outputs[1];</span></div> |
|
|
|
<div class="line"><a name="l00086"></a><span class="lineno"> 86</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00087"></a><span class="lineno"> 87</span> <span class="comment"> // mute audio</span></div> |
|
|
|
<div class="line"><a name="l00088"></a><span class="lineno"> 88</span> <span class="comment"> std::memset(outL, 0, sizeof(float)*frames);</span></div> |
|
|
|
<div class="line"><a name="l00089"></a><span class="lineno"> 89</span> <span class="comment"> std::memset(outR, 0, sizeof(float)*frames);</span></div> |
|
|
|
<div class="line"><a name="l00090"></a><span class="lineno"> 90</span> <span class="comment"> }</span></div> |
|
|
|
<div class="line"><a name="l00091"></a><span class="lineno"> 91</span> <span class="comment"> };</span></div> |
|
|
|
<div class="line"><a name="l00092"></a><span class="lineno"> 92</span> <span class="comment"> @endcode</span></div> |
|
|
|
<div class="line"><a name="l00093"></a><span class="lineno"> 93</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00094"></a><span class="lineno"> 94</span> <span class="comment"> See the @ref Plugin class for more information and to understand what each function does.</span></div> |
|
|
|
<div class="line"><a name="l00095"></a><span class="lineno"> 95</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00096"></a><span class="lineno"> 96</span> <span class="comment"> @section Parameters</span></div> |
|
|
|
<div class="line"><a name="l00097"></a><span class="lineno"> 97</span> <span class="comment"> describe input and output, automable and rt safe, boolean etc, cv</span></div> |
|
|
|
<div class="line"><a name="l00098"></a><span class="lineno"> 98</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00099"></a><span class="lineno"> 99</span> <span class="comment"> @section Programs</span></div> |
|
|
|
<div class="line"><a name="l00100"></a><span class="lineno"> 100</span> <span class="comment"> describe them</span></div> |
|
|
|
<div class="line"><a name="l00101"></a><span class="lineno"> 101</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00102"></a><span class="lineno"> 102</span> <span class="comment"> @section States</span></div> |
|
|
|
<div class="line"><a name="l00103"></a><span class="lineno"> 103</span> <span class="comment"> describe them</span></div> |
|
|
|
<div class="line"><a name="l00104"></a><span class="lineno"> 104</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00105"></a><span class="lineno"> 105</span> <span class="comment"> @section MIDI</span></div> |
|
|
|
<div class="line"><a name="l00106"></a><span class="lineno"> 106</span> <span class="comment"> describe them</span></div> |
|
|
|
<div class="line"><a name="l00107"></a><span class="lineno"> 107</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00108"></a><span class="lineno"> 108</span> <span class="comment"> @section Latency</span></div> |
|
|
|
<div class="line"><a name="l00109"></a><span class="lineno"> 109</span> <span class="comment"> describe it</span></div> |
|
|
|
<div class="line"><a name="l00110"></a><span class="lineno"> 110</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00111"></a><span class="lineno"> 111</span> <span class="comment"> @section Time-Position</span></div> |
|
|
|
<div class="line"><a name="l00112"></a><span class="lineno"> 112</span> <span class="comment"> describe it</span></div> |
|
|
|
<div class="line"><a name="l00113"></a><span class="lineno"> 113</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00114"></a><span class="lineno"> 114</span> <span class="comment"> @section UI</span></div> |
|
|
|
<div class="line"><a name="l00115"></a><span class="lineno"> 115</span> <span class="comment"> describe them</span></div> |
|
|
|
<div class="line"><a name="l00116"></a><span class="lineno"> 116</span> <span class="comment">*/</span></div> |
|
|
|
<div class="line"><a name="l00117"></a><span class="lineno"> 117</span> </div> |
|
|
|
<div class="line"><a name="l00118"></a><span class="lineno"> 118</span> <span class="comment">/* ------------------------------------------------------------------------------------------------------------</span></div> |
|
|
|
<div class="line"><a name="l00119"></a><span class="lineno"> 119</span> <span class="comment"> * Plugin Macros */</span></div> |
|
|
|
<div class="line"><a name="l00120"></a><span class="lineno"> 120</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00121"></a><span class="lineno"> 121</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00122"></a><span class="lineno"> 122</span> <span class="comment"> @defgroup PluginMacros Plugin Macros</span></div> |
|
|
|
<div class="line"><a name="l00123"></a><span class="lineno"> 123</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00124"></a><span class="lineno"> 124</span> <span class="comment"> C Macros that describe your plugin. (defined in the "DistrhoPluginInfo.h" file)</span></div> |
|
|
|
<div class="line"><a name="l00125"></a><span class="lineno"> 125</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00126"></a><span class="lineno"> 126</span> <span class="comment"> With these macros you can tell the host what features your plugin requires.@n</span></div> |
|
|
|
<div class="line"><a name="l00127"></a><span class="lineno"> 127</span> <span class="comment"> Depending on which macros you enable, new functions will be available to call and/or override.</span></div> |
|
|
|
<div class="line"><a name="l00128"></a><span class="lineno"> 128</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00129"></a><span class="lineno"> 129</span> <span class="comment"> All values are either integer or strings.@n</span></div> |
|
|
|
<div class="line"><a name="l00130"></a><span class="lineno"> 130</span> <span class="comment"> For boolean-like values 1 means 'on' and 0 means 'off'.</span></div> |
|
|
|
<div class="line"><a name="l00131"></a><span class="lineno"> 131</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00132"></a><span class="lineno"> 132</span> <span class="comment"> The values defined in this group are for documentation purposes only.@n</span></div> |
|
|
|
<div class="line"><a name="l00133"></a><span class="lineno"> 133</span> <span class="comment"> All macros are disabled by default.</span></div> |
|
|
|
<div class="line"><a name="l00134"></a><span class="lineno"> 134</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00135"></a><span class="lineno"> 135</span> <span class="comment"> Only 4 macros are required, they are:</span></div> |
|
|
|
<div class="line"><a name="l00136"></a><span class="lineno"> 136</span> <span class="comment"> - @ref DISTRHO_PLUGIN_NAME</span></div> |
|
|
|
<div class="line"><a name="l00137"></a><span class="lineno"> 137</span> <span class="comment"> - @ref DISTRHO_PLUGIN_NUM_INPUTS</span></div> |
|
|
|
<div class="line"><a name="l00138"></a><span class="lineno"> 138</span> <span class="comment"> - @ref DISTRHO_PLUGIN_NUM_OUTPUTS</span></div> |
|
|
|
<div class="line"><a name="l00139"></a><span class="lineno"> 139</span> <span class="comment"> - @ref DISTRHO_PLUGIN_URI</span></div> |
|
|
|
<div class="line"><a name="l00140"></a><span class="lineno"> 140</span> <span class="comment"> @{</span></div> |
|
|
|
<div class="line"><a name="l00141"></a><span class="lineno"> 141</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00142"></a><span class="lineno"> 142</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00143"></a><span class="lineno"> 143</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00144"></a><span class="lineno"> 144</span> <span class="comment"> The plugin name.@n</span></div> |
|
|
|
<div class="line"><a name="l00145"></a><span class="lineno"> 145</span> <span class="comment"> This is used to identify your plugin before a Plugin instance can be created.</span></div> |
|
|
|
<div class="line"><a name="l00146"></a><span class="lineno"> 146</span> <span class="comment"> @note This macro is required.</span></div> |
|
|
|
<div class="line"><a name="l00147"></a><span class="lineno"> 147</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00148"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga888482a9f695c2ca2f433e5f3172dcc4"> 148</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_NAME "Plugin Name"</span></div> |
|
|
|
<div class="line"><a name="l00149"></a><span class="lineno"> 149</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00150"></a><span class="lineno"> 150</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00151"></a><span class="lineno"> 151</span> <span class="comment"> Number of audio inputs the plugin has.</span></div> |
|
|
|
<div class="line"><a name="l00152"></a><span class="lineno"> 152</span> <span class="comment"> @note This macro is required.</span></div> |
|
|
|
<div class="line"><a name="l00153"></a><span class="lineno"> 153</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00154"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga5f4f3d9a5dc3c23882d158e636319998"> 154</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_NUM_INPUTS 2</span></div> |
|
|
|
<div class="line"><a name="l00155"></a><span class="lineno"> 155</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00156"></a><span class="lineno"> 156</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00157"></a><span class="lineno"> 157</span> <span class="comment"> Number of audio outputs the plugin has.</span></div> |
|
|
|
<div class="line"><a name="l00158"></a><span class="lineno"> 158</span> <span class="comment"> @note This macro is required.</span></div> |
|
|
|
<div class="line"><a name="l00159"></a><span class="lineno"> 159</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00160"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga917195804ebcb2bb48c9fad52b20b3ca"> 160</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_NUM_OUTPUTS 2</span></div> |
|
|
|
<div class="line"><a name="l00161"></a><span class="lineno"> 161</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00162"></a><span class="lineno"> 162</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00163"></a><span class="lineno"> 163</span> <span class="comment"> The plugin URI when exporting in LV2 format.</span></div> |
|
|
|
<div class="line"><a name="l00164"></a><span class="lineno"> 164</span> <span class="comment"> @note This macro is required.</span></div> |
|
|
|
<div class="line"><a name="l00165"></a><span class="lineno"> 165</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00166"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga9cc186448134e6a1956474b3878c97a8"> 166</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_URI "urn:distrho:name"</span></div> |
|
|
|
<div class="line"><a name="l00167"></a><span class="lineno"> 167</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00168"></a><span class="lineno"> 168</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00169"></a><span class="lineno"> 169</span> <span class="comment"> Wherever the plugin has a custom %UI.</span></div> |
|
|
|
<div class="line"><a name="l00170"></a><span class="lineno"> 170</span> <span class="comment"> @see DISTRHO_UI_USE_NANOVG</span></div> |
|
|
|
<div class="line"><a name="l00171"></a><span class="lineno"> 171</span> <span class="comment"> @see UI</span></div> |
|
|
|
<div class="line"><a name="l00172"></a><span class="lineno"> 172</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00173"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#gacf8a1af679c09637ba0bdc5f4f8e37dd"> 173</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_HAS_UI 1</span></div> |
|
|
|
<div class="line"><a name="l00174"></a><span class="lineno"> 174</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00175"></a><span class="lineno"> 175</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00176"></a><span class="lineno"> 176</span> <span class="comment"> Wherever the plugin processing is realtime-safe.@n</span></div> |
|
|
|
<div class="line"><a name="l00177"></a><span class="lineno"> 177</span> <span class="comment"> TODO - list rtsafe requirements</span></div> |
|
|
|
<div class="line"><a name="l00178"></a><span class="lineno"> 178</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00179"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga82546dd199fcea338b113f2f6da84ced"> 179</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_IS_RT_SAFE 1</span></div> |
|
|
|
<div class="line"><a name="l00180"></a><span class="lineno"> 180</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00181"></a><span class="lineno"> 181</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00182"></a><span class="lineno"> 182</span> <span class="comment"> Wherever the plugin is a synth.@n</span></div> |
|
|
|
<div class="line"><a name="l00183"></a><span class="lineno"> 183</span> <span class="comment"> @ref DISTRHO_PLUGIN_WANT_MIDI_INPUT is automatically enabled when this is too.</span></div> |
|
|
|
<div class="line"><a name="l00184"></a><span class="lineno"> 184</span> <span class="comment"> @see DISTRHO_PLUGIN_WANT_MIDI_INPUT</span></div> |
|
|
|
<div class="line"><a name="l00185"></a><span class="lineno"> 185</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00186"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga854bde6b6fdb0d47182149dbab0fed72"> 186</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_IS_SYNTH 1</span></div> |
|
|
|
<div class="line"><a name="l00187"></a><span class="lineno"> 187</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00188"></a><span class="lineno"> 188</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00189"></a><span class="lineno"> 189</span> <span class="comment"> Enable direct access between the %UI and plugin code.</span></div> |
|
|
|
<div class="line"><a name="l00190"></a><span class="lineno"> 190</span> <span class="comment"> @see UI::getPluginInstancePointer()</span></div> |
|
|
|
<div class="line"><a name="l00191"></a><span class="lineno"> 191</span> <span class="comment"> @note DO NOT USE THIS UNLESS STRICTLY NECESSARY!!</span></div> |
|
|
|
<div class="line"><a name="l00192"></a><span class="lineno"> 192</span> <span class="comment"> Try to avoid it at all costs!</span></div> |
|
|
|
<div class="line"><a name="l00193"></a><span class="lineno"> 193</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00194"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#gac6873a3950f52f3fde8e386af63b69a1"> 194</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_WANT_DIRECT_ACCESS 0</span></div> |
|
|
|
<div class="line"><a name="l00195"></a><span class="lineno"> 195</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00196"></a><span class="lineno"> 196</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00197"></a><span class="lineno"> 197</span> <span class="comment"> Wherever the plugin introduces latency during audio or midi processing.</span></div> |
|
|
|
<div class="line"><a name="l00198"></a><span class="lineno"> 198</span> <span class="comment"> @see Plugin::setLatency(uint32_t)</span></div> |
|
|
|
<div class="line"><a name="l00199"></a><span class="lineno"> 199</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00200"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#gad6b0ebf10e048f4742f29735da4d4930"> 200</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_WANT_LATENCY 1</span></div> |
|
|
|
<div class="line"><a name="l00201"></a><span class="lineno"> 201</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00202"></a><span class="lineno"> 202</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00203"></a><span class="lineno"> 203</span> <span class="comment"> Wherever the plugin wants MIDI input.@n</span></div> |
|
|
|
<div class="line"><a name="l00204"></a><span class="lineno"> 204</span> <span class="comment"> This is automatically enabled if @ref DISTRHO_PLUGIN_IS_SYNTH is true.</span></div> |
|
|
|
<div class="line"><a name="l00205"></a><span class="lineno"> 205</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00206"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#gadf2e2eb7550e4116001c816adfb04a70"> 206</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_WANT_MIDI_INPUT 1</span></div> |
|
|
|
<div class="line"><a name="l00207"></a><span class="lineno"> 207</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00208"></a><span class="lineno"> 208</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00209"></a><span class="lineno"> 209</span> <span class="comment"> Wherever the plugin wants MIDI output.</span></div> |
|
|
|
<div class="line"><a name="l00210"></a><span class="lineno"> 210</span> <span class="comment"> @see Plugin::writeMidiEvent(const MidiEvent&)</span></div> |
|
|
|
<div class="line"><a name="l00211"></a><span class="lineno"> 211</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00212"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga548522eb91344a45841a5a95ff4f8073"> 212</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_WANT_MIDI_OUTPUT 1</span></div> |
|
|
|
<div class="line"><a name="l00213"></a><span class="lineno"> 213</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00214"></a><span class="lineno"> 214</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00215"></a><span class="lineno"> 215</span> <span class="comment"> Wherever the plugin provides its own internal programs.</span></div> |
|
|
|
<div class="line"><a name="l00216"></a><span class="lineno"> 216</span> <span class="comment"> @see Plugin::initProgramName(uint32_t, String&)</span></div> |
|
|
|
<div class="line"><a name="l00217"></a><span class="lineno"> 217</span> <span class="comment"> @see Plugin::setProgram(uint32_t)</span></div> |
|
|
|
<div class="line"><a name="l00218"></a><span class="lineno"> 218</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00219"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#gad95e24b17f196260cee15255fdb5b677"> 219</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_WANT_PROGRAMS 1</span></div> |
|
|
|
<div class="line"><a name="l00220"></a><span class="lineno"> 220</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00221"></a><span class="lineno"> 221</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00222"></a><span class="lineno"> 222</span> <span class="comment"> Wherever the plugin uses internal non-parameter data.</span></div> |
|
|
|
<div class="line"><a name="l00223"></a><span class="lineno"> 223</span> <span class="comment"> @see Plugin::initState(uint32_t, String&, String&)</span></div> |
|
|
|
<div class="line"><a name="l00224"></a><span class="lineno"> 224</span> <span class="comment"> @see Plugin::setState(const char*, const char*)</span></div> |
|
|
|
<div class="line"><a name="l00225"></a><span class="lineno"> 225</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00226"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga255f43cc0997af8b56abcca260c875e0"> 226</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_WANT_STATE 1</span></div> |
|
|
|
<div class="line"><a name="l00227"></a><span class="lineno"> 227</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00228"></a><span class="lineno"> 228</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00229"></a><span class="lineno"> 229</span> <span class="comment"> Wherever the plugin wants time position information from the host.</span></div> |
|
|
|
<div class="line"><a name="l00230"></a><span class="lineno"> 230</span> <span class="comment"> @see Plugin::getTimePosition()</span></div> |
|
|
|
<div class="line"><a name="l00231"></a><span class="lineno"> 231</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00232"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga496610b956d931b1940d07da48d123f2"> 232</a></span> <span class="preprocessor">#define DISTRHO_PLUGIN_WANT_TIMEPOS 1</span></div> |
|
|
|
<div class="line"><a name="l00233"></a><span class="lineno"> 233</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00234"></a><span class="lineno"> 234</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00235"></a><span class="lineno"> 235</span> <span class="comment"> Wherever the %UI uses NanoVG for drawing instead of the default raw OpenGL calls.@n</span></div> |
|
|
|
<div class="line"><a name="l00236"></a><span class="lineno"> 236</span> <span class="comment"> When enabled your %UI instance will subclass @ref NanoWidget instead of @ref Widget.</span></div> |
|
|
|
<div class="line"><a name="l00237"></a><span class="lineno"> 237</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00238"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#gad49e79936a2aa5afa089cbc051426ccd"> 238</a></span> <span class="preprocessor">#define DISTRHO_UI_USE_NANOVG 1</span></div> |
|
|
|
<div class="line"><a name="l00239"></a><span class="lineno"> 239</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00240"></a><span class="lineno"> 240</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00241"></a><span class="lineno"> 241</span> <span class="comment"> The %UI URI when exporting in LV2 format.@n</span></div> |
|
|
|
<div class="line"><a name="l00242"></a><span class="lineno"> 242</span> <span class="comment"> By default this is set to @ref DISTRHO_PLUGIN_URI with "#UI" as suffix.</span></div> |
|
|
|
<div class="line"><a name="l00243"></a><span class="lineno"> 243</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00244"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga420a88022da249b9f38a6046998dbd7c"> 244</a></span> <span class="preprocessor">#define DISTRHO_UI_URI DISTRHO_PLUGIN_URI "#UI"</span></div> |
|
|
|
<div class="line"><a name="l00245"></a><span class="lineno"> 245</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00246"></a><span class="lineno"> 246</span> <span class="comment">/** @} */</span></div> |
|
|
|
<div class="line"><a name="l00247"></a><span class="lineno"> 247</span> </div> |
|
|
|
<div class="line"><a name="l00248"></a><span class="lineno"> 248</span> <span class="comment">// -----------------------------------------------------------------------------------------------------------</span></div> |
|
|
|
<div class="line"><a name="l00249"></a><span class="lineno"> 249</span> </div> |
|
|
|
<div class="line"><a name="l00250"></a><span class="lineno"> 250</span> END_NAMESPACE_DISTRHO</div> |
|
|
|
<div class="line"><a name="l00251"></a><span class="lineno"> 251</span> </div> |
|
|
|
<div class="line"><a name="l00252"></a><span class="lineno"> 252</span> <span class="preprocessor">#endif // DOXYGEN</span></div> |
|
|
|
<div class="line"><a name="l00066"></a><span class="lineno"> 66</span> <span class="comment"> /**</span></div> |
|
|
|
<div class="line"><a name="l00067"></a><span class="lineno"> 67</span> <span class="comment"> Get the plugin label.</span></div> |
|
|
|
<div class="line"><a name="l00068"></a><span class="lineno"> 68</span> <span class="comment"> This label is a short restricted name consisting of only _, a-z, A-Z and 0-9 characters.</span></div> |
|
|
|
<div class="line"><a name="l00069"></a><span class="lineno"> 69</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00070"></a><span class="lineno"> 70</span>  const char* getLabel() const override</div> |
|
|
|
<div class="line"><a name="l00071"></a><span class="lineno"> 71</span>  {</div> |
|
|
|
<div class="line"><a name="l00072"></a><span class="lineno"> 72</span>  return "Mute";</div> |
|
|
|
<div class="line"><a name="l00073"></a><span class="lineno"> 73</span>  }</div> |
|
|
|
<div class="line"><a name="l00074"></a><span class="lineno"> 74</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00075"></a><span class="lineno"> 75</span> <span class="comment"> /**</span></div> |
|
|
|
<div class="line"><a name="l00076"></a><span class="lineno"> 76</span> <span class="comment"> Get the plugin author/maker.</span></div> |
|
|
|
<div class="line"><a name="l00077"></a><span class="lineno"> 77</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00078"></a><span class="lineno"> 78</span>  const char* getMaker() const override</div> |
|
|
|
<div class="line"><a name="l00079"></a><span class="lineno"> 79</span>  {</div> |
|
|
|
<div class="line"><a name="l00080"></a><span class="lineno"> 80</span>  return "DPF";</div> |
|
|
|
<div class="line"><a name="l00081"></a><span class="lineno"> 81</span>  }</div> |
|
|
|
<div class="line"><a name="l00082"></a><span class="lineno"> 82</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00083"></a><span class="lineno"> 83</span> <span class="comment"> /**</span></div> |
|
|
|
<div class="line"><a name="l00084"></a><span class="lineno"> 84</span> <span class="comment"> Get the plugin license name (a single line of text).</span></div> |
|
|
|
<div class="line"><a name="l00085"></a><span class="lineno"> 85</span> <span class="comment"> For commercial plugins this should return some short copyright information.</span></div> |
|
|
|
<div class="line"><a name="l00086"></a><span class="lineno"> 86</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00087"></a><span class="lineno"> 87</span>  const char* getLicense() const override</div> |
|
|
|
<div class="line"><a name="l00088"></a><span class="lineno"> 88</span>  {</div> |
|
|
|
<div class="line"><a name="l00089"></a><span class="lineno"> 89</span>  return "MIT";</div> |
|
|
|
<div class="line"><a name="l00090"></a><span class="lineno"> 90</span>  }</div> |
|
|
|
<div class="line"><a name="l00091"></a><span class="lineno"> 91</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00092"></a><span class="lineno"> 92</span> <span class="comment"> /**</span></div> |
|
|
|
<div class="line"><a name="l00093"></a><span class="lineno"> 93</span> <span class="comment"> Get the plugin version, in hexadecimal.</span></div> |
|
|
|
<div class="line"><a name="l00094"></a><span class="lineno"> 94</span> <span class="comment"> TODO format to be defined</span></div> |
|
|
|
<div class="line"><a name="l00095"></a><span class="lineno"> 95</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00096"></a><span class="lineno"> 96</span>  uint32_t getVersion() const override</div> |
|
|
|
<div class="line"><a name="l00097"></a><span class="lineno"> 97</span>  {</div> |
|
|
|
<div class="line"><a name="l00098"></a><span class="lineno"> 98</span>  return 0x1000;</div> |
|
|
|
<div class="line"><a name="l00099"></a><span class="lineno"> 99</span>  }</div> |
|
|
|
<div class="line"><a name="l00100"></a><span class="lineno"> 100</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00101"></a><span class="lineno"> 101</span> <span class="comment"> /**</span></div> |
|
|
|
<div class="line"><a name="l00102"></a><span class="lineno"> 102</span> <span class="comment"> Get the plugin unique Id.</span></div> |
|
|
|
<div class="line"><a name="l00103"></a><span class="lineno"> 103</span> <span class="comment"> This value is used by LADSPA, DSSI and VST plugin formats.</span></div> |
|
|
|
<div class="line"><a name="l00104"></a><span class="lineno"> 104</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00105"></a><span class="lineno"> 105</span>  int64_t getUniqueId() const override</div> |
|
|
|
<div class="line"><a name="l00106"></a><span class="lineno"> 106</span>  {</div> |
|
|
|
<div class="line"><a name="l00107"></a><span class="lineno"> 107</span>  return cconst('M', 'u', 't', 'e');</div> |
|
|
|
<div class="line"><a name="l00108"></a><span class="lineno"> 108</span>  }</div> |
|
|
|
<div class="line"><a name="l00109"></a><span class="lineno"> 109</span> </div> |
|
|
|
<div class="line"><a name="l00110"></a><span class="lineno"> 110</span>  /* ----------------------------------------------------------------------------------------</div> |
|
|
|
<div class="line"><a name="l00111"></a><span class="lineno"> 111</span>  * This example has no parameters, so skip parameter stuff */</div> |
|
|
|
<div class="line"><a name="l00112"></a><span class="lineno"> 112</span> </div> |
|
|
|
<div class="line"><a name="l00113"></a><span class="lineno"> 113</span>  void initParameter(uint32_t, Parameter&) override {}</div> |
|
|
|
<div class="line"><a name="l00114"></a><span class="lineno"> 114</span>  float getParameterValue(uint32_t) const override { return 0.0f; }</div> |
|
|
|
<div class="line"><a name="l00115"></a><span class="lineno"> 115</span>  void setParameterValue(uint32_t, float) override {}</div> |
|
|
|
<div class="line"><a name="l00116"></a><span class="lineno"> 116</span> </div> |
|
|
|
<div class="line"><a name="l00117"></a><span class="lineno"> 117</span>  /* ----------------------------------------------------------------------------------------</div> |
|
|
|
<div class="line"><a name="l00118"></a><span class="lineno"> 118</span>  * Audio/MIDI Processing */</div> |
|
|
|
<div class="line"><a name="l00119"></a><span class="lineno"> 119</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00120"></a><span class="lineno"> 120</span> <span class="comment"> /**</span></div> |
|
|
|
<div class="line"><a name="l00121"></a><span class="lineno"> 121</span> <span class="comment"> Run/process function for plugins without MIDI input.</span></div> |
|
|
|
<div class="line"><a name="l00122"></a><span class="lineno"> 122</span> <span class="comment"> NOTE: Some parameters might be null if there are no audio inputs or outputs.</span></div> |
|
|
|
<div class="line"><a name="l00123"></a><span class="lineno"> 123</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00124"></a><span class="lineno"> 124</span>  void run(const float**, float** outputs, uint32_t frames) override</div> |
|
|
|
<div class="line"><a name="l00125"></a><span class="lineno"> 125</span>  {</div> |
|
|
|
<div class="line"><a name="l00126"></a><span class="lineno"> 126</span>  // get the left and right audio outputs</div> |
|
|
|
<div class="line"><a name="l00127"></a><span class="lineno"> 127</span>  float* const outL = outputs[0];</div> |
|
|
|
<div class="line"><a name="l00128"></a><span class="lineno"> 128</span>  float* const outR = outputs[1];</div> |
|
|
|
<div class="line"><a name="l00129"></a><span class="lineno"> 129</span> </div> |
|
|
|
<div class="line"><a name="l00130"></a><span class="lineno"> 130</span>  // mute audio</div> |
|
|
|
<div class="line"><a name="l00131"></a><span class="lineno"> 131</span>  std::memset(outL, 0, sizeof(float)*frames);</div> |
|
|
|
<div class="line"><a name="l00132"></a><span class="lineno"> 132</span>  std::memset(outR, 0, sizeof(float)*frames);</div> |
|
|
|
<div class="line"><a name="l00133"></a><span class="lineno"> 133</span>  }</div> |
|
|
|
<div class="line"><a name="l00134"></a><span class="lineno"> 134</span> </div> |
|
|
|
<div class="line"><a name="l00135"></a><span class="lineno"> 135</span>  };</div> |
|
|
|
<div class="line"><a name="l00136"></a><span class="lineno"> 136</span>  @endcode</div> |
|
|
|
<div class="line"><a name="l00137"></a><span class="lineno"> 137</span> </div> |
|
|
|
<div class="line"><a name="l00138"></a><span class="lineno"> 138</span>  See the Plugin class for more information and to understand what each function does.</div> |
|
|
|
<div class="line"><a name="l00139"></a><span class="lineno"> 139</span> </div> |
|
|
|
<div class="line"><a name="l00140"></a><span class="lineno"> 140</span>  @section Parameters</div> |
|
|
|
<div class="line"><a name="l00141"></a><span class="lineno"> 141</span>  A plugin is nothing without parameters.@n</div> |
|
|
|
<div class="line"><a name="l00142"></a><span class="lineno"> 142</span>  In DPF parameters can be inputs or outputs.@n</div> |
|
|
|
<div class="line"><a name="l00143"></a><span class="lineno"> 143</span>  They have hints to describe how they behave plus a name and a symbol identifying them.@n</div> |
|
|
|
<div class="line"><a name="l00144"></a><span class="lineno"> 144</span>  Parameters also have 'ranges' โ a minimum, maximum and default value.</div> |
|
|
|
<div class="line"><a name="l00145"></a><span class="lineno"> 145</span> </div> |
|
|
|
<div class="line"><a name="l00146"></a><span class="lineno"> 146</span>  Input parameters are "read-only": the plugin can read them but not change them.</div> |
|
|
|
<div class="line"><a name="l00147"></a><span class="lineno"> 147</span>  (the exception being when changing programs, more on that below)@n</div> |
|
|
|
<div class="line"><a name="l00148"></a><span class="lineno"> 148</span>  It's the host responsibility to save, restore and set input parameters.</div> |
|
|
|
<div class="line"><a name="l00149"></a><span class="lineno"> 149</span> </div> |
|
|
|
<div class="line"><a name="l00150"></a><span class="lineno"> 150</span>  Output parameters can be changed at anytime by the plugin.@n</div> |
|
|
|
<div class="line"><a name="l00151"></a><span class="lineno"> 151</span>  The host will simply read their values and not change them.</div> |
|
|
|
<div class="line"><a name="l00152"></a><span class="lineno"> 152</span> </div> |
|
|
|
<div class="line"><a name="l00153"></a><span class="lineno"> 153</span>  Here's an example of an audio plugin that has 1 input parameter:</div> |
|
|
|
<div class="line"><a name="l00154"></a><span class="lineno"> 154</span>  @code</div> |
|
|
|
<div class="line"><a name="l00155"></a><span class="lineno"> 155</span>  class GainPlugin : public Plugin</div> |
|
|
|
<div class="line"><a name="l00156"></a><span class="lineno"> 156</span>  {</div> |
|
|
|
<div class="line"><a name="l00157"></a><span class="lineno"> 157</span>  public:<span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00158"></a><span class="lineno"> 158</span> <span class="comment"> /**</span></div> |
|
|
|
<div class="line"><a name="l00159"></a><span class="lineno"> 159</span> <span class="comment"> Plugin class constructor.</span></div> |
|
|
|
<div class="line"><a name="l00160"></a><span class="lineno"> 160</span> <span class="comment"> You must set all parameter values to their defaults, matching ParameterRanges::def.</span></div> |
|
|
|
<div class="line"><a name="l00161"></a><span class="lineno"> 161</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00162"></a><span class="lineno"> 162</span>  GainPlugin()</div> |
|
|
|
<div class="line"><a name="l00163"></a><span class="lineno"> 163</span>  : Plugin(1, 0, 0), // 1 parameter, 0 programs and 0 states</div> |
|
|
|
<div class="line"><a name="l00164"></a><span class="lineno"> 164</span>  fGain(1.0f)</div> |
|
|
|
<div class="line"><a name="l00165"></a><span class="lineno"> 165</span>  {</div> |
|
|
|
<div class="line"><a name="l00166"></a><span class="lineno"> 166</span>  }</div> |
|
|
|
<div class="line"><a name="l00167"></a><span class="lineno"> 167</span> </div> |
|
|
|
<div class="line"><a name="l00168"></a><span class="lineno"> 168</span>  protected:</div> |
|
|
|
<div class="line"><a name="l00169"></a><span class="lineno"> 169</span>  /* ----------------------------------------------------------------------------------------</div> |
|
|
|
<div class="line"><a name="l00170"></a><span class="lineno"> 170</span>  * Information */</div> |
|
|
|
<div class="line"><a name="l00171"></a><span class="lineno"> 171</span> </div> |
|
|
|
<div class="line"><a name="l00172"></a><span class="lineno"> 172</span>  const char* getLabel() const override</div> |
|
|
|
<div class="line"><a name="l00173"></a><span class="lineno"> 173</span>  {</div> |
|
|
|
<div class="line"><a name="l00174"></a><span class="lineno"> 174</span>  return "Mute";</div> |
|
|
|
<div class="line"><a name="l00175"></a><span class="lineno"> 175</span>  }</div> |
|
|
|
<div class="line"><a name="l00176"></a><span class="lineno"> 176</span> </div> |
|
|
|
<div class="line"><a name="l00177"></a><span class="lineno"> 177</span>  const char* getMaker() const override</div> |
|
|
|
<div class="line"><a name="l00178"></a><span class="lineno"> 178</span>  {</div> |
|
|
|
<div class="line"><a name="l00179"></a><span class="lineno"> 179</span>  return "DPF";</div> |
|
|
|
<div class="line"><a name="l00180"></a><span class="lineno"> 180</span>  }</div> |
|
|
|
<div class="line"><a name="l00181"></a><span class="lineno"> 181</span> </div> |
|
|
|
<div class="line"><a name="l00182"></a><span class="lineno"> 182</span>  const char* getLicense() const override</div> |
|
|
|
<div class="line"><a name="l00183"></a><span class="lineno"> 183</span>  {</div> |
|
|
|
<div class="line"><a name="l00184"></a><span class="lineno"> 184</span>  return "MIT";</div> |
|
|
|
<div class="line"><a name="l00185"></a><span class="lineno"> 185</span>  }</div> |
|
|
|
<div class="line"><a name="l00186"></a><span class="lineno"> 186</span> </div> |
|
|
|
<div class="line"><a name="l00187"></a><span class="lineno"> 187</span>  uint32_t getVersion() const override</div> |
|
|
|
<div class="line"><a name="l00188"></a><span class="lineno"> 188</span>  {</div> |
|
|
|
<div class="line"><a name="l00189"></a><span class="lineno"> 189</span>  return 0x1000;</div> |
|
|
|
<div class="line"><a name="l00190"></a><span class="lineno"> 190</span>  }</div> |
|
|
|
<div class="line"><a name="l00191"></a><span class="lineno"> 191</span> </div> |
|
|
|
<div class="line"><a name="l00192"></a><span class="lineno"> 192</span>  int64_t getUniqueId() const override</div> |
|
|
|
<div class="line"><a name="l00193"></a><span class="lineno"> 193</span>  {</div> |
|
|
|
<div class="line"><a name="l00194"></a><span class="lineno"> 194</span>  return cconst('M', 'u', 't', 'e');</div> |
|
|
|
<div class="line"><a name="l00195"></a><span class="lineno"> 195</span>  }</div> |
|
|
|
<div class="line"><a name="l00196"></a><span class="lineno"> 196</span> </div> |
|
|
|
<div class="line"><a name="l00197"></a><span class="lineno"> 197</span>  /* ----------------------------------------------------------------------------------------</div> |
|
|
|
<div class="line"><a name="l00198"></a><span class="lineno"> 198</span>  * Init */</div> |
|
|
|
<div class="line"><a name="l00199"></a><span class="lineno"> 199</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00200"></a><span class="lineno"> 200</span> <span class="comment"> /**</span></div> |
|
|
|
<div class="line"><a name="l00201"></a><span class="lineno"> 201</span> <span class="comment"> Initialize a parameter.</span></div> |
|
|
|
<div class="line"><a name="l00202"></a><span class="lineno"> 202</span> <span class="comment"> This function will be called once, shortly after the plugin is created.</span></div> |
|
|
|
<div class="line"><a name="l00203"></a><span class="lineno"> 203</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00204"></a><span class="lineno"> 204</span>  void initParameter(uint32_t index, Parameter& parameter) override</div> |
|
|
|
<div class="line"><a name="l00205"></a><span class="lineno"> 205</span>  {</div> |
|
|
|
<div class="line"><a name="l00206"></a><span class="lineno"> 206</span>  // we only have one parameter so we can skip checking the index</div> |
|
|
|
<div class="line"><a name="l00207"></a><span class="lineno"> 207</span> </div> |
|
|
|
<div class="line"><a name="l00208"></a><span class="lineno"> 208</span>  parameter.hints = kParameterIsAutomable;</div> |
|
|
|
<div class="line"><a name="l00209"></a><span class="lineno"> 209</span>  parameter.name = "Gain";</div> |
|
|
|
<div class="line"><a name="l00210"></a><span class="lineno"> 210</span>  parameter.symbol = "gain";</div> |
|
|
|
<div class="line"><a name="l00211"></a><span class="lineno"> 211</span>  }</div> |
|
|
|
<div class="line"><a name="l00212"></a><span class="lineno"> 212</span> </div> |
|
|
|
<div class="line"><a name="l00213"></a><span class="lineno"> 213</span>  /* ----------------------------------------------------------------------------------------</div> |
|
|
|
<div class="line"><a name="l00214"></a><span class="lineno"> 214</span>  * Internal data */</div> |
|
|
|
<div class="line"><a name="l00215"></a><span class="lineno"> 215</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00216"></a><span class="lineno"> 216</span> <span class="comment"> /**</span></div> |
|
|
|
<div class="line"><a name="l00217"></a><span class="lineno"> 217</span> <span class="comment"> Get the current value of a parameter.</span></div> |
|
|
|
<div class="line"><a name="l00218"></a><span class="lineno"> 218</span> <span class="comment"> The host may call this function from any context, including realtime processing.</span></div> |
|
|
|
<div class="line"><a name="l00219"></a><span class="lineno"> 219</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00220"></a><span class="lineno"> 220</span>  float getParameterValue(uint32_t index) const override</div> |
|
|
|
<div class="line"><a name="l00221"></a><span class="lineno"> 221</span>  {</div> |
|
|
|
<div class="line"><a name="l00222"></a><span class="lineno"> 222</span>  // same as before, ignore index check</div> |
|
|
|
<div class="line"><a name="l00223"></a><span class="lineno"> 223</span> </div> |
|
|
|
<div class="line"><a name="l00224"></a><span class="lineno"> 224</span>  return fGain;</div> |
|
|
|
<div class="line"><a name="l00225"></a><span class="lineno"> 225</span>  }</div> |
|
|
|
<div class="line"><a name="l00226"></a><span class="lineno"> 226</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00227"></a><span class="lineno"> 227</span> <span class="comment"> /**</span></div> |
|
|
|
<div class="line"><a name="l00228"></a><span class="lineno"> 228</span> <span class="comment"> Change a parameter value.</span></div> |
|
|
|
<div class="line"><a name="l00229"></a><span class="lineno"> 229</span> <span class="comment"> The host may call this function from any context, including realtime processing.</span></div> |
|
|
|
<div class="line"><a name="l00230"></a><span class="lineno"> 230</span> <span class="comment"> When a parameter is marked as automable, you must ensure no non-realtime operations are performed.</span></div> |
|
|
|
<div class="line"><a name="l00231"></a><span class="lineno"> 231</span> <span class="comment"> NOTE: This function will only be called for parameter inputs.</span></div> |
|
|
|
<div class="line"><a name="l00232"></a><span class="lineno"> 232</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00233"></a><span class="lineno"> 233</span>  void setParameterValue(uint32_t index, float value) override</div> |
|
|
|
<div class="line"><a name="l00234"></a><span class="lineno"> 234</span>  {</div> |
|
|
|
<div class="line"><a name="l00235"></a><span class="lineno"> 235</span>  // same as before, ignore index check</div> |
|
|
|
<div class="line"><a name="l00236"></a><span class="lineno"> 236</span> </div> |
|
|
|
<div class="line"><a name="l00237"></a><span class="lineno"> 237</span>  fGain = value;</div> |
|
|
|
<div class="line"><a name="l00238"></a><span class="lineno"> 238</span>  }</div> |
|
|
|
<div class="line"><a name="l00239"></a><span class="lineno"> 239</span> </div> |
|
|
|
<div class="line"><a name="l00240"></a><span class="lineno"> 240</span>  /* ----------------------------------------------------------------------------------------</div> |
|
|
|
<div class="line"><a name="l00241"></a><span class="lineno"> 241</span>  * Audio/MIDI Processing */</div> |
|
|
|
<div class="line"><a name="l00242"></a><span class="lineno"> 242</span> </div> |
|
|
|
<div class="line"><a name="l00243"></a><span class="lineno"> 243</span>  void run(const float**, float** outputs, uint32_t frames) override</div> |
|
|
|
<div class="line"><a name="l00244"></a><span class="lineno"> 244</span>  {</div> |
|
|
|
<div class="line"><a name="l00245"></a><span class="lineno"> 245</span>  // get the mono input and output</div> |
|
|
|
<div class="line"><a name="l00246"></a><span class="lineno"> 246</span>  const float* const in = inputs[0];</div> |
|
|
|
<div class="line"><a name="l00247"></a><span class="lineno"> 247</span>  /* */ float* const out = outputs[0];</div> |
|
|
|
<div class="line"><a name="l00248"></a><span class="lineno"> 248</span> </div> |
|
|
|
<div class="line"><a name="l00249"></a><span class="lineno"> 249</span>  // apply gain against all samples</div> |
|
|
|
<div class="line"><a name="l00250"></a><span class="lineno"> 250</span>  for (uint32_t i=0; i < frames; ++i)</div> |
|
|
|
<div class="line"><a name="l00251"></a><span class="lineno"> 251</span>  out[i] = in[i] * fGain;</div> |
|
|
|
<div class="line"><a name="l00252"></a><span class="lineno"> 252</span>  }</div> |
|
|
|
<div class="line"><a name="l00253"></a><span class="lineno"> 253</span>  };</div> |
|
|
|
<div class="line"><a name="l00254"></a><span class="lineno"> 254</span>  @endcode</div> |
|
|
|
<div class="line"><a name="l00255"></a><span class="lineno"> 255</span> </div> |
|
|
|
<div class="line"><a name="l00256"></a><span class="lineno"> 256</span>  See the Parameter struct for more information about parameters.</div> |
|
|
|
<div class="line"><a name="l00257"></a><span class="lineno"> 257</span> </div> |
|
|
|
<div class="line"><a name="l00258"></a><span class="lineno"> 258</span>  @section Programs</div> |
|
|
|
<div class="line"><a name="l00259"></a><span class="lineno"> 259</span>  describe them</div> |
|
|
|
<div class="line"><a name="l00260"></a><span class="lineno"> 260</span> </div> |
|
|
|
<div class="line"><a name="l00261"></a><span class="lineno"> 261</span>  @section States</div> |
|
|
|
<div class="line"><a name="l00262"></a><span class="lineno"> 262</span>  describe them</div> |
|
|
|
<div class="line"><a name="l00263"></a><span class="lineno"> 263</span> </div> |
|
|
|
<div class="line"><a name="l00264"></a><span class="lineno"> 264</span>  @section MIDI</div> |
|
|
|
<div class="line"><a name="l00265"></a><span class="lineno"> 265</span>  describe them</div> |
|
|
|
<div class="line"><a name="l00266"></a><span class="lineno"> 266</span> </div> |
|
|
|
<div class="line"><a name="l00267"></a><span class="lineno"> 267</span>  @section Latency</div> |
|
|
|
<div class="line"><a name="l00268"></a><span class="lineno"> 268</span>  describe it</div> |
|
|
|
<div class="line"><a name="l00269"></a><span class="lineno"> 269</span> </div> |
|
|
|
<div class="line"><a name="l00270"></a><span class="lineno"> 270</span>  @section Time-Position</div> |
|
|
|
<div class="line"><a name="l00271"></a><span class="lineno"> 271</span>  describe it</div> |
|
|
|
<div class="line"><a name="l00272"></a><span class="lineno"> 272</span> </div> |
|
|
|
<div class="line"><a name="l00273"></a><span class="lineno"> 273</span>  @section UI</div> |
|
|
|
<div class="line"><a name="l00274"></a><span class="lineno"> 274</span>  describe them</div> |
|
|
|
<div class="line"><a name="l00275"></a><span class="lineno"> 275</span> */</div> |
|
|
|
<div class="line"><a name="l00276"></a><span class="lineno"> 276</span> </div> |
|
|
|
<div class="line"><a name="l00277"></a><span class="lineno"> 277</span> /* ------------------------------------------------------------------------------------------------------------</div> |
|
|
|
<div class="line"><a name="l00278"></a><span class="lineno"> 278</span>  * Plugin Macros */</div> |
|
|
|
<div class="line"><a name="l00279"></a><span class="lineno"> 279</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00280"></a><span class="lineno"> 280</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00281"></a><span class="lineno"> 281</span> <span class="comment"> @defgroup PluginMacros Plugin Macros</span></div> |
|
|
|
<div class="line"><a name="l00282"></a><span class="lineno"> 282</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00283"></a><span class="lineno"> 283</span> <span class="comment"> C Macros that describe your plugin. (defined in the "DistrhoPluginInfo.h" file)</span></div> |
|
|
|
<div class="line"><a name="l00284"></a><span class="lineno"> 284</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00285"></a><span class="lineno"> 285</span> <span class="comment"> With these macros you can tell the host what features your plugin requires.@n</span></div> |
|
|
|
<div class="line"><a name="l00286"></a><span class="lineno"> 286</span> <span class="comment"> Depending on which macros you enable, new functions will be available to call and/or override.</span></div> |
|
|
|
<div class="line"><a name="l00287"></a><span class="lineno"> 287</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00288"></a><span class="lineno"> 288</span> <span class="comment"> All values are either integer or strings.@n</span></div> |
|
|
|
<div class="line"><a name="l00289"></a><span class="lineno"> 289</span> <span class="comment"> For boolean-like values 1 means 'on' and 0 means 'off'.</span></div> |
|
|
|
<div class="line"><a name="l00290"></a><span class="lineno"> 290</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00291"></a><span class="lineno"> 291</span> <span class="comment"> The values defined in this group are for documentation purposes only.@n</span></div> |
|
|
|
<div class="line"><a name="l00292"></a><span class="lineno"> 292</span> <span class="comment"> All macros are disabled by default.</span></div> |
|
|
|
<div class="line"><a name="l00293"></a><span class="lineno"> 293</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00294"></a><span class="lineno"> 294</span> <span class="comment"> Only 4 macros are required, they are:</span></div> |
|
|
|
<div class="line"><a name="l00295"></a><span class="lineno"> 295</span> <span class="comment"> - @ref DISTRHO_PLUGIN_NAME</span></div> |
|
|
|
<div class="line"><a name="l00296"></a><span class="lineno"> 296</span> <span class="comment"> - @ref DISTRHO_PLUGIN_NUM_INPUTS</span></div> |
|
|
|
<div class="line"><a name="l00297"></a><span class="lineno"> 297</span> <span class="comment"> - @ref DISTRHO_PLUGIN_NUM_OUTPUTS</span></div> |
|
|
|
<div class="line"><a name="l00298"></a><span class="lineno"> 298</span> <span class="comment"> - @ref DISTRHO_PLUGIN_URI</span></div> |
|
|
|
<div class="line"><a name="l00299"></a><span class="lineno"> 299</span> <span class="comment"> @{</span></div> |
|
|
|
<div class="line"><a name="l00300"></a><span class="lineno"> 300</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00301"></a><span class="lineno"> 301</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00302"></a><span class="lineno"> 302</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00303"></a><span class="lineno"> 303</span> <span class="comment"> The plugin name.@n</span></div> |
|
|
|
<div class="line"><a name="l00304"></a><span class="lineno"> 304</span> <span class="comment"> This is used to identify your plugin before a Plugin instance can be created.</span></div> |
|
|
|
<div class="line"><a name="l00305"></a><span class="lineno"> 305</span> <span class="comment"> @note This macro is required.</span></div> |
|
|
|
<div class="line"><a name="l00306"></a><span class="lineno"> 306</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00307"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga888482a9f695c2ca2f433e5f3172dcc4"> 307</a></span> #define DISTRHO_PLUGIN_NAME "Plugin Name"</div> |
|
|
|
<div class="line"><a name="l00308"></a><span class="lineno"> 308</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00309"></a><span class="lineno"> 309</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00310"></a><span class="lineno"> 310</span> <span class="comment"> Number of audio inputs the plugin has.</span></div> |
|
|
|
<div class="line"><a name="l00311"></a><span class="lineno"> 311</span> <span class="comment"> @note This macro is required.</span></div> |
|
|
|
<div class="line"><a name="l00312"></a><span class="lineno"> 312</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00313"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga5f4f3d9a5dc3c23882d158e636319998"> 313</a></span> #define DISTRHO_PLUGIN_NUM_INPUTS 2</div> |
|
|
|
<div class="line"><a name="l00314"></a><span class="lineno"> 314</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00315"></a><span class="lineno"> 315</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00316"></a><span class="lineno"> 316</span> <span class="comment"> Number of audio outputs the plugin has.</span></div> |
|
|
|
<div class="line"><a name="l00317"></a><span class="lineno"> 317</span> <span class="comment"> @note This macro is required.</span></div> |
|
|
|
<div class="line"><a name="l00318"></a><span class="lineno"> 318</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00319"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga917195804ebcb2bb48c9fad52b20b3ca"> 319</a></span> #define DISTRHO_PLUGIN_NUM_OUTPUTS 2</div> |
|
|
|
<div class="line"><a name="l00320"></a><span class="lineno"> 320</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00321"></a><span class="lineno"> 321</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00322"></a><span class="lineno"> 322</span> <span class="comment"> The plugin URI when exporting in LV2 format.</span></div> |
|
|
|
<div class="line"><a name="l00323"></a><span class="lineno"> 323</span> <span class="comment"> @note This macro is required.</span></div> |
|
|
|
<div class="line"><a name="l00324"></a><span class="lineno"> 324</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00325"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga9cc186448134e6a1956474b3878c97a8"> 325</a></span> #define DISTRHO_PLUGIN_URI "urn:distrho:name"</div> |
|
|
|
<div class="line"><a name="l00326"></a><span class="lineno"> 326</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00327"></a><span class="lineno"> 327</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00328"></a><span class="lineno"> 328</span> <span class="comment"> Wherever the plugin has a custom %UI.</span></div> |
|
|
|
<div class="line"><a name="l00329"></a><span class="lineno"> 329</span> <span class="comment"> @see DISTRHO_UI_USE_NANOVG</span></div> |
|
|
|
<div class="line"><a name="l00330"></a><span class="lineno"> 330</span> <span class="comment"> @see UI</span></div> |
|
|
|
<div class="line"><a name="l00331"></a><span class="lineno"> 331</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00332"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#gacf8a1af679c09637ba0bdc5f4f8e37dd"> 332</a></span> #define DISTRHO_PLUGIN_HAS_UI 1</div> |
|
|
|
<div class="line"><a name="l00333"></a><span class="lineno"> 333</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00334"></a><span class="lineno"> 334</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00335"></a><span class="lineno"> 335</span> <span class="comment"> Wherever the plugin processing is realtime-safe.@n</span></div> |
|
|
|
<div class="line"><a name="l00336"></a><span class="lineno"> 336</span> <span class="comment"> TODO - list rtsafe requirements</span></div> |
|
|
|
<div class="line"><a name="l00337"></a><span class="lineno"> 337</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00338"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga82546dd199fcea338b113f2f6da84ced"> 338</a></span> #define DISTRHO_PLUGIN_IS_RT_SAFE 1</div> |
|
|
|
<div class="line"><a name="l00339"></a><span class="lineno"> 339</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00340"></a><span class="lineno"> 340</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00341"></a><span class="lineno"> 341</span> <span class="comment"> Wherever the plugin is a synth.@n</span></div> |
|
|
|
<div class="line"><a name="l00342"></a><span class="lineno"> 342</span> <span class="comment"> @ref DISTRHO_PLUGIN_WANT_MIDI_INPUT is automatically enabled when this is too.</span></div> |
|
|
|
<div class="line"><a name="l00343"></a><span class="lineno"> 343</span> <span class="comment"> @see DISTRHO_PLUGIN_WANT_MIDI_INPUT</span></div> |
|
|
|
<div class="line"><a name="l00344"></a><span class="lineno"> 344</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00345"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga854bde6b6fdb0d47182149dbab0fed72"> 345</a></span> #define DISTRHO_PLUGIN_IS_SYNTH 1</div> |
|
|
|
<div class="line"><a name="l00346"></a><span class="lineno"> 346</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00347"></a><span class="lineno"> 347</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00348"></a><span class="lineno"> 348</span> <span class="comment"> Enable direct access between the %UI and plugin code.</span></div> |
|
|
|
<div class="line"><a name="l00349"></a><span class="lineno"> 349</span> <span class="comment"> @see UI::getPluginInstancePointer()</span></div> |
|
|
|
<div class="line"><a name="l00350"></a><span class="lineno"> 350</span> <span class="comment"> @note DO NOT USE THIS UNLESS STRICTLY NECESSARY!!</span></div> |
|
|
|
<div class="line"><a name="l00351"></a><span class="lineno"> 351</span> <span class="comment"> Try to avoid it at all costs!</span></div> |
|
|
|
<div class="line"><a name="l00352"></a><span class="lineno"> 352</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00353"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#gac6873a3950f52f3fde8e386af63b69a1"> 353</a></span> #define DISTRHO_PLUGIN_WANT_DIRECT_ACCESS 0</div> |
|
|
|
<div class="line"><a name="l00354"></a><span class="lineno"> 354</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00355"></a><span class="lineno"> 355</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00356"></a><span class="lineno"> 356</span> <span class="comment"> Wherever the plugin introduces latency during audio or midi processing.</span></div> |
|
|
|
<div class="line"><a name="l00357"></a><span class="lineno"> 357</span> <span class="comment"> @see Plugin::setLatency(uint32_t)</span></div> |
|
|
|
<div class="line"><a name="l00358"></a><span class="lineno"> 358</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00359"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#gad6b0ebf10e048f4742f29735da4d4930"> 359</a></span> #define DISTRHO_PLUGIN_WANT_LATENCY 1</div> |
|
|
|
<div class="line"><a name="l00360"></a><span class="lineno"> 360</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00361"></a><span class="lineno"> 361</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00362"></a><span class="lineno"> 362</span> <span class="comment"> Wherever the plugin wants MIDI input.@n</span></div> |
|
|
|
<div class="line"><a name="l00363"></a><span class="lineno"> 363</span> <span class="comment"> This is automatically enabled if @ref DISTRHO_PLUGIN_IS_SYNTH is true.</span></div> |
|
|
|
<div class="line"><a name="l00364"></a><span class="lineno"> 364</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00365"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#gadf2e2eb7550e4116001c816adfb04a70"> 365</a></span> #define DISTRHO_PLUGIN_WANT_MIDI_INPUT 1</div> |
|
|
|
<div class="line"><a name="l00366"></a><span class="lineno"> 366</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00367"></a><span class="lineno"> 367</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00368"></a><span class="lineno"> 368</span> <span class="comment"> Wherever the plugin wants MIDI output.</span></div> |
|
|
|
<div class="line"><a name="l00369"></a><span class="lineno"> 369</span> <span class="comment"> @see Plugin::writeMidiEvent(const MidiEvent&)</span></div> |
|
|
|
<div class="line"><a name="l00370"></a><span class="lineno"> 370</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00371"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga548522eb91344a45841a5a95ff4f8073"> 371</a></span> #define DISTRHO_PLUGIN_WANT_MIDI_OUTPUT 1</div> |
|
|
|
<div class="line"><a name="l00372"></a><span class="lineno"> 372</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00373"></a><span class="lineno"> 373</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00374"></a><span class="lineno"> 374</span> <span class="comment"> Wherever the plugin provides its own internal programs.</span></div> |
|
|
|
<div class="line"><a name="l00375"></a><span class="lineno"> 375</span> <span class="comment"> @see Plugin::initProgramName(uint32_t, String&)</span></div> |
|
|
|
<div class="line"><a name="l00376"></a><span class="lineno"> 376</span> <span class="comment"> @see Plugin::setProgram(uint32_t)</span></div> |
|
|
|
<div class="line"><a name="l00377"></a><span class="lineno"> 377</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00378"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#gad95e24b17f196260cee15255fdb5b677"> 378</a></span> #define DISTRHO_PLUGIN_WANT_PROGRAMS 1</div> |
|
|
|
<div class="line"><a name="l00379"></a><span class="lineno"> 379</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00380"></a><span class="lineno"> 380</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00381"></a><span class="lineno"> 381</span> <span class="comment"> Wherever the plugin uses internal non-parameter data.</span></div> |
|
|
|
<div class="line"><a name="l00382"></a><span class="lineno"> 382</span> <span class="comment"> @see Plugin::initState(uint32_t, String&, String&)</span></div> |
|
|
|
<div class="line"><a name="l00383"></a><span class="lineno"> 383</span> <span class="comment"> @see Plugin::setState(const char*, const char*)</span></div> |
|
|
|
<div class="line"><a name="l00384"></a><span class="lineno"> 384</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00385"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga255f43cc0997af8b56abcca260c875e0"> 385</a></span> #define DISTRHO_PLUGIN_WANT_STATE 1</div> |
|
|
|
<div class="line"><a name="l00386"></a><span class="lineno"> 386</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00387"></a><span class="lineno"> 387</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00388"></a><span class="lineno"> 388</span> <span class="comment"> Wherever the plugin wants time position information from the host.</span></div> |
|
|
|
<div class="line"><a name="l00389"></a><span class="lineno"> 389</span> <span class="comment"> @see Plugin::getTimePosition()</span></div> |
|
|
|
<div class="line"><a name="l00390"></a><span class="lineno"> 390</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00391"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga496610b956d931b1940d07da48d123f2"> 391</a></span> #define DISTRHO_PLUGIN_WANT_TIMEPOS 1</div> |
|
|
|
<div class="line"><a name="l00392"></a><span class="lineno"> 392</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00393"></a><span class="lineno"> 393</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00394"></a><span class="lineno"> 394</span> <span class="comment"> Wherever the %UI uses NanoVG for drawing instead of the default raw OpenGL calls.@n</span></div> |
|
|
|
<div class="line"><a name="l00395"></a><span class="lineno"> 395</span> <span class="comment"> When enabled your %UI instance will subclass @ref NanoWidget instead of @ref Widget.</span></div> |
|
|
|
<div class="line"><a name="l00396"></a><span class="lineno"> 396</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00397"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#gad49e79936a2aa5afa089cbc051426ccd"> 397</a></span> #define DISTRHO_UI_USE_NANOVG 1</div> |
|
|
|
<div class="line"><a name="l00398"></a><span class="lineno"> 398</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00399"></a><span class="lineno"> 399</span> <span class="comment">/**</span></div> |
|
|
|
<div class="line"><a name="l00400"></a><span class="lineno"> 400</span> <span class="comment"> The %UI URI when exporting in LV2 format.@n</span></div> |
|
|
|
<div class="line"><a name="l00401"></a><span class="lineno"> 401</span> <span class="comment"> By default this is set to @ref DISTRHO_PLUGIN_URI with "#UI" as suffix.</span></div> |
|
|
|
<div class="line"><a name="l00402"></a><span class="lineno"> 402</span> <span class="comment"> */</span></div> |
|
|
|
<div class="line"><a name="l00403"></a><span class="lineno"><a class="line" href="group__PluginMacros.html#ga420a88022da249b9f38a6046998dbd7c"> 403</a></span> #define DISTRHO_UI_URI DISTRHO_PLUGIN_URI "#UI"</div> |
|
|
|
<div class="line"><a name="l00404"></a><span class="lineno"> 404</span> <span class="comment"></span></div> |
|
|
|
<div class="line"><a name="l00405"></a><span class="lineno"> 405</span> <span class="comment">/** @} */</span></div> |
|
|
|
<div class="line"><a name="l00406"></a><span class="lineno"> 406</span> </div> |
|
|
|
<div class="line"><a name="l00407"></a><span class="lineno"> 407</span> // -----------------------------------------------------------------------------------------------------------</div> |
|
|
|
<div class="line"><a name="l00408"></a><span class="lineno"> 408</span> </div> |
|
|
|
<div class="line"><a name="l00409"></a><span class="lineno"> 409</span> END_NAMESPACE_DISTRHO</div> |
|
|
|
<div class="line"><a name="l00410"></a><span class="lineno"> 410</span> </div> |
|
|
|
<div class="line"><a name="l00411"></a><span class="lineno"> 411</span> #endif // DOXYGEN</div> |
|
|
|
</div><!-- fragment --></div><!-- contents --> |
|
|
|
<!-- start footer part --> |
|
|
|
<hr class="footer"/><address class="footer"><small> |
|
|
|
Generated on Sun Apr 26 2015 14:55:15 for DISTRHO Plugin Framework by  <a href="http://www.doxygen.org/index.html"> |
|
|
|
Generated on Sun Apr 26 2015 15:43:46 for DISTRHO Plugin Framework by  <a href="http://www.doxygen.org/index.html"> |
|
|
|
<img class="footer" src="doxygen.png" alt="doxygen"/> |
|
|
|
</a> 1.8.8 |
|
|
|
</small></address> |
|
|
|