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.

_data.cpp 15KB

9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449
  1. /*
  2. * Carla Native Plugins
  3. * Copyright (C) 2012-2018 Filipe Coelho <falktx@falktx.com>
  4. *
  5. * This program is free software; you can redistribute it and/or
  6. * modify it under the terms of the GNU General Public License as
  7. * published by the Free Software Foundation; either version 2 of
  8. * the License, or any later version.
  9. *
  10. * This program is distributed in the hope that it will be useful,
  11. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. * GNU General Public License for more details.
  14. *
  15. * For a full copy of the GNU General Public License see the doc/GPL.txt file.
  16. */
  17. #include "CarlaNative.h"
  18. #include "CarlaMIDI.h"
  19. #include "CarlaUtils.hpp"
  20. #undef DESCFUNCS
  21. #define DESCFUNCS \
  22. nullptr, nullptr, nullptr, nullptr, nullptr, \
  23. nullptr, nullptr, nullptr, nullptr, nullptr, \
  24. nullptr, nullptr, nullptr, nullptr, nullptr, \
  25. nullptr, nullptr, nullptr, nullptr, nullptr, nullptr
  26. static const NativePluginDescriptor sNativePluginDescriptors[] = {
  27. // --------------------------------------------------------------------------------------------------------------------
  28. // Simple plugins
  29. {
  30. /* category */ NATIVE_PLUGIN_CATEGORY_NONE,
  31. /* hints */ NATIVE_PLUGIN_IS_RTSAFE,
  32. /* supports */ NATIVE_PLUGIN_SUPPORTS_NOTHING,
  33. /* audioIns */ 1,
  34. /* audioOuts */ 1,
  35. /* midiIns */ 0,
  36. /* midiOuts */ 0,
  37. /* paramIns */ 0,
  38. /* paramOuts */ 0,
  39. /* name */ "Bypass",
  40. /* label */ "bypass",
  41. /* maker */ "falkTX",
  42. /* copyright */ "GNU GPL v2+",
  43. DESCFUNCS
  44. },
  45. {
  46. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  47. /* hints */ NATIVE_PLUGIN_IS_RTSAFE,
  48. /* supports */ NATIVE_PLUGIN_SUPPORTS_NOTHING,
  49. /* audioIns */ 0,
  50. /* audioOuts */ 0,
  51. /* midiIns */ 0,
  52. /* midiOuts */ 0,
  53. /* paramIns */ 5-1,
  54. /* paramOuts */ 1,
  55. /* name */ "LFO",
  56. /* label */ "lfo",
  57. /* maker */ "falkTX",
  58. /* copyright */ "GNU GPL v2+",
  59. DESCFUNCS
  60. },
  61. {
  62. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  63. /* hints */ NATIVE_PLUGIN_IS_RTSAFE,
  64. /* supports */ NATIVE_PLUGIN_SUPPORTS_EVERYTHING,
  65. /* audioIns */ 0,
  66. /* audioOuts */ 0,
  67. /* midiIns */ 1,
  68. /* midiOuts */ 1,
  69. /* paramIns */ 0,
  70. /* paramOuts */ 0,
  71. /* name */ "MIDI Channel Filter",
  72. /* label */ "midichanfilter",
  73. /* maker */ "falkTX",
  74. /* copyright */ "GNU GPL v2+",
  75. DESCFUNCS
  76. },
  77. {
  78. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  79. /* hints */ NATIVE_PLUGIN_IS_RTSAFE,
  80. /* supports */ NATIVE_PLUGIN_SUPPORTS_EVERYTHING,
  81. /* audioIns */ 0,
  82. /* audioOuts */ 0,
  83. /* midiIns */ 1,
  84. /* midiOuts */ 2,
  85. /* paramIns */ 0,
  86. /* paramOuts */ 0,
  87. /* name */ "MIDI Channel A/B",
  88. /* label */ "midichanab",
  89. /* maker */ "Milk Brewster",
  90. /* copyright */ "GNU GPL v2+",
  91. DESCFUNCS
  92. },
  93. {
  94. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  95. /* hints */ NATIVE_PLUGIN_IS_RTSAFE,
  96. /* supports */ NATIVE_PLUGIN_SUPPORTS_EVERYTHING,
  97. /* audioIns */ 0,
  98. /* audioOuts */ 0,
  99. /* midiIns */ 1,
  100. /* midiOuts */ 1,
  101. /* paramIns */ 0,
  102. /* paramOuts */ 0,
  103. /* name */ "MIDI Gain",
  104. /* label */ "midigain",
  105. /* maker */ "falkTX",
  106. /* copyright */ "GNU GPL v2+",
  107. DESCFUNCS
  108. },
  109. {
  110. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  111. /* hints */ NATIVE_PLUGIN_IS_RTSAFE,
  112. /* supports */ NATIVE_PLUGIN_SUPPORTS_EVERYTHING,
  113. /* audioIns */ 0,
  114. /* audioOuts */ 0,
  115. /* midiIns */ MAX_MIDI_CHANNELS,
  116. /* midiOuts */ 1,
  117. /* paramIns */ 0,
  118. /* paramOuts */ 0,
  119. /* name */ "MIDI Join",
  120. /* label */ "midijoin",
  121. /* maker */ "falkTX",
  122. /* copyright */ "GNU GPL v2+",
  123. DESCFUNCS
  124. },
  125. {
  126. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  127. /* hints */ NATIVE_PLUGIN_IS_RTSAFE,
  128. /* supports */ NATIVE_PLUGIN_SUPPORTS_EVERYTHING,
  129. /* audioIns */ 0,
  130. /* audioOuts */ 0,
  131. /* midiIns */ 1,
  132. /* midiOuts */ MAX_MIDI_CHANNELS,
  133. /* paramIns */ 0,
  134. /* paramOuts */ 0,
  135. /* name */ "MIDI Split",
  136. /* label */ "midisplit",
  137. /* maker */ "falkTX",
  138. /* copyright */ "GNU GPL v2+",
  139. DESCFUNCS
  140. },
  141. {
  142. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  143. /* hints */ NATIVE_PLUGIN_IS_RTSAFE,
  144. /* supports */ NATIVE_PLUGIN_SUPPORTS_EVERYTHING,
  145. /* audioIns */ 0,
  146. /* audioOuts */ 0,
  147. /* midiIns */ 1,
  148. /* midiOuts */ 1,
  149. /* paramIns */ 0,
  150. /* paramOuts */ 0,
  151. /* name */ "MIDI Through",
  152. /* label */ "midithrough",
  153. /* maker */ "falkTX",
  154. /* copyright */ "GNU GPL v2+",
  155. DESCFUNCS
  156. },
  157. {
  158. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  159. /* hints */ NATIVE_PLUGIN_IS_RTSAFE,
  160. /* supports */ NATIVE_PLUGIN_SUPPORTS_EVERYTHING,
  161. /* audioIns */ 0,
  162. /* audioOuts */ 0,
  163. /* midiIns */ 1,
  164. /* midiOuts */ 1,
  165. /* paramIns */ 2,
  166. /* paramOuts */ 0,
  167. /* name */ "MIDI Transpose",
  168. /* label */ "miditranspose",
  169. /* maker */ "falkTX",
  170. /* copyright */ "GNU GPL v2+",
  171. DESCFUNCS
  172. },
  173. {
  174. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  175. /* hints */ NATIVE_PLUGIN_IS_RTSAFE,
  176. /* supports */ NATIVE_PLUGIN_SUPPORTS_EVERYTHING,
  177. /* audioIns */ 0,
  178. /* audioOuts */ 0,
  179. /* midiIns */ 1,
  180. /* midiOuts */ 1,
  181. /* paramIns */ 1,
  182. /* paramOuts */ 0,
  183. /* name */ "MIDI Channelize",
  184. /* label */ "midichannelize",
  185. /* maker */ "falkTX",
  186. /* copyright */ "GNU GPL v2+",
  187. DESCFUNCS
  188. },
  189. // --------------------------------------------------------------------------------------------------------------------
  190. // Audio file
  191. {
  192. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  193. /* hints */ static_cast<NativePluginHints>(NATIVE_PLUGIN_IS_RTSAFE
  194. |NATIVE_PLUGIN_HAS_UI
  195. |NATIVE_PLUGIN_NEEDS_UI_OPEN_SAVE
  196. |NATIVE_PLUGIN_USES_TIME),
  197. /* supports */ NATIVE_PLUGIN_SUPPORTS_NOTHING,
  198. /* audioIns */ 0,
  199. /* audioOuts */ 2,
  200. /* midiIns */ 0,
  201. /* midiOuts */ 0,
  202. /* paramIns */ 1,
  203. /* paramOuts */ 0,
  204. /* name */ "Audio File",
  205. /* label */ "audiofile",
  206. /* maker */ "falkTX",
  207. /* copyright */ "GNU GPL v2+",
  208. DESCFUNCS
  209. },
  210. // --------------------------------------------------------------------------------------------------------------------
  211. // MIDI file and sequencer
  212. {
  213. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  214. /* hints */ static_cast<NativePluginHints>(NATIVE_PLUGIN_IS_RTSAFE
  215. |NATIVE_PLUGIN_HAS_UI
  216. |NATIVE_PLUGIN_NEEDS_UI_OPEN_SAVE
  217. |NATIVE_PLUGIN_USES_STATE
  218. |NATIVE_PLUGIN_USES_TIME),
  219. /* supports */ NATIVE_PLUGIN_SUPPORTS_NOTHING,
  220. /* audioIns */ 0,
  221. /* audioOuts */ 0,
  222. /* midiIns */ 0,
  223. /* midiOuts */ 1,
  224. /* paramIns */ 0,
  225. /* paramOuts */ 0,
  226. /* name */ "MIDI File",
  227. /* label */ "midifile",
  228. /* maker */ "falkTX",
  229. /* copyright */ "GNU GPL v2+",
  230. DESCFUNCS
  231. },
  232. #ifdef HAVE_PYQT
  233. {
  234. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  235. /* hints */ static_cast<NativePluginHints>(NATIVE_PLUGIN_IS_RTSAFE
  236. |NATIVE_PLUGIN_HAS_UI
  237. |NATIVE_PLUGIN_USES_STATE
  238. |NATIVE_PLUGIN_USES_TIME),
  239. /* supports */ NATIVE_PLUGIN_SUPPORTS_NOTHING,
  240. /* audioIns */ 0,
  241. /* audioOuts */ 0,
  242. /* midiIns */ 0,
  243. /* midiOuts */ 1,
  244. /* paramIns */ 4,
  245. /* paramOuts */ 0,
  246. /* name */ "MIDI Pattern",
  247. /* label */ "midipattern",
  248. /* maker */ "falkTX, tatch",
  249. /* copyright */ "GNU GPL v2+",
  250. DESCFUNCS
  251. },
  252. #endif
  253. // --------------------------------------------------------------------------------------------------------------------
  254. // Carla
  255. #ifdef HAVE_PYQT
  256. {
  257. /* category */ NATIVE_PLUGIN_CATEGORY_OTHER,
  258. /* hints */ static_cast<NativePluginHints>(NATIVE_PLUGIN_IS_SYNTH
  259. |NATIVE_PLUGIN_HAS_UI
  260. |NATIVE_PLUGIN_NEEDS_UI_MAIN_THREAD
  261. |NATIVE_PLUGIN_USES_STATE
  262. |NATIVE_PLUGIN_USES_TIME),
  263. /* supports */ static_cast<NativePluginSupports>(NATIVE_PLUGIN_SUPPORTS_EVERYTHING),
  264. /* audioIns */ 2,
  265. /* audioOuts */ 2,
  266. /* midiIns */ 1,
  267. /* midiOuts */ 1,
  268. /* paramIns */ 0,
  269. /* paramOuts */ 0,
  270. /* name */ "Carla-Rack",
  271. /* label */ "carlarack",
  272. /* maker */ "falkTX",
  273. /* copyright */ "GNU GPL v2+",
  274. DESCFUNCS
  275. },
  276. {
  277. /* category */ NATIVE_PLUGIN_CATEGORY_OTHER,
  278. /* hints */ static_cast<NativePluginHints>(NATIVE_PLUGIN_IS_SYNTH
  279. |NATIVE_PLUGIN_HAS_UI
  280. |NATIVE_PLUGIN_NEEDS_UI_MAIN_THREAD
  281. |NATIVE_PLUGIN_USES_STATE
  282. |NATIVE_PLUGIN_USES_TIME),
  283. /* supports */ static_cast<NativePluginSupports>(NATIVE_PLUGIN_SUPPORTS_EVERYTHING),
  284. /* audioIns */ 2,
  285. /* audioOuts */ 2,
  286. /* midiIns */ 1,
  287. /* midiOuts */ 0,
  288. /* paramIns */ 0,
  289. /* paramOuts */ 0,
  290. /* name */ "Carla-Rack (no midi out)",
  291. /* label */ "carlarack-nomidiout",
  292. /* maker */ "falkTX",
  293. /* copyright */ "GNU GPL v2+",
  294. DESCFUNCS
  295. },
  296. {
  297. /* category */ NATIVE_PLUGIN_CATEGORY_OTHER,
  298. /* hints */ static_cast<NativePluginHints>(NATIVE_PLUGIN_IS_SYNTH
  299. |NATIVE_PLUGIN_HAS_UI
  300. |NATIVE_PLUGIN_NEEDS_UI_MAIN_THREAD
  301. |NATIVE_PLUGIN_USES_STATE
  302. |NATIVE_PLUGIN_USES_TIME),
  303. /* supports */ static_cast<NativePluginSupports>(NATIVE_PLUGIN_SUPPORTS_EVERYTHING),
  304. /* audioIns */ 2,
  305. /* audioOuts */ 2,
  306. /* midiIns */ 1,
  307. /* midiOuts */ 1,
  308. /* paramIns */ 0,
  309. /* paramOuts */ 0,
  310. /* name */ "Carla-Patchbay",
  311. /* label */ "carlapatchbay",
  312. /* maker */ "falkTX",
  313. /* copyright */ "GNU GPL v2+",
  314. DESCFUNCS
  315. },
  316. {
  317. /* category */ NATIVE_PLUGIN_CATEGORY_OTHER,
  318. /* hints */ static_cast<NativePluginHints>(NATIVE_PLUGIN_IS_SYNTH
  319. |NATIVE_PLUGIN_HAS_UI
  320. |NATIVE_PLUGIN_NEEDS_UI_MAIN_THREAD
  321. |NATIVE_PLUGIN_USES_STATE
  322. |NATIVE_PLUGIN_USES_TIME),
  323. /* supports */ static_cast<NativePluginSupports>(NATIVE_PLUGIN_SUPPORTS_EVERYTHING),
  324. /* audioIns */ 3,
  325. /* audioOuts */ 2,
  326. /* midiIns */ 1,
  327. /* midiOuts */ 1,
  328. /* paramIns */ 0,
  329. /* paramOuts */ 0,
  330. /* name */ "Carla-Patchbay (sidechain)",
  331. /* label */ "carlapatchbay3s",
  332. /* maker */ "falkTX",
  333. /* copyright */ "GNU GPL v2+",
  334. DESCFUNCS
  335. },
  336. {
  337. /* category */ NATIVE_PLUGIN_CATEGORY_OTHER,
  338. /* hints */ static_cast<NativePluginHints>(NATIVE_PLUGIN_IS_SYNTH
  339. |NATIVE_PLUGIN_HAS_UI
  340. |NATIVE_PLUGIN_NEEDS_UI_MAIN_THREAD
  341. |NATIVE_PLUGIN_USES_STATE
  342. |NATIVE_PLUGIN_USES_TIME),
  343. /* supports */ static_cast<NativePluginSupports>(NATIVE_PLUGIN_SUPPORTS_EVERYTHING),
  344. /* audioIns */ 16,
  345. /* audioOuts */ 16,
  346. /* midiIns */ 1,
  347. /* midiOuts */ 1,
  348. /* paramIns */ 0,
  349. /* paramOuts */ 0,
  350. /* name */ "Carla-Patchbay (16chan)",
  351. /* label */ "carlapatchbay16",
  352. /* maker */ "falkTX",
  353. /* copyright */ "GNU GPL v2+",
  354. DESCFUNCS
  355. },
  356. {
  357. /* category */ NATIVE_PLUGIN_CATEGORY_OTHER,
  358. /* hints */ static_cast<NativePluginHints>(NATIVE_PLUGIN_IS_SYNTH
  359. |NATIVE_PLUGIN_HAS_UI
  360. |NATIVE_PLUGIN_NEEDS_UI_MAIN_THREAD
  361. |NATIVE_PLUGIN_USES_STATE
  362. |NATIVE_PLUGIN_USES_TIME),
  363. /* supports */ static_cast<NativePluginSupports>(NATIVE_PLUGIN_SUPPORTS_EVERYTHING),
  364. /* audioIns */ 32,
  365. /* audioOuts */ 32,
  366. /* midiIns */ 1,
  367. /* midiOuts */ 1,
  368. /* paramIns */ 0,
  369. /* paramOuts */ 0,
  370. /* name */ "Carla-Patchbay (32chan)",
  371. /* label */ "carlapatchbay32",
  372. /* maker */ "falkTX",
  373. /* copyright */ "GNU GPL v2+",
  374. DESCFUNCS
  375. },
  376. #endif
  377. // --------------------------------------------------------------------------------------------------------------------
  378. // External-UI plugins
  379. #ifdef HAVE_PYQT
  380. {
  381. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  382. /* hints */ static_cast<NativePluginHints>(NATIVE_PLUGIN_IS_RTSAFE
  383. |NATIVE_PLUGIN_HAS_UI
  384. |NATIVE_PLUGIN_NEEDS_FIXED_BUFFERS),
  385. /* supports */ NATIVE_PLUGIN_SUPPORTS_NOTHING,
  386. /* audioIns */ 2,
  387. /* audioOuts */ 0,
  388. /* midiIns */ 0,
  389. /* midiOuts */ 0,
  390. /* paramIns */ 2,
  391. /* paramOuts */ 2,
  392. /* name */ "Big Meter",
  393. /* label */ "bigmeter",
  394. /* maker */ "falkTX",
  395. /* copyright */ "GNU GPL v2+",
  396. DESCFUNCS
  397. },
  398. {
  399. /* category */ NATIVE_PLUGIN_CATEGORY_UTILITY,
  400. /* hints */ static_cast<NativePluginHints>(NATIVE_PLUGIN_IS_RTSAFE
  401. |NATIVE_PLUGIN_HAS_UI),
  402. /* supports */ NATIVE_PLUGIN_SUPPORTS_NOTHING,
  403. /* audioIns */ 0,
  404. /* audioOuts */ 0,
  405. /* midiIns */ 0,
  406. /* midiOuts */ 0,
  407. /* paramIns */ 1,
  408. /* paramOuts */ 0,
  409. /* name */ "Notes",
  410. /* label */ "notes",
  411. /* maker */ "falkTX",
  412. /* copyright */ "GNU GPL v2+",
  413. DESCFUNCS
  414. },
  415. #endif
  416. #ifdef HAVE_EXTERNAL_PLUGINS
  417. # define CARLA_EXTERNAL_PLUGINS_INCLUDED_DIRECTLY
  418. # include "external/_data.cpp"
  419. #endif
  420. };
  421. #undef DESCFUNCS
  422. // --------------------------------------------------------------------------------------------------------------------
  423. const NativePluginDescriptor* carla_get_native_plugins_data(uint32_t* count)
  424. {
  425. CARLA_SAFE_ASSERT_RETURN(count != nullptr, nullptr);
  426. *count = static_cast<uint32_t>(sizeof(sNativePluginDescriptors)/sizeof(NativePluginDescriptor));
  427. return sNativePluginDescriptors;
  428. }
  429. // --------------------------------------------------------------------------------------------------------------------