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.

1065 lines
31KB

  1. /*
  2. * DISTRHO Cardinal Plugin
  3. * Copyright (C) 2021 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 3 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 LICENSE file.
  16. */
  17. #include <plugin.hpp>
  18. #include "DistrhoUtils.hpp"
  19. // Cardinal (built-in)
  20. #include "Cardinal/src/plugin.hpp"
  21. #ifndef NOPLUGINS
  22. // AmalgamatedHarmonics
  23. #include "AmalgamatedHarmonics/src/AH.hpp"
  24. // AnimatedCircuits
  25. #include "AnimatedCircuits/src/plugin.hpp"
  26. // AS
  27. #define modelADSR modelASADSR
  28. #define modelVCA modelASVCA
  29. #include "AS/src/AS.hpp"
  30. #undef modelADSR
  31. #undef modelVCA
  32. // AudibleInstruments
  33. #include "AudibleInstruments/src/plugin.hpp"
  34. // Befaco
  35. #include "Befaco/src/plugin.hpp"
  36. // Bidoo
  37. #include "Bidoo/src/plugin.hpp"
  38. // BogaudioModules
  39. #define modelADSR modelBogaudioADSR
  40. #define modelLFO modelBogaudioLFO
  41. #define modelNoise modelBogaudioNoise
  42. #define modelVCA modelBogaudioVCA
  43. #define modelVCF modelBogaudioVCF
  44. #define modelVCO modelBogaudioVCO
  45. #include "BogaudioModules/src/AD.hpp"
  46. #include "BogaudioModules/src/Additator.hpp"
  47. #include "BogaudioModules/src/AddrSeqX.hpp"
  48. #include "BogaudioModules/src/ADSR.hpp"
  49. #include "BogaudioModules/src/AMRM.hpp"
  50. #include "BogaudioModules/src/Analyzer.hpp"
  51. #include "BogaudioModules/src/AnalyzerXL.hpp"
  52. #include "BogaudioModules/src/Assign.hpp"
  53. #include "BogaudioModules/src/ASR.hpp"
  54. #include "BogaudioModules/src/Arp.hpp"
  55. #include "BogaudioModules/src/Blank3.hpp"
  56. #include "BogaudioModules/src/Blank6.hpp"
  57. #include "BogaudioModules/src/Bool.hpp"
  58. #include "BogaudioModules/src/Chirp.hpp"
  59. #include "BogaudioModules/src/Clpr.hpp"
  60. #include "BogaudioModules/src/Cmp.hpp"
  61. #include "BogaudioModules/src/CmpDist.hpp"
  62. #include "BogaudioModules/src/CVD.hpp"
  63. #include "BogaudioModules/src/DADSRH.hpp"
  64. #include "BogaudioModules/src/DADSRHPlus.hpp"
  65. #include "BogaudioModules/src/Detune.hpp"
  66. #include "BogaudioModules/src/DGate.hpp"
  67. #include "BogaudioModules/src/Edge.hpp"
  68. #include "BogaudioModules/src/EightFO.hpp"
  69. #include "BogaudioModules/src/EightOne.hpp"
  70. #include "BogaudioModules/src/EQ.hpp"
  71. #include "BogaudioModules/src/EQS.hpp"
  72. #include "BogaudioModules/src/FFB.hpp"
  73. #include "BogaudioModules/src/FlipFlop.hpp"
  74. #include "BogaudioModules/src/FMOp.hpp"
  75. #include "BogaudioModules/src/Follow.hpp"
  76. #include "BogaudioModules/src/FourFO.hpp"
  77. #include "BogaudioModules/src/FourMan.hpp"
  78. #include "BogaudioModules/src/Inv.hpp"
  79. #include "BogaudioModules/src/LFO.hpp"
  80. #include "BogaudioModules/src/Lgsw.hpp"
  81. #include "BogaudioModules/src/LLFO.hpp"
  82. #include "BogaudioModules/src/LLPG.hpp"
  83. #include "BogaudioModules/src/Lmtr.hpp"
  84. #include "BogaudioModules/src/LPG.hpp"
  85. #include "BogaudioModules/src/LVCF.hpp"
  86. #include "BogaudioModules/src/LVCO.hpp"
  87. #include "BogaudioModules/src/Manual.hpp"
  88. #include "BogaudioModules/src/Matrix18.hpp"
  89. #include "BogaudioModules/src/Matrix44.hpp"
  90. #include "BogaudioModules/src/Matrix81.hpp"
  91. #include "BogaudioModules/src/Matrix88.hpp"
  92. #include "BogaudioModules/src/Matrix88Cv.hpp"
  93. #include "BogaudioModules/src/Matrix88M.hpp"
  94. #include "BogaudioModules/src/MegaGate.hpp"
  95. #include "BogaudioModules/src/Mix1.hpp"
  96. #include "BogaudioModules/src/Mix2.hpp"
  97. #include "BogaudioModules/src/Mix4.hpp"
  98. #include "BogaudioModules/src/Mix4x.hpp"
  99. #include "BogaudioModules/src/Mix8x.hpp"
  100. #include "BogaudioModules/src/Mono.hpp"
  101. #include "BogaudioModules/src/Mult.hpp"
  102. #include "BogaudioModules/src/Mumix.hpp"
  103. #include "BogaudioModules/src/Mute8.hpp"
  104. #include "BogaudioModules/src/Noise.hpp"
  105. #include "BogaudioModules/src/Nsgt.hpp"
  106. #include "BogaudioModules/src/Offset.hpp"
  107. #include "BogaudioModules/src/OneEight.hpp"
  108. #include "BogaudioModules/src/Pan.hpp"
  109. #include "BogaudioModules/src/PEQ.hpp"
  110. #include "BogaudioModules/src/PEQ6.hpp"
  111. #include "BogaudioModules/src/PEQ6XF.hpp"
  112. #include "BogaudioModules/src/PEQ14.hpp"
  113. #include "BogaudioModules/src/PEQ14XF.hpp"
  114. #include "BogaudioModules/src/Pgmr.hpp"
  115. #include "BogaudioModules/src/PgmrX.hpp"
  116. #include "BogaudioModules/src/PolyCon16.hpp"
  117. #include "BogaudioModules/src/PolyCon8.hpp"
  118. #include "BogaudioModules/src/PolyMult.hpp"
  119. #include "BogaudioModules/src/PolyOff16.hpp"
  120. #include "BogaudioModules/src/PolyOff8.hpp"
  121. #include "BogaudioModules/src/Pressor.hpp"
  122. #include "BogaudioModules/src/Pulse.hpp"
  123. #include "BogaudioModules/src/Ranalyzer.hpp"
  124. #include "BogaudioModules/src/Reftone.hpp"
  125. #include "BogaudioModules/src/RGate.hpp"
  126. #include "BogaudioModules/src/SampleHold.hpp"
  127. #include "BogaudioModules/src/Shaper.hpp"
  128. #include "BogaudioModules/src/ShaperPlus.hpp"
  129. #include "BogaudioModules/src/Sine.hpp"
  130. #include "BogaudioModules/src/Slew.hpp"
  131. #include "BogaudioModules/src/Stack.hpp"
  132. #include "BogaudioModules/src/Sums.hpp"
  133. #include "BogaudioModules/src/Switch.hpp"
  134. #include "BogaudioModules/src/Switch1616.hpp"
  135. #include "BogaudioModules/src/Switch18.hpp"
  136. #include "BogaudioModules/src/Switch44.hpp"
  137. #include "BogaudioModules/src/Switch81.hpp"
  138. #include "BogaudioModules/src/Switch88.hpp"
  139. #include "BogaudioModules/src/UMix.hpp"
  140. #include "BogaudioModules/src/Unison.hpp"
  141. #include "BogaudioModules/src/VCA.hpp"
  142. #include "BogaudioModules/src/VCAmp.hpp"
  143. #include "BogaudioModules/src/VCF.hpp"
  144. #include "BogaudioModules/src/VCM.hpp"
  145. #include "BogaudioModules/src/VCO.hpp"
  146. #include "BogaudioModules/src/Velo.hpp"
  147. #include "BogaudioModules/src/Vish.hpp"
  148. #include "BogaudioModules/src/VU.hpp"
  149. #include "BogaudioModules/src/Walk.hpp"
  150. #include "BogaudioModules/src/Walk2.hpp"
  151. #include "BogaudioModules/src/XCO.hpp"
  152. #include "BogaudioModules/src/XFade.hpp"
  153. #undef modelADSR
  154. #undef modelLFO
  155. #undef modelNoise
  156. #undef modelVCA
  157. #undef modelVCF
  158. #undef modelVCO
  159. // cf
  160. #include "cf/src/plugin.hpp"
  161. // ESeries
  162. #include "ESeries/src/plugin.hpp"
  163. // Fundamental
  164. #include "Fundamental/src/plugin.hpp"
  165. // GrandeModular
  166. #include "GrandeModular/src/plugin.hpp"
  167. // ImpromptuModular
  168. /* NOTE too much noise in original include, do this a different way
  169. // #include "ImpromptuModular/src/ImpromptuModular.hpp"
  170. */
  171. extern Model *modelBigButtonSeq;
  172. extern Model *modelBigButtonSeq2;
  173. extern Model *modelChordKey;
  174. extern Model *modelChordKeyExpander;
  175. extern Model *modelClocked;
  176. extern Model *modelClockedExpander;
  177. extern Model *modelClkd;
  178. extern Model *modelCvPad;
  179. extern Model *modelFoundry;
  180. extern Model *modelFoundryExpander;
  181. extern Model *modelFourView;
  182. extern Model *modelGateSeq64;
  183. extern Model *modelGateSeq64Expander;
  184. extern Model *modelHotkey;
  185. extern Model *modelPart;
  186. extern Model *modelPhraseSeq16;
  187. extern Model *modelPhraseSeq32;
  188. extern Model *modelPhraseSeqExpander;
  189. extern Model *modelProbKey;
  190. // extern Model *modelProbKeyExpander;
  191. extern Model *modelSemiModularSynth;
  192. extern Model *modelTact;
  193. extern Model *modelTact1;
  194. extern Model *modelTactG;
  195. extern Model *modelTwelveKey;
  196. extern Model *modelWriteSeq32;
  197. extern Model *modelWriteSeq64;
  198. extern Model *modelBlankPanel;
  199. // JW-Modules
  200. #define modelQuantizer modelJWQuantizer
  201. #include "JW-Modules/src/JWModules.hpp"
  202. #undef modelQuantizer
  203. // rackwindows
  204. #include "rackwindows/src/plugin.hpp"
  205. // ValleyAudio
  206. /* does not build against v2
  207. #include "ValleyAudio/src/Valley.hpp"
  208. */
  209. // ZetaCarinaeModules
  210. #include "ZetaCarinaeModules/src/plugin.hpp"
  211. #endif // NOPLUGINS
  212. // stuff that reads config files, we dont want that
  213. int loadConsoleType() { return 0; }
  214. int loadDirectOutMode() { return 0; }
  215. bool loadDarkAsDefault() { return true; }
  216. bool loadQuality() { return false; }
  217. void saveConsoleType(int) {}
  218. void saveDarkAsDefault(bool) {}
  219. void saveDirectOutMode(bool) {}
  220. void saveHighQualityAsDefault(bool) {}
  221. // plugin instances
  222. Plugin* pluginInstance__Cardinal;
  223. #ifndef NOPLUGINS
  224. Plugin* pluginInstance__AmalgamatedHarmonics;
  225. Plugin* pluginInstance__AnimatedCircuits;
  226. Plugin* pluginInstance__AS;
  227. Plugin* pluginInstance__AudibleInstruments;
  228. Plugin* pluginInstance__Befaco;
  229. Plugin* pluginInstance__Bidoo;
  230. Plugin* pluginInstance__BogaudioModules;
  231. Plugin* pluginInstance__cf;
  232. Plugin* pluginInstance__ESeries;
  233. Plugin* pluginInstance__Fundamental;
  234. Plugin* pluginInstance__GrandeModular;
  235. extern Plugin* pluginInstance__ImpromptuModular;
  236. Plugin* pluginInstance__JW;
  237. Plugin* pluginInstance__rackwindows;
  238. Plugin* pluginInstance__ValleyAudio;
  239. Plugin* pluginInstance__ZetaCarinaeModules;
  240. #endif // NOPLUGINS
  241. namespace rack {
  242. namespace asset {
  243. std::string pluginManifest(const std::string& dirname);
  244. std::string pluginPath(const std::string& dirname);
  245. }
  246. // core plugins
  247. namespace core {
  248. extern Model* modelAudioInterface;
  249. extern Model* modelAudioInterface2;
  250. extern Model* modelAudioInterface16;
  251. extern Model* modelMIDI_CV;
  252. extern Model* modelMIDI_CC;
  253. extern Model* modelMIDI_Gate;
  254. extern Model* modelMIDI_Map;
  255. extern Model* modelCV_MIDI;
  256. extern Model* modelCV_CC;
  257. extern Model* modelCV_Gate;
  258. extern Model* modelBlank;
  259. extern Model* modelNotes;
  260. }
  261. // regular plugins
  262. namespace plugin {
  263. struct StaticPluginLoader {
  264. Plugin* const plugin;
  265. FILE* file;
  266. json_t* rootJ;
  267. StaticPluginLoader(Plugin* const p, const char* const name)
  268. : plugin(p),
  269. file(nullptr),
  270. rootJ(nullptr)
  271. {
  272. #ifdef DEBUG
  273. DEBUG("Loading plugin module %s", name);
  274. #endif
  275. p->path = asset::pluginPath(name);
  276. const std::string manifestFilename = asset::pluginManifest(name);
  277. if ((file = std::fopen(manifestFilename.c_str(), "r")) == nullptr)
  278. {
  279. d_stderr2("Manifest file %s does not exist", manifestFilename.c_str());
  280. return;
  281. }
  282. json_error_t error;
  283. if ((rootJ = json_loadf(file, 0, &error)) == nullptr)
  284. {
  285. d_stderr2("JSON parsing error at %s %d:%d %s", manifestFilename.c_str(), error.line, error.column, error.text);
  286. return;
  287. }
  288. // force ABI, we use static plugins so this doesnt matter as long as it builds
  289. json_t* const version = json_string((APP_VERSION_MAJOR + ".0").c_str());
  290. json_object_set(rootJ, "version", version);
  291. json_decref(version);
  292. }
  293. ~StaticPluginLoader()
  294. {
  295. if (rootJ != nullptr)
  296. {
  297. plugin->fromJson(rootJ);
  298. json_decref(rootJ);
  299. plugins.push_back(plugin);
  300. }
  301. if (file != nullptr)
  302. std::fclose(file);
  303. }
  304. bool ok() const noexcept
  305. {
  306. return rootJ != nullptr;
  307. }
  308. };
  309. static void initStatic__Core()
  310. {
  311. Plugin* const p = new Plugin;
  312. const StaticPluginLoader spl(p, "Core");
  313. if (spl.ok())
  314. {
  315. p->addModel(rack::core::modelAudioInterface);
  316. p->addModel(rack::core::modelAudioInterface2);
  317. p->addModel(rack::core::modelAudioInterface16);
  318. p->addModel(rack::core::modelMIDI_CV);
  319. p->addModel(rack::core::modelMIDI_CC);
  320. p->addModel(rack::core::modelMIDI_Gate);
  321. p->addModel(rack::core::modelMIDI_Map);
  322. p->addModel(rack::core::modelCV_MIDI);
  323. p->addModel(rack::core::modelCV_CC);
  324. p->addModel(rack::core::modelCV_Gate);
  325. p->addModel(rack::core::modelBlank);
  326. p->addModel(rack::core::modelNotes);
  327. }
  328. }
  329. static void initStatic__Cardinal()
  330. {
  331. Plugin* const p = new Plugin;
  332. pluginInstance__Cardinal = p;
  333. const StaticPluginLoader spl(p, "Cardinal");
  334. if (spl.ok())
  335. {
  336. p->addModel(modelGlBars);
  337. p->addModel(modelHostParameters);
  338. p->addModel(modelHostTime);
  339. }
  340. }
  341. #ifndef NOPLUGINS
  342. static void initStatic__AmalgamatedHarmonics()
  343. {
  344. Plugin* const p = new Plugin;
  345. pluginInstance__AmalgamatedHarmonics = p;
  346. const StaticPluginLoader spl(p, "AmalgamatedHarmonics");
  347. if (spl.ok())
  348. {
  349. p->addModel(modelArp31);
  350. p->addModel(modelArp32);
  351. p->addModel(modelBombe);
  352. p->addModel(modelChord);
  353. p->addModel(modelCircle);
  354. p->addModel(modelGalaxy);
  355. p->addModel(modelGenerative);
  356. p->addModel(modelImp);
  357. p->addModel(modelImperfect2);
  358. p->addModel(modelProgress2);
  359. p->addModel(modelRuckus);
  360. p->addModel(modelScaleQuantizer2);
  361. p->addModel(modelSLN);
  362. p->addModel(modelMuxDeMux);
  363. p->addModel(modelPolyProbe);
  364. p->addModel(modelPolyScope);
  365. p->addModel(modelPolyUtils);
  366. p->addModel(modelPolyVolt);
  367. p->addModel(modelScaleQuantizer);
  368. p->addModel(modelArpeggiator2);
  369. p->addModel(modelProgress);
  370. }
  371. }
  372. static void initStatic__AnimatedCircuits()
  373. {
  374. Plugin* const p = new Plugin;
  375. pluginInstance__AnimatedCircuits = p;
  376. const StaticPluginLoader spl(p, "AnimatedCircuits");
  377. if (spl.ok())
  378. {
  379. p->addModel(model_AC_Folding);
  380. }
  381. }
  382. static void initStatic__AS()
  383. {
  384. Plugin* const p = new Plugin;
  385. pluginInstance__AS = p;
  386. const StaticPluginLoader spl(p, "AS");
  387. if (spl.ok())
  388. {
  389. #define modelADSR modelASADSR
  390. #define modelVCA modelASVCA
  391. //OSCILLATORS
  392. p->addModel(modelSineOsc);
  393. p->addModel(modelSawOsc);
  394. //TOOLS
  395. p->addModel(modelADSR);
  396. p->addModel(modelVCA);
  397. p->addModel(modelQuadVCA);
  398. p->addModel(modelTriLFO);
  399. p->addModel(modelAtNuVrTr);
  400. p->addModel(modelBPMClock);
  401. p->addModel(modelSEQ16);
  402. p->addModel(modelMixer2ch);
  403. p->addModel(modelMixer4ch);
  404. p->addModel(modelMixer8ch);
  405. p->addModel(modelMonoVUmeter);
  406. p->addModel(modelStereoVUmeter);
  407. p->addModel(modelMultiple2_5);
  408. p->addModel(modelMerge2_5);
  409. p->addModel(modelSteps);
  410. p->addModel(modelLaunchGate);
  411. p->addModel(modelKillGate);
  412. p->addModel(modelFlow);
  413. p->addModel(modelSignalDelay);
  414. p->addModel(modelTriggersMKI);
  415. p->addModel(modelTriggersMKII);
  416. p->addModel(modelTriggersMKIII);
  417. p->addModel(modelBPMCalc);
  418. p->addModel(modelBPMCalc2);
  419. p->addModel(modelCv2T);
  420. p->addModel(modelZeroCV2T);
  421. p->addModel(modelReScale);
  422. //EFFECTS
  423. p->addModel(modelDelayPlusFx);
  424. p->addModel(modelDelayPlusStereoFx);
  425. p->addModel(modelPhaserFx);
  426. p->addModel(modelReverbFx);
  427. p->addModel(modelReverbStereoFx);
  428. p->addModel(modelSuperDriveFx);
  429. p->addModel(modelSuperDriveStereoFx);
  430. p->addModel(modelTremoloFx);
  431. p->addModel(modelTremoloStereoFx);
  432. p->addModel(modelWaveShaper);
  433. p->addModel(modelWaveShaperStereo);
  434. //BLANK PANELS
  435. p->addModel(modelBlankPanel4);
  436. p->addModel(modelBlankPanel6);
  437. p->addModel(modelBlankPanel8);
  438. p->addModel(modelBlankPanelSpecial);
  439. #undef modelADSR
  440. #undef modelVCA
  441. }
  442. }
  443. static void initStatic__AudibleInstruments()
  444. {
  445. Plugin* const p = new Plugin;
  446. pluginInstance__AudibleInstruments = p;
  447. const StaticPluginLoader spl(p, "AudibleInstruments");
  448. if (spl.ok())
  449. {
  450. p->addModel(modelBraids);
  451. p->addModel(modelPlaits);
  452. p->addModel(modelElements);
  453. p->addModel(modelTides);
  454. p->addModel(modelTides2);
  455. p->addModel(modelClouds);
  456. p->addModel(modelWarps);
  457. p->addModel(modelRings);
  458. p->addModel(modelLinks);
  459. p->addModel(modelKinks);
  460. p->addModel(modelShades);
  461. p->addModel(modelBranches);
  462. p->addModel(modelBlinds);
  463. p->addModel(modelVeils);
  464. p->addModel(modelFrames);
  465. p->addModel(modelMarbles);
  466. p->addModel(modelStages);
  467. p->addModel(modelRipples);
  468. p->addModel(modelShelves);
  469. p->addModel(modelStreams);
  470. }
  471. }
  472. static void initStatic__Befaco()
  473. {
  474. Plugin* const p = new Plugin;
  475. pluginInstance__Befaco = p;
  476. const StaticPluginLoader spl(p, "Befaco");
  477. if (spl.ok())
  478. {
  479. p->addModel(modelEvenVCO);
  480. p->addModel(modelRampage);
  481. p->addModel(modelABC);
  482. p->addModel(modelSpringReverb);
  483. p->addModel(modelMixer);
  484. p->addModel(modelSlewLimiter);
  485. p->addModel(modelDualAtenuverter);
  486. }
  487. }
  488. static void initStatic__Bidoo()
  489. {
  490. Plugin* const p = new Plugin;
  491. pluginInstance__Bidoo = p;
  492. const StaticPluginLoader spl(p, "Bidoo");
  493. if (spl.ok())
  494. {
  495. p->addModel(modelTOCANTE);
  496. p->addModel(modelLATE);
  497. p->addModel(modelDIKTAT);
  498. p->addModel(modelDTROY);
  499. p->addModel(modelBORDL);
  500. p->addModel(modelZOUMAI);
  501. p->addModel(modelMU);
  502. p->addModel(modelCHUTE);
  503. p->addModel(modelLOURDE);
  504. p->addModel(modelACNE);
  505. p->addModel(modelMS);
  506. p->addModel(modelDUKE);
  507. p->addModel(modelMOIRE);
  508. p->addModel(modelPILOT);
  509. p->addModel(modelHUITRE);
  510. p->addModel(modelOUAIVE);
  511. p->addModel(modelPOUPRE);
  512. p->addModel(modelMAGMA);
  513. p->addModel(modelOAI);
  514. p->addModel(modelCANARD);
  515. p->addModel(modelEMILE);
  516. p->addModel(modelFORK);
  517. p->addModel(modelTIARE);
  518. //p->addModel(modelCLACOS);
  519. //p->addModel(modelPENEQUE);
  520. p->addModel(modelLIMONADE);
  521. p->addModel(modelLIMBO);
  522. p->addModel(modelPERCO);
  523. p->addModel(modelBAFIS);
  524. p->addModel(modelFFILTR);
  525. p->addModel(modelBAR);
  526. p->addModel(modelMINIBAR);
  527. p->addModel(modelZINC);
  528. p->addModel(modelFREIN);
  529. p->addModel(modelHCTIP);
  530. //p->addModel(modelCURT);
  531. p->addModel(modelDFUZE);
  532. p->addModel(modelREI);
  533. p->addModel(modelRABBIT);
  534. p->addModel(modelBISTROT);
  535. p->addModel(modelSIGMA);
  536. p->addModel(modelGARCON);
  537. p->addModel(modelVOID);
  538. // NOTE disabled in Cardinal due to curl usage
  539. // p->addModel(modelANTN);
  540. // intentionally remove known bad plugin
  541. if (json_t* const modules = json_object_get(spl.rootJ, "modules"))
  542. {
  543. size_t i;
  544. json_t* v;
  545. json_array_foreach(modules, i, v)
  546. {
  547. if (json_t* const slug = json_object_get(v, "slug"))
  548. {
  549. if (const char* const value = json_string_value(slug))
  550. {
  551. if (std::strcmp(value, "antN") == 0)
  552. {
  553. json_array_remove(modules, i);
  554. break;
  555. }
  556. }
  557. }
  558. }
  559. }
  560. }
  561. }
  562. static void initStatic__BogaudioModules()
  563. {
  564. Plugin* const p = new Plugin;
  565. pluginInstance__BogaudioModules = p;
  566. const StaticPluginLoader spl(p, "BogaudioModules");
  567. if (spl.ok())
  568. {
  569. #define modelADSR modelBogaudioADSR
  570. #define modelLFO modelBogaudioLFO
  571. #define modelNoise modelBogaudioNoise
  572. #define modelVCA modelBogaudioVCA
  573. #define modelVCF modelBogaudioVCF
  574. #define modelVCO modelBogaudioVCO
  575. p->addModel(modelVCO);
  576. p->addModel(modelLVCO);
  577. p->addModel(modelSine);
  578. p->addModel(modelPulse);
  579. p->addModel(modelXCO);
  580. p->addModel(modelAdditator);
  581. p->addModel(modelFMOp);
  582. p->addModel(modelChirp);
  583. p->addModel(modelLFO);
  584. p->addModel(modelLLFO);
  585. p->addModel(modelFourFO);
  586. p->addModel(modelEightFO);
  587. p->addModel(modelVCF);
  588. p->addModel(modelLVCF);
  589. p->addModel(modelFFB);
  590. p->addModel(modelEQ);
  591. p->addModel(modelEQS);
  592. p->addModel(modelLPG);
  593. p->addModel(modelLLPG);
  594. p->addModel(modelMegaGate);
  595. p->addModel(modelPEQ);
  596. p->addModel(modelPEQ6);
  597. p->addModel(modelPEQ6XF);
  598. p->addModel(modelPEQ14);
  599. p->addModel(modelPEQ14XF);
  600. p->addModel(modelDADSRH);
  601. p->addModel(modelDADSRHPlus);
  602. p->addModel(modelShaper);
  603. p->addModel(modelShaperPlus);
  604. p->addModel(modelAD);
  605. p->addModel(modelASR);
  606. p->addModel(modelADSR);
  607. p->addModel(modelVish);
  608. p->addModel(modelFollow);
  609. p->addModel(modelDGate);
  610. p->addModel(modelRGate);
  611. p->addModel(modelEdge);
  612. p->addModel(modelNoise);
  613. p->addModel(modelSampleHold);
  614. p->addModel(modelWalk2);
  615. p->addModel(modelWalk);
  616. p->addModel(modelMix8);
  617. p->addModel(modelMix8x);
  618. p->addModel(modelMix4);
  619. p->addModel(modelMix4x);
  620. p->addModel(modelMix2);
  621. p->addModel(modelMix1);
  622. p->addModel(modelVCM);
  623. p->addModel(modelMute8);
  624. p->addModel(modelPan);
  625. p->addModel(modelXFade);
  626. p->addModel(modelVCA);
  627. p->addModel(modelVCAmp);
  628. p->addModel(modelVelo);
  629. p->addModel(modelUMix);
  630. p->addModel(modelMumix);
  631. p->addModel(modelMatrix81);
  632. p->addModel(modelMatrix18);
  633. p->addModel(modelMatrix44);
  634. p->addModel(modelMatrix44Cvm);
  635. p->addModel(modelMatrix88);
  636. p->addModel(modelMatrix88Cv);
  637. p->addModel(modelMatrix88M);
  638. p->addModel(modelSwitch81);
  639. p->addModel(modelSwitch18);
  640. p->addModel(modelSwitch44);
  641. p->addModel(modelSwitch88);
  642. p->addModel(modelSwitch1616);
  643. p->addModel(modelAMRM);
  644. p->addModel(modelPressor);
  645. p->addModel(modelClpr);
  646. p->addModel(modelLmtr);
  647. p->addModel(modelNsgt);
  648. p->addModel(modelCmpDist);
  649. p->addModel(modelOneEight);
  650. p->addModel(modelEightOne);
  651. p->addModel(modelAddrSeq);
  652. p->addModel(modelAddrSeqX);
  653. p->addModel(modelPgmr);
  654. p->addModel(modelPgmrX);
  655. p->addModel(modelVU);
  656. p->addModel(modelAnalyzer);
  657. p->addModel(modelAnalyzerXL);
  658. p->addModel(modelRanalyzer);
  659. p->addModel(modelDetune);
  660. p->addModel(modelStack);
  661. p->addModel(modelReftone);
  662. p->addModel(modelMono);
  663. p->addModel(modelArp);
  664. p->addModel(modelAssign);
  665. p->addModel(modelUnison);
  666. p->addModel(modelPolyCon8);
  667. p->addModel(modelPolyCon16);
  668. p->addModel(modelPolyOff8);
  669. p->addModel(modelPolyOff16);
  670. p->addModel(modelPolyMult);
  671. p->addModel(modelBool);
  672. p->addModel(modelCmp);
  673. p->addModel(modelCVD);
  674. p->addModel(modelFlipFlop);
  675. p->addModel(modelInv);
  676. p->addModel(modelManual);
  677. p->addModel(modelFourMan);
  678. p->addModel(modelMult);
  679. p->addModel(modelOffset);
  680. p->addModel(modelSlew);
  681. p->addModel(modelSums);
  682. p->addModel(modelSwitch);
  683. p->addModel(modelLgsw);
  684. p->addModel(modelBlank3);
  685. p->addModel(modelBlank6);
  686. #ifdef EXPERIMENTAL
  687. p->addModel(modelLag);
  688. p->addModel(modelPEQ14XR);
  689. p->addModel(modelPEQ14XV);
  690. #endif
  691. #ifdef TEST
  692. p->addModel(modelTest);
  693. p->addModel(modelTest2);
  694. p->addModel(modelTestExpanderBase);
  695. p->addModel(modelTestExpanderExtension);
  696. p->addModel(modelTestGl);
  697. p->addModel(modelTestVCF);
  698. #endif
  699. #undef modelADSR
  700. #undef modelLFO
  701. #undef modelNoise
  702. #undef modelVCA
  703. #undef modelVCF
  704. #undef modelVCO
  705. }
  706. }
  707. static void initStatic__cf()
  708. {
  709. Plugin* const p = new Plugin;
  710. pluginInstance__cf = p;
  711. const StaticPluginLoader spl(p, "cf");
  712. if (spl.ok())
  713. {
  714. p->addModel(modelMETRO);
  715. p->addModel(modelEACH);
  716. p->addModel(modeltrSEQ);
  717. p->addModel(modelLEDSEQ);
  718. p->addModel(modelL3DS3Q);
  719. p->addModel(modelSLIDERSEQ);
  720. p->addModel(modelPLAYER);
  721. p->addModel(modelPLAY);
  722. p->addModel(modelMONO);
  723. p->addModel(modelSTEREO);
  724. p->addModel(modelSUB);
  725. p->addModel(modelMASTER);
  726. p->addModel(modelVARIABLE);
  727. p->addModel(modelALGEBRA);
  728. p->addModel(modelFUNKTION);
  729. p->addModel(modelCHOKE);
  730. p->addModel(modelFOUR);
  731. p->addModel(modelSTEPS);
  732. p->addModel(modelPEAK);
  733. p->addModel(modelCUTS);
  734. p->addModel(modelBUFFER);
  735. p->addModel(modelDISTO);
  736. p->addModel(modelCUBE);
  737. p->addModel(modelPATCH);
  738. p->addModel(modelLABEL);
  739. p->addModel(modelDAVE);
  740. }
  741. }
  742. static void initStatic__ESeries()
  743. {
  744. Plugin* const p = new Plugin;
  745. pluginInstance__ESeries = p;
  746. const StaticPluginLoader spl(p, "ESeries");
  747. if (spl.ok())
  748. {
  749. p->addModel(modelE340);
  750. }
  751. }
  752. static void initStatic__Fundamental()
  753. {
  754. Plugin* const p = new Plugin;
  755. pluginInstance__Fundamental = p;
  756. const StaticPluginLoader spl(p, "Fundamental");
  757. if (spl.ok())
  758. {
  759. p->addModel(modelVCO);
  760. p->addModel(modelVCO2);
  761. p->addModel(modelVCF);
  762. p->addModel(modelVCA_1);
  763. p->addModel(modelVCA);
  764. p->addModel(modelLFO);
  765. p->addModel(modelLFO2);
  766. p->addModel(modelDelay);
  767. p->addModel(modelADSR);
  768. p->addModel(modelVCMixer);
  769. p->addModel(model_8vert);
  770. p->addModel(modelUnity);
  771. p->addModel(modelMutes);
  772. p->addModel(modelPulses);
  773. p->addModel(modelScope);
  774. p->addModel(modelSEQ3);
  775. p->addModel(modelSequentialSwitch1);
  776. p->addModel(modelSequentialSwitch2);
  777. p->addModel(modelOctave);
  778. p->addModel(modelQuantizer);
  779. p->addModel(modelSplit);
  780. p->addModel(modelMerge);
  781. p->addModel(modelSum);
  782. p->addModel(modelViz);
  783. p->addModel(modelMidSide);
  784. p->addModel(modelNoise);
  785. p->addModel(modelRandom);
  786. }
  787. }
  788. static void initStatic__GrandeModular()
  789. {
  790. Plugin* const p = new Plugin;
  791. pluginInstance__GrandeModular = p;
  792. const StaticPluginLoader spl(p, "GrandeModular");
  793. if (spl.ok())
  794. {
  795. p->addModel(modelClip);
  796. p->addModel(modelMergeSplit4);
  797. p->addModel(modelMicrotonalChords);
  798. p->addModel(modelMicrotonalNotes);
  799. p->addModel(modelNoteMT);
  800. p->addModel(modelPolyMergeResplit);
  801. p->addModel(modelQuant);
  802. p->addModel(modelQuantIntervals);
  803. p->addModel(modelQuantMT);
  804. p->addModel(modelSampleDelays);
  805. p->addModel(modelScale);
  806. p->addModel(modelTails);
  807. p->addModel(modelVarSampleDelays);
  808. }
  809. }
  810. static void initStatic__ImpromptuModular()
  811. {
  812. Plugin* const p = new Plugin;
  813. pluginInstance__ImpromptuModular = p;
  814. const StaticPluginLoader spl(p, "ImpromptuModular");
  815. if (spl.ok())
  816. {
  817. p->addModel(modelBigButtonSeq);
  818. p->addModel(modelBigButtonSeq2);
  819. p->addModel(modelChordKey);
  820. p->addModel(modelChordKeyExpander);
  821. p->addModel(modelClocked);
  822. p->addModel(modelClockedExpander);
  823. p->addModel(modelClkd);
  824. p->addModel(modelCvPad);
  825. p->addModel(modelFoundry);
  826. p->addModel(modelFoundryExpander);
  827. p->addModel(modelFourView);
  828. p->addModel(modelGateSeq64);
  829. p->addModel(modelGateSeq64Expander);
  830. p->addModel(modelHotkey);
  831. p->addModel(modelPart);
  832. p->addModel(modelPhraseSeq16);
  833. p->addModel(modelPhraseSeq32);
  834. p->addModel(modelPhraseSeqExpander);
  835. p->addModel(modelProbKey);
  836. // p->addModel(modelProbKeyExpander);
  837. p->addModel(modelSemiModularSynth);
  838. p->addModel(modelTact);
  839. p->addModel(modelTact1);
  840. p->addModel(modelTactG);
  841. p->addModel(modelTwelveKey);
  842. p->addModel(modelWriteSeq32);
  843. p->addModel(modelWriteSeq64);
  844. p->addModel(modelBlankPanel);
  845. }
  846. }
  847. static void initStatic__JW()
  848. {
  849. Plugin* const p = new Plugin;
  850. pluginInstance__JW = p;
  851. const StaticPluginLoader spl(p, "JW-Modules");
  852. if (spl.ok())
  853. {
  854. #define modelQuantizer modelJWQuantizer
  855. p->addModel(modelAdd5);
  856. p->addModel(modelBouncyBalls);
  857. p->addModel(modelCat);
  858. p->addModel(modelTree);
  859. p->addModel(modelFullScope);
  860. p->addModel(modelGridSeq);
  861. p->addModel(modelEightSeq);
  862. p->addModel(modelDivSeq);
  863. p->addModel(modelMinMax);
  864. p->addModel(modelNoteSeq);
  865. p->addModel(modelNoteSeqFu);
  866. p->addModel(modelNoteSeq16);
  867. p->addModel(modelTrigs);
  868. p->addModel(modelOnePattern);
  869. p->addModel(modelPatterns);
  870. p->addModel(modelQuantizer);
  871. p->addModel(modelSimpleClock);
  872. p->addModel(modelStr1ker);
  873. p->addModel(modelD1v1de);
  874. p->addModel(modelPres1t);
  875. p->addModel(modelThingThing);
  876. p->addModel(modelWavHead);
  877. p->addModel(modelXYPad);
  878. p->addModel(modelBlankPanel1hp);
  879. p->addModel(modelBlankPanelSmall);
  880. p->addModel(modelBlankPanelMedium);
  881. p->addModel(modelBlankPanelLarge);
  882. p->addModel(modelCoolBreeze);
  883. p->addModel(modelPete);
  884. #undef modelQuantizer
  885. }
  886. }
  887. static void initStatic__rackwindows()
  888. {
  889. Plugin* const p = new Plugin;
  890. pluginInstance__rackwindows = p;
  891. const StaticPluginLoader spl(p, "rackwindows");
  892. if (spl.ok())
  893. {
  894. // p->addModel(modelAcceleration);
  895. p->addModel(modelBitshiftgain);
  896. p->addModel(modelCapacitor);
  897. p->addModel(modelCapacitor_stereo);
  898. p->addModel(modelChorus);
  899. p->addModel(modelConsole);
  900. p->addModel(modelConsole_mm);
  901. p->addModel(modelDistance);
  902. p->addModel(modelGolem);
  903. p->addModel(modelHolt);
  904. p->addModel(modelHombre);
  905. p->addModel(modelInterstage);
  906. p->addModel(modelMonitoring);
  907. p->addModel(modelMv);
  908. p->addModel(modelRasp);
  909. p->addModel(modelReseq);
  910. p->addModel(modelTape);
  911. p->addModel(modelTremolo);
  912. p->addModel(modelVibrato);
  913. }
  914. }
  915. /* does not build against v2
  916. static void initStatic__ValleyAudio()
  917. {
  918. Plugin* const p = new Plugin;
  919. pluginInstance__ValleyAudio = p;
  920. const StaticPluginLoader spl(p, "ValleyAudio");
  921. if (spl.ok())
  922. {
  923. p->addModel(modelTopograph);
  924. p->addModel(modelUGraph);
  925. p->addModel(modelDexter);
  926. p->addModel(modelPlateau);
  927. p->addModel(modelInterzone);
  928. p->addModel(modelAmalgam);
  929. p->addModel(modelFeline);
  930. p->addModel(modelTerrorform);
  931. }
  932. }
  933. */
  934. static void initStatic__ZetaCarinaeModules()
  935. {
  936. Plugin* p = new Plugin;
  937. pluginInstance__ZetaCarinaeModules = p;
  938. const StaticPluginLoader spl(p, "ZetaCarinaeModules");
  939. if (spl.ok())
  940. {
  941. p->addModel(modelBrownianBridge);
  942. p->addModel(modelOrnsteinUhlenbeck);
  943. p->addModel(modelIOU);
  944. p->addModel(modelWarbler);
  945. p->addModel(modelRosenchance);
  946. p->addModel(modelGuildensTurn);
  947. p->addModel(modelRosslerRustler);
  948. p->addModel(modelFirefly);
  949. }
  950. }
  951. #endif // NOPLUGINS
  952. void initStaticPlugins()
  953. {
  954. initStatic__Core();
  955. initStatic__Cardinal();
  956. #ifndef NOPLUGINS
  957. initStatic__AmalgamatedHarmonics();
  958. initStatic__AnimatedCircuits();
  959. initStatic__AS();
  960. initStatic__AudibleInstruments();
  961. initStatic__Befaco();
  962. initStatic__Bidoo();
  963. initStatic__BogaudioModules();
  964. initStatic__cf();
  965. initStatic__ESeries();
  966. initStatic__Fundamental();
  967. initStatic__GrandeModular();
  968. initStatic__ImpromptuModular();
  969. initStatic__JW();
  970. initStatic__rackwindows();
  971. /* does not build against v2
  972. initStatic__ValleyAudio();
  973. */
  974. initStatic__ZetaCarinaeModules();
  975. #endif // NOPLUGINS
  976. }
  977. void destroyStaticPlugins()
  978. {
  979. for (Plugin* p : plugins)
  980. delete p;
  981. plugins.clear();
  982. }
  983. }
  984. }