From 421d263013f6e5c392d67ba1c23538a752a82a6e Mon Sep 17 00:00:00 2001 From: Don Cross Date: Mon, 1 Apr 2024 12:40:03 -0400 Subject: [PATCH 01/21] Sapphire v 2.4.3: Moots option to toggle via triggers. Added an option to the Sapphire Moots right-click menu to toggle between using gates or triggers for the control ports. Gate mode causes Moots to work the same way it always did. Trigger mode causes Moots to toggle the state of each controller every time a trigger is received. I'm also now building Sapphire using C++17 instead of C++11. This allows me to use cool stuff like std::clamp and std::make_unique. --- plugins/Sapphire | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/Sapphire b/plugins/Sapphire index 4bf2ad3..d26e157 160000 --- a/plugins/Sapphire +++ b/plugins/Sapphire @@ -1 +1 @@ -Subproject commit 4bf2ad39eeaddcbfcc5cd345aef8c0c4cc722b73 +Subproject commit d26e157140ef6283906a33675733ea35e4dd26ac From c44acc824155cfceface3baddc2101ab78312379 Mon Sep 17 00:00:00 2001 From: falkTX Date: Thu, 4 Apr 2024 09:49:12 +0200 Subject: [PATCH 02/21] Update carla and dpf, bump version to 24.04 Signed-off-by: falkTX --- Makefile | 2 +- carla | 2 +- deps/PawPaw | 2 +- dpf | 2 +- src/CardinalCommon.cpp | 2 +- src/CardinalPlugin.cpp | 2 +- utils/macOS/Info_JACK.plist | 2 +- utils/macOS/Info_Native.plist | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Makefile b/Makefile index 8623ca3..109c4e6 100644 --- a/Makefile +++ b/Makefile @@ -14,7 +14,7 @@ include $(ROOT)/Makefile.base.mk # src/CardinalPlugin.cpp `getVersion` # utils/macOS/Info_{JACK,Native}.plist # src/CardinalCommon.cpp src/CardinalPlugin.cpp utils/macOS/Info_{JACK,Native}.plist -VERSION = 24.03 +VERSION = 24.04 # -------------------------------------------------------------- # Build targets diff --git a/carla b/carla index 66afe24..3c7d0e7 160000 --- a/carla +++ b/carla @@ -1 +1 @@ -Subproject commit 66afe24a08790732cc17d81d4b846a1e0cfa0118 +Subproject commit 3c7d0e7b914d38a32b733cc5ced0b5696d2f9a03 diff --git a/deps/PawPaw b/deps/PawPaw index b84d0ec..0edef21 160000 --- a/deps/PawPaw +++ b/deps/PawPaw @@ -1 +1 @@ -Subproject commit b84d0ec2d1bb5c7d7fd05d4a8d7f4af71306c425 +Subproject commit 0edef2120e7fd493493e66967438c0b2ea8c8552 diff --git a/dpf b/dpf index 045b943..01aca76 160000 --- a/dpf +++ b/dpf @@ -1 +1 @@ -Subproject commit 045b943199393053c606b530fc882661502d53d7 +Subproject commit 01aca7649c1a3a5ee20a47c5ecd3cb2e29395f89 diff --git a/src/CardinalCommon.cpp b/src/CardinalCommon.cpp index ed36098..b616872 100644 --- a/src/CardinalCommon.cpp +++ b/src/CardinalCommon.cpp @@ -99,7 +99,7 @@ void destroyStaticPlugins(); } } -const std::string CARDINAL_VERSION = "24.03"; +const std::string CARDINAL_VERSION = "24.04"; START_NAMESPACE_DISTRHO diff --git a/src/CardinalPlugin.cpp b/src/CardinalPlugin.cpp index f89338b..09d6a1a 100644 --- a/src/CardinalPlugin.cpp +++ b/src/CardinalPlugin.cpp @@ -406,7 +406,7 @@ protected: uint32_t getVersion() const override { - return d_version(0, 24, 3); + return d_version(0, 24, 4); } int64_t getUniqueId() const override diff --git a/utils/macOS/Info_JACK.plist b/utils/macOS/Info_JACK.plist index 9df338c..66bb498 100644 --- a/utils/macOS/Info_JACK.plist +++ b/utils/macOS/Info_JACK.plist @@ -11,7 +11,7 @@ CFBundleIdentifier studio.kx.distrho.cardinal.jack CFBundleShortVersionString - 23.03 + 23.04 LSMinimumSystemVersion 10.15 NSHumanReadableCopyright diff --git a/utils/macOS/Info_Native.plist b/utils/macOS/Info_Native.plist index ed61faf..310766e 100644 --- a/utils/macOS/Info_Native.plist +++ b/utils/macOS/Info_Native.plist @@ -11,7 +11,7 @@ CFBundleIdentifier studio.kx.distrho.cardinal.native CFBundleShortVersionString - 24.03 + 24.04 LSMinimumSystemVersion 10.15 NSHumanReadableCopyright From 64eafbc631a12cc8d84f79ebe49950cf806253ef Mon Sep 17 00:00:00 2001 From: Shiera Kawa <156562233+washikano@users.noreply.github.com> Date: Thu, 4 Apr 2024 02:22:39 -0600 Subject: [PATCH 03/21] Add Computerscare modules (#614) * Attempt to clean up some things * Add Makefile and plugins.cpp * Added modified res and src for Computerscare * Updated README.md and docs/LICENSES.md, fixed Makefile * Updated Makefile * Added PanelBorder to custom names, modified ComputerscareSVGPanel again * Updated Makefile * Modified dep.cpp for Computerscare dark mode * Attempt to prepare ComputerscareBlank for dark mode * [WIP] a janky fix for ComputerscareBlank dark mode, but logo disappeared! * [WIP] eureka * fix ComputerscareBlank for mark dode * Updated LICENSES.md * [WIP] patched modules so labels properly change colors, hopefully everything else still works as intended * adjust PatchSequencer font size * What does this option do? * tweaked colors, text boxes now change color for dark mode * minor upd to Computerscare and dep.cpp * Upd ComputerscareLaundrySoup (hopefully fixes plugin-validation) * Upd LaundrySoup again * Delete ComputerscareIso.cpp from Computerscare * rebase Computerscare to updated master branch * Upd Computerscare * Don't change object names in submodule source, instead define/undef in plugins.cpp * revert Computerscare due to lto build failure --- .gitmodules | 6 +++++- README.md | 1 + docs/LICENSES.md | 4 ++++ plugins/Computerscare | 1 + plugins/Makefile | 15 +++++++++++++++ plugins/plugins.cpp | 33 +++++++++++++++++++++++++++++++++ src/custom/dep.cpp | 33 +++++++++++++++++++++++++++++++++ 7 files changed, 92 insertions(+), 1 deletion(-) create mode 160000 plugins/Computerscare diff --git a/.gitmodules b/.gitmodules index 1c2a632..0f8b9da 100644 --- a/.gitmodules +++ b/.gitmodules @@ -233,6 +233,10 @@ [submodule "plugins/DHE-Modules"] path = plugins/DHE-Modules url = https://github.com/dhemery/DHE-Modules.git +[submodule "plugins/Computerscare"] + path = plugins/Computerscare + url = https://github.com/freddyz/computerscare-vcv-modules.git + branch = v2.0.4 [submodule "plugins/CVfunk"] path = plugins/CVfunk - url = https://github.com/codygeary/CVfunk-Modules.git + url = https://github.com/codygeary/CVfunk-Modules.git \ No newline at end of file diff --git a/README.md b/README.md index 811634c..3692f53 100644 --- a/README.md +++ b/README.md @@ -139,6 +139,7 @@ At the moment the following 3rd-party modules are provided: - [Catro/Modulo](https://github.com/catronomix/catro-modulo) - [cf](https://github.com/cfoulc/cf) - [ChowDSP](https://github.com/jatinchowdhury18/ChowDSP-VCV) +- [Computerscare](https://github.com/freddyz/computerscare-vcv-modules) - [CVfunk](https://github.com/codygeary/CVfunk-Modules) - [dBiz](https://github.com/dBiz/dBiz) - [DHE Modules](https://github.com/dhemery/DHE-Modules) diff --git a/docs/LICENSES.md b/docs/LICENSES.md index 29192c0..ba7ea2a 100644 --- a/docs/LICENSES.md +++ b/docs/LICENSES.md @@ -33,6 +33,7 @@ Bellow follows a list of all code licenses used in Cardinal and linked submodule | Catro/Modulo | BSD-3-Clause | | | cf | BSD-3-Clause | | | ChowDSP | GPL-3.0-or-later | | +| Computerscare | BSD-3-Clause | | | CVfunk | MIT | | | dBiz | GPL-3.0-or-later | | | DHE-Modules | MIT | | @@ -158,6 +159,9 @@ Below is a list of artwork licenses from plugins | cf/VT323-Regular.ttf | OFL-1.1-no-RFN | | | ChowDSP/* | GPL-3.0-or-later | Same license as source code | | ChowDSP/fonts/RobotoCondensed-*.ttf | Apache-2.0 | | +| Computerscare/* | BSD-3-Clause | No artwork specific license provided | +| Computerscare/Oswald-Regular.ttf | OFL-1.1 | | +| Computerscare/Segment7Standard.ttf | OFL-1.1-RFN | | | CVfunk/* | MIT | Same license as source code | | dBiz/* | CC-BY-NC-ND-4.0 | | | dBiz/DejaVuSansMono.ttf | Bitstream-Vera | | diff --git a/plugins/Computerscare b/plugins/Computerscare new file mode 160000 index 0000000..d460bd2 --- /dev/null +++ b/plugins/Computerscare @@ -0,0 +1 @@ +Subproject commit d460bd226ab7b132fc4dfe14c5f359d7bbf007b7 diff --git a/plugins/Makefile b/plugins/Makefile index 78d1611..f8d6116 100644 --- a/plugins/Makefile +++ b/plugins/Makefile @@ -645,6 +645,14 @@ PLUGIN_FILES += $(filter-out cf/src/plugin.cpp,$(wildcard cf/src/*.cpp)) # modules/types which are present in other plugins CF_CUSTOM = $(DRWAV) +# -------------------------------------------------------------- +# Computerscare + +PLUGIN_FILES += $(filter-out Computerscare/src/Computerscare.cpp Computerscare/src/test.cpp,$(wildcard Computerscare/src/*.cpp)) + +# modules/types which are present in other plugins +COMPUTERSCARE_CUSTOM = Quantizer PanelBorder + # -------------------------------------------------------------- # CVfunk @@ -2207,6 +2215,13 @@ $(BUILD_DIR)/cf/src/%.cpp.o: cf/src/%.cpp -DpluginInstance=pluginInstance__cf \ -Wno-misleading-indentation +$(BUILD_DIR)/Computerscare/src/%.cpp.o: Computerscare/src/%.cpp + -@mkdir -p "$(shell dirname $(BUILD_DIR)/$<)" + @echo "Compiling $<" + $(SILENT)$(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@ \ + $(foreach m,$(COMPUTERSCARE_CUSTOM),$(call custom_module_names,$(m),Computerscare)) \ + -DpluginInstance=pluginInstance__Computerscare + $(BUILD_DIR)/CVfunk/src/%.cpp.o: CVfunk/src/%.cpp -@mkdir -p "$(shell dirname $(BUILD_DIR)/$<)" @echo "Compiling $<" diff --git a/plugins/plugins.cpp b/plugins/plugins.cpp index 3ab90db..4c8e50e 100644 --- a/plugins/plugins.cpp +++ b/plugins/plugins.cpp @@ -311,6 +311,9 @@ extern Model* modelTestVCF; #include "ChowDSP/src/plugin.cpp" #undef init +// Computerscare +#include "Computerscare/src/Computerscare.hpp" + // dBiz #define DarkDefaultItem dBizDarkDefaultItem #define OrangeLight dBizOrangeLight @@ -866,6 +869,7 @@ Plugin* pluginInstance__BogaudioModules; Plugin* pluginInstance__CatroModulo; Plugin* pluginInstance__cf; Plugin* pluginInstance__ChowDSP; +Plugin* pluginInstance__Computerscare; Plugin* pluginInstance__CVfunk; Plugin* pluginInstance__dBiz; Plugin* pluginInstance__DHE; @@ -1833,6 +1837,34 @@ static void initStatic__ChowDSP() } } +static void initStatic__Computerscare() +{ + Plugin* const p = new Plugin; + pluginInstance__Computerscare = p; + + const StaticPluginLoader spl(p, "Computerscare"); + if (spl.ok()) + { + p->addModel(modelComputerscarePatchSequencer); + p->addModel(modelComputerscareDebug); + p->addModel(modelComputerscareLaundrySoup); + p->addModel(modelComputerscareILoveCookies); + p->addModel(modelComputerscareOhPeas); + p->addModel(modelComputerscareHorseADoodleDoo); + p->addModel(modelComputerscareKnolyPobs); + p->addModel(modelComputerscareBolyPuttons); + p->addModel(modelComputerscareRolyPouter); + p->addModel(modelComputerscareSolyPequencer); + p->addModel(modelComputerscareTolyPools); + p->addModel(modelComputerscareMolyPatrix); + p->addModel(modelComputerscareGolyPenerator); + p->addModel(modelComputerscareFolyPace); + p->addModel(modelComputerscareStolyFickPigure); + p->addModel(modelComputerscareBlank); + p->addModel(modelComputerscareBlankExpander); + } +} + static void initStatic__CVfunk() { Plugin* const p = new Plugin; @@ -3252,6 +3284,7 @@ void initStaticPlugins() initStatic__CatroModulo(); initStatic__cf(); initStatic__ChowDSP(); + initStatic__Computerscare(); initStatic__CVfunk(); initStatic__dBiz(); initStatic__DHE(); diff --git a/src/custom/dep.cpp b/src/custom/dep.cpp index 6551dfb..293726c 100644 --- a/src/custom/dep.cpp +++ b/src/custom/dep.cpp @@ -62,6 +62,7 @@ enum DarkMode { kModeAudibleInstruments, kModeBidoo, kModeCf, + kModeComputerscare, kModeDHE, kModeDrumKit, kModeESeries, @@ -214,6 +215,29 @@ static const struct { { kModeCf, "/cf/res/SUB.svg", {}, -1 }, { kModeCf, "/cf/res/trSEQ.svg", {}, -1 }, { kModeCf, "/cf/res/VARIABLE.svg", {}, -1 }, + // BSD-3 Clause + { kModeComputerscare, "/Computerscare/res/computerscare-clk-text.svg", {}, -1}, + { kModeComputerscare, "/Computerscare/res/vertical-x-1.svg", {}, -1}, + { kModeComputerscare, "/Computerscare/res/vertical-x-2.svg", {}, -1}, + { kModeComputerscare, "/Computerscare/res/vertical-x-3.svg", {}, -1}, + { kModeComputerscare, "/Computerscare/res/computerscare-logo-normal.svg", {}, -1}, + { kModeComputerscare, "/Computerscare/res/computerscare-logo-sad.svg", {}, -1}, + { kModeComputerscare, "/Computerscare/res/ComputerscareDebugPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareOhPeasPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareFolyPacePanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareKnolyPobsPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareTolyPoolsPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareMolyPatrixPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareRolyPouterPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareBolyPuttonsPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareCustomBlankPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareLaundrySoupPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareILoveCookiesPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareGolyPeneratorPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareSolyPequencerPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscarePatchSequencerPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareHorseADoodleDooPanel.svg", {}, -1 }, + { kModeComputerscare, "/Computerscare/res/ComputerscareCustomBlankExpanderPanel.svg", {}, -1 }, // MIT { kModeDHE, "/DHE-Modules/svg/blossom.svg", {}, -1 }, { kModeDHE, "/DHE-Modules/svg/booster-stage.svg", {}, -1 }, @@ -664,6 +688,15 @@ bool invertPaintForDarkMode(const DarkMode mode, NSVGshape* const shape, NSVGpai } } break; + // Special case for Computerscare + case kModeComputerscare: + switch (paint.color) + { + // Just make vertical-x-* visible + case 0xffa6c924: + return false; + } + break; // Special case for DHE, mark things darker instead of inverting case kModeDHE: paint.color = darkerColor(paint.color); From 3b2a78534f43c007c1667108c5257231f4b3bc61 Mon Sep 17 00:00:00 2001 From: falkTX Date: Thu, 4 Apr 2024 10:45:48 +0200 Subject: [PATCH 04/21] Invert ComputerscareStolyFickPigurePanel.svg for light mode Signed-off-by: falkTX --- plugins/Computerscare | 2 +- src/custom/dep.cpp | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/plugins/Computerscare b/plugins/Computerscare index d460bd2..5baab04 160000 --- a/plugins/Computerscare +++ b/plugins/Computerscare @@ -1 +1 @@ -Subproject commit d460bd226ab7b132fc4dfe14c5f359d7bbf007b7 +Subproject commit 5baab047242088e45c99c9999b6e2d9082981ef1 diff --git a/src/custom/dep.cpp b/src/custom/dep.cpp index 293726c..14a1fc4 100644 --- a/src/custom/dep.cpp +++ b/src/custom/dep.cpp @@ -386,6 +386,7 @@ enum LightMode { kModeAutinn, kModeBefaco, kModeCardinal, + kModeComputerscareLight, kModeExtratone, kModeFehlerFabrik, kModeForsitan, @@ -474,6 +475,8 @@ static const struct { { kModeCardinal, "/Cardinal/res/HostParamsMap.svg" }, { kModeCardinal, "/Cardinal/res/HostTime.svg" }, { kModeCardinal, "/Cardinal/res/Ildaeil.svg" }, + // BSD-3 Clause + { kModeComputerscareLight, "/Computerscare/res/ComputerscareStolyFickPigurePanel.svg" }, // GPLv3+ { kModeExtratone, "/Extratone/res/Darwinism.svg" }, // { kModeExtratone, "/Extratone/res/HalluciMemory.svg" }, From b44f993f9146524daee635e6e5e61ffa877273e2 Mon Sep 17 00:00:00 2001 From: falkTX Date: Thu, 4 Apr 2024 11:39:32 +0200 Subject: [PATCH 05/21] Force-redraw of all child widgets on dark mode change Signed-off-by: falkTX --- src/override/MenuBar.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/override/MenuBar.cpp b/src/override/MenuBar.cpp index e68abf8..7a13f17 100644 --- a/src/override/MenuBar.cpp +++ b/src/override/MenuBar.cpp @@ -605,10 +605,8 @@ static void setAllFramebufferWidgetsDirty(widget::Widget* const widget) for (widget::Widget* child : widget->children) { if (widget::FramebufferWidget* const fbw = dynamic_cast(child)) - { fbw->setDirty(); - break; - } + setAllFramebufferWidgetsDirty(child); } } From 106c6dd3d936e03741d9be2416494eaf8b8e12e8 Mon Sep 17 00:00:00 2001 From: jn64 <23169302+jn64@users.noreply.github.com> Date: Thu, 4 Apr 2024 21:29:36 +0800 Subject: [PATCH 06/21] Add issue templates (#551) * Create bug.yaml * Create feature.yaml * Create config.yml * Add DAW/host field Also change version from placeholder to value so it is pre-filled * Change OS field from dropdown to input --- .github/ISSUE_TEMPLATE/bug.yaml | 42 +++++++++++++++++++++++++++++ .github/ISSUE_TEMPLATE/config.yml | 8 ++++++ .github/ISSUE_TEMPLATE/feature.yaml | 9 +++++++ 3 files changed, 59 insertions(+) create mode 100644 .github/ISSUE_TEMPLATE/bug.yaml create mode 100644 .github/ISSUE_TEMPLATE/config.yml create mode 100644 .github/ISSUE_TEMPLATE/feature.yaml diff --git a/.github/ISSUE_TEMPLATE/bug.yaml b/.github/ISSUE_TEMPLATE/bug.yaml new file mode 100644 index 0000000..e010766 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug.yaml @@ -0,0 +1,42 @@ +name: Bug Report +description: Report a bug with Cardinal +body: + - type: input + id: version + attributes: + label: Version + value: "23.10" + validations: + required: true + - type: dropdown + id: plugin-type + attributes: + label: Plugin type + multiple: true + options: + - Native + - AU + - CLAP + - LV2 + - VST2 + - VST3 + validations: + required: true + - type: input + id: os + attributes: + label: OS + validations: + required: true + - type: input + id: daw-host + attributes: + label: "DAW / host" + validations: + required: false + - type: textarea + id: bug-description + attributes: + label: Description + validations: + required: true diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 0000000..62ee212 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1,8 @@ +blank_issues_enabled: false +contact_links: + - name: Module request + url: https://github.com/DISTRHO/Cardinal/wiki/Possible-modules-to-include + about: To request a new module, add it to the wiki page here + - name: Discussions + url: https://github.com/DISTRHO/Cardinal/discussions + about: Ask other questions or share what you've made with Cardinal diff --git a/.github/ISSUE_TEMPLATE/feature.yaml b/.github/ISSUE_TEMPLATE/feature.yaml new file mode 100644 index 0000000..475c88b --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature.yaml @@ -0,0 +1,9 @@ +name: Feature request +description: Request a new feature +body: + - type: textarea + id: feature-description + attributes: + label: Description + validations: + required: true From 0f405dd45b8c8423c1a0f4bbc67bcfe85f664fdd Mon Sep 17 00:00:00 2001 From: Filipe Coelho Date: Thu, 4 Apr 2024 17:16:50 +0200 Subject: [PATCH 07/21] Add Starling Via (#636) * adding Starling Via * update StarlingVia with async file dialogs; adjust plugins/Makefile * include plugin binaries * custom defines for StarlingVia * extern StarlingVia * update starlingvia * use newer StarlingVia commit * Fix memory issues in StarlingVia Signed-off-by: falkTX --------- Signed-off-by: falkTX Co-authored-by: dreamer Co-authored-by: dreamer <1185977+dromer@users.noreply.github.com> --- .gitmodules | 6 ++++-- README.md | 1 + docs/LICENSES.md | 2 ++ plugins/Makefile | 33 ++++++++++++++++++++++++++++++++- plugins/StarlingVia | 1 + plugins/plugins.cpp | 39 +++++++++++++++++++++++++++++++++++++++ 6 files changed, 79 insertions(+), 3 deletions(-) create mode 160000 plugins/StarlingVia diff --git a/.gitmodules b/.gitmodules index 0f8b9da..0c38e5e 100644 --- a/.gitmodules +++ b/.gitmodules @@ -236,7 +236,9 @@ [submodule "plugins/Computerscare"] path = plugins/Computerscare url = https://github.com/freddyz/computerscare-vcv-modules.git - branch = v2.0.4 [submodule "plugins/CVfunk"] path = plugins/CVfunk - url = https://github.com/codygeary/CVfunk-Modules.git \ No newline at end of file + url = https://github.com/codygeary/CVfunk-Modules.git +[submodule "plugins/StarlingVia"] + path = plugins/StarlingVia + url = https://github.com/starlingcode/Via-for-Rack.git diff --git a/README.md b/README.md index 3692f53..1cef9ea 100644 --- a/README.md +++ b/README.md @@ -186,6 +186,7 @@ At the moment the following 3rd-party modules are provided: - [Sapphire](https://github.com/cosinekitty/sapphire) - [Sonus Modular](https://gitlab.com/sonusdept/sonusmodular) - [stocaudio](https://github.com/aptrn/stocaudio-modules) +- [Starling Via](https://github.com/starlingcode/Via-for-Rack) - [Stoermelder Pack-One](https://github.com/stoermelder/vcvrack-packone) - [Surge XT](https://github.com/surge-synthesizer/surge-rack) - [unless_modules](https://gitlab.com/unlessgames/unless_modules) diff --git a/docs/LICENSES.md b/docs/LICENSES.md index ba7ea2a..16406f2 100644 --- a/docs/LICENSES.md +++ b/docs/LICENSES.md @@ -79,6 +79,7 @@ Bellow follows a list of all code licenses used in Cardinal and linked submodule | RebelTech | GPL-2.0-or-later | | | Sapphire | GPL-3.0-or-later | | | Sonus Modular | GPL-3.0-or-later | | +| Starling Via | MIT | | | stocaudio | GPL-3.0-or-later | | | Stoermelder Pack-One | GPL-3.0-or-later | | | Surge XT | GPL-3.0-or-later | | @@ -235,6 +236,7 @@ Below is a list of artwork licenses from plugins | RebelTech/* | CC-BY-NC-4.0 | | | Sapphire/* | GPL-3.0-or-later | No artwork specific license provided | | sonusmodular/* | GPL-3.0-or-later | [Same license as source code](https://gitlab.com/sonusdept/sonusmodular/-/issues/14) | +| StarlingVia/* | MIT | No artwork specific license provided | | stocaudio/* | GPL-3.0-or-later | No artwork specific license provided | | stoermelder-packone/* | GPL-3.0-or-later | No artwork specific license provided | | stoermelder-packone/fonts/RedkostComic.otf | OFL-1.1-RFN | | diff --git a/plugins/Makefile b/plugins/Makefile index f8d6116..40cb2cd 100644 --- a/plugins/Makefile +++ b/plugins/Makefile @@ -1012,8 +1012,24 @@ PLUGIN_FILES += $(filter-out Sapphire/src/plugin.cpp,$(wildcard Sapphire/src/*.c PLUGIN_FILES += $(filter-out sonusmodular/src/sonusmodular.cpp,$(wildcard sonusmodular/src/*.cpp)) # -------------------------------------------------------------- -# stocaudio +# Starling Via +PLUGIN_FILES += $(wildcard StarlingVia/src/*.cpp) +PLUGIN_FILES += $(wildcard StarlingVia/Via/io/src/*.cpp) +PLUGIN_FILES += $(wildcard StarlingVia/Via/ui/src/*.cpp) +PLUGIN_FILES += $(wildcard StarlingVia/Via/modules/*/*.cpp) +PLUGIN_BINARIES += StarlingVia/res/original.gateseq +PLUGIN_BINARIES += StarlingVia/res/original.meta +PLUGIN_BINARIES += StarlingVia/res/original.osc3 +PLUGIN_BINARIES += StarlingVia/res/original.scanner +PLUGIN_BINARIES += StarlingVia/res/original.sync +PLUGIN_BINARIES += StarlingVia/res/original.sync3 + +# modules/types which are present in other plugins +STARLINGVIA_CUSTOM = Scanner Scale Wavetable + +# -------------------------------------------------------------- +# stocaudio PLUGIN_FILES += $(filter-out stocaudio/src/plugin.cpp,$(wildcard stocaudio/src/*.cpp)) # -------------------------------------------------------------- @@ -2645,6 +2661,21 @@ $(BUILD_DIR)/sonusmodular/%.cpp.o: sonusmodular/%.cpp $(foreach m,$(SONUSMODULAR_CUSTOM),$(call custom_module_names,$(m),sonusmodular)) \ -DpluginInstance=pluginInstance__sonusmodular +$(BUILD_DIR)/StarlingVia/%.cpp.o: StarlingVia/%.cpp + -@mkdir -p "$(shell dirname $(BUILD_DIR)/$<)" + @echo "Compiling $<" + $(SILENT)$(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@ \ + $(foreach m,$(STARLINGVIA_CUSTOM),$(call custom_module_names,$(m),StarlingVia)) \ + -DpluginInstance=pluginInstance__StarlingVia \ + -DBUILD_VIRTUAL \ + -IStarlingVia/dep/starling-dsp \ + -IStarlingVia/Via/modules/inc \ + -IStarlingVia/Via/synthesis/inc \ + -IStarlingVia/Via/io/inc \ + -IStarlingVia/Via/ui/inc \ + -IStarlingVia/src/dep/starling-dsp \ + -IStarlingVia/src/dep/starling-rack-ui + $(BUILD_DIR)/stoermelder-packone/%.cpp.o: stoermelder-packone/%.cpp -@mkdir -p "$(shell dirname $(BUILD_DIR)/$<)" @echo "Compiling $<" diff --git a/plugins/StarlingVia b/plugins/StarlingVia new file mode 160000 index 0000000..a6b75fd --- /dev/null +++ b/plugins/StarlingVia @@ -0,0 +1 @@ +Subproject commit a6b75fddc2df624ba64dab70c2e35b8e48ad8c1d diff --git a/plugins/plugins.cpp b/plugins/plugins.cpp index 4c8e50e..60e1307 100644 --- a/plugins/plugins.cpp +++ b/plugins/plugins.cpp @@ -782,6 +782,16 @@ void addThemeMenuItems(Menu*, ModuleTheme*) {} // sonusmodular #include "sonusmodular/src/sonusmodular.hpp" + +// Starling Via +#define modelScanner modelStarlingViaScanner +#define Scale starlingViaScale +#define Wavetable starlingViaWavetable +#include "StarlingVia/src/starling.hpp" +#undef modelScanner +#undef Scale +#undef Wavetable + // stocaudio #include "stocaudio/src/plugin.hpp" @@ -914,6 +924,7 @@ Plugin* pluginInstance__RebelTech; Plugin* pluginInstance__repelzen; Plugin* pluginInstance__sapphire; Plugin* pluginInstance__sonusmodular; +extern Plugin* pluginInstance__StarlingVia; Plugin* pluginInstance__stocaudio; extern Plugin* pluginInstance__stoermelder_p1; Plugin* pluginInstance__surgext; @@ -2987,6 +2998,33 @@ static void initStatic__sonusmodular() } } + +static void initStatic__StarlingVia() +{ + Plugin* const p = new Plugin; + pluginInstance__StarlingVia = p; + + const StaticPluginLoader spl(p, "StarlingVia"); + if (spl.ok()) + { +#define modelScanner modelStarlingViaScanner +#define Scale starlingViaScale +#define Wavetable starlingViaWavetable + p->addModel(modelMeta); + p->addModel(modelGateseq); + p->addModel(modelScanner); + p->addModel(modelSync); + p->addModel(modelAtsr); + p->addModel(modelOsc3); + p->addModel(modelSync3); + p->addModel(modelSync3XL); + p->addModel(modelSync3XLLevels); +#undef modelScanner +#undef Scale +#undef Wavetable + } +} + static void initStatic__stocaudio() { Plugin* const p = new Plugin; @@ -3329,6 +3367,7 @@ void initStaticPlugins() initStatic__repelzen(); initStatic__Sapphire(); initStatic__sonusmodular(); + initStatic__StarlingVia(); initStatic__stocaudio(); initStatic__stoermelder_p1(); initStatic__surgext(); From 6414fd36c48d897a54cf21896b4ba693be6f8fe6 Mon Sep 17 00:00:00 2001 From: falkTX Date: Thu, 4 Apr 2024 17:30:01 +0200 Subject: [PATCH 08/21] Cleanup, tweak issue template Signed-off-by: falkTX --- .github/ISSUE_TEMPLATE/bug.yaml | 6 +++--- Makefile | 3 ++- plugins/Makefile | 1 + plugins/plugins.cpp | 4 ---- 4 files changed, 6 insertions(+), 8 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/bug.yaml b/.github/ISSUE_TEMPLATE/bug.yaml index e010766..21d67a5 100644 --- a/.github/ISSUE_TEMPLATE/bug.yaml +++ b/.github/ISSUE_TEMPLATE/bug.yaml @@ -5,7 +5,7 @@ body: id: version attributes: label: Version - value: "23.10" + value: "24.04" validations: required: true - type: dropdown @@ -14,7 +14,7 @@ body: label: Plugin type multiple: true options: - - Native + - Native / JACK - AU - CLAP - LV2 @@ -31,7 +31,7 @@ body: - type: input id: daw-host attributes: - label: "DAW / host" + label: "DAW / Host (if applicable)" validations: required: false - type: textarea diff --git a/Makefile b/Makefile index 109c4e6..c9f010f 100644 --- a/Makefile +++ b/Makefile @@ -10,10 +10,11 @@ include $(ROOT)/Makefile.base.mk # Set version # also set in: +# .github/ISSUE_TEMPLATE/bug.yaml # src/CardinalCommon.cpp `CARDINAL_VERSION` # src/CardinalPlugin.cpp `getVersion` # utils/macOS/Info_{JACK,Native}.plist -# src/CardinalCommon.cpp src/CardinalPlugin.cpp utils/macOS/Info_{JACK,Native}.plist +# .github/ISSUE_TEMPLATE/bug.yaml src/CardinalCommon.cpp src/CardinalPlugin.cpp utils/macOS/Info_{JACK,Native}.plist VERSION = 24.04 # -------------------------------------------------------------- diff --git a/plugins/Makefile b/plugins/Makefile index 40cb2cd..ac9d0fb 100644 --- a/plugins/Makefile +++ b/plugins/Makefile @@ -1030,6 +1030,7 @@ STARLINGVIA_CUSTOM = Scanner Scale Wavetable # -------------------------------------------------------------- # stocaudio + PLUGIN_FILES += $(filter-out stocaudio/src/plugin.cpp,$(wildcard stocaudio/src/*.cpp)) # -------------------------------------------------------------- diff --git a/plugins/plugins.cpp b/plugins/plugins.cpp index 60e1307..eb86948 100644 --- a/plugins/plugins.cpp +++ b/plugins/plugins.cpp @@ -3008,8 +3008,6 @@ static void initStatic__StarlingVia() if (spl.ok()) { #define modelScanner modelStarlingViaScanner -#define Scale starlingViaScale -#define Wavetable starlingViaWavetable p->addModel(modelMeta); p->addModel(modelGateseq); p->addModel(modelScanner); @@ -3020,8 +3018,6 @@ static void initStatic__StarlingVia() p->addModel(modelSync3XL); p->addModel(modelSync3XLLevels); #undef modelScanner -#undef Scale -#undef Wavetable } } From 8239f3957afb0f37876be52960f407ff60faac2a Mon Sep 17 00:00:00 2001 From: falkTX Date: Thu, 4 Apr 2024 21:12:42 +0200 Subject: [PATCH 09/21] Fix DHE-Modules and MindMeldModular for wasm Signed-off-by: falkTX --- plugins/Makefile | 2 +- plugins/MindMeldModular | 2 +- src/Makefile.cardinal.mk | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/plugins/Makefile b/plugins/Makefile index ac9d0fb..42e9436 100644 --- a/plugins/Makefile +++ b/plugins/Makefile @@ -1427,11 +1427,11 @@ RESOURCE_FILES += Befaco/res/SpringReverbIR.f32 RESOURCE_FILES += cf/playeroscs RESOURCE_FILES += DHE-Modules/svg RESOURCE_FILES += DrumKit/res/samples +RESOURCE_FILES += Meander/res RESOURCE_FILES += MindMeldModular/res/ShapeMaster/CommunityPresets RESOURCE_FILES += MindMeldModular/res/ShapeMaster/CommunityShapes RESOURCE_FILES += MindMeldModular/res/ShapeMaster/MindMeldPresets RESOURCE_FILES += MindMeldModular/res/ShapeMaster/MindMeldShapes -RESOURCE_FILES += Meander/res RESOURCE_FILES += Mog/res RESOURCE_FILES += nonlinearcircuits/res RESOURCE_FILES += ParableInstruments/res/Neil.png diff --git a/plugins/MindMeldModular b/plugins/MindMeldModular index 18f4fa8..8136f0c 160000 --- a/plugins/MindMeldModular +++ b/plugins/MindMeldModular @@ -1 +1 @@ -Subproject commit 18f4fa89ca08e9943e38548440d3e02e1ee2e170 +Subproject commit 8136f0c941b41c57af70a5ebb5839f0086518b2b diff --git a/src/Makefile.cardinal.mk b/src/Makefile.cardinal.mk index ad893bd..fd4c058 100644 --- a/src/Makefile.cardinal.mk +++ b/src/Makefile.cardinal.mk @@ -316,6 +316,7 @@ SYMLINKED_DIRS_RESOURCES += BaconPlugs/res/midi/chopin SYMLINKED_DIRS_RESOURCES += BaconPlugs/res/midi/debussy SYMLINKED_DIRS_RESOURCES += BaconPlugs/res/midi/goldberg SYMLINKED_DIRS_RESOURCES += cf/playeroscs +SYMLINKED_DIRS_RESOURCES += DHE-Modules/svg SYMLINKED_DIRS_RESOURCES += DrumKit/res/samples SYMLINKED_DIRS_RESOURCES += GrandeModular/presets SYMLINKED_DIRS_RESOURCES += LyraeModules/presets From 6e907131b293434aace20ce7f4f6aacab60d93f1 Mon Sep 17 00:00:00 2001 From: dreamer Date: Fri, 5 Apr 2024 08:39:28 +0200 Subject: [PATCH 10/21] use dBiz with fix --- plugins/dBiz | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/dBiz b/plugins/dBiz index 88f1bd6..d6933ab 160000 --- a/plugins/dBiz +++ b/plugins/dBiz @@ -1 +1 @@ -Subproject commit 88f1bd64cff6e96a1a48566a1692de86b9a7de2a +Subproject commit d6933abe016eeb97c9fb0b0f955af756401403c1 From aeb2f195748b3188093e763c84345de13d2861ac Mon Sep 17 00:00:00 2001 From: CV funk Date: Mon, 15 Apr 2024 10:32:29 +0200 Subject: [PATCH 11/21] Update CV funk to 2.0.3 Added Ouros stereo phase injection oscillator Numerous small buxfixes to other modules --- plugins/CVfunk | 2 +- plugins/plugins.cpp | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/plugins/CVfunk b/plugins/CVfunk index 9829130..9b36e61 160000 --- a/plugins/CVfunk +++ b/plugins/CVfunk @@ -1 +1 @@ -Subproject commit 9829130ab972ff4a0c0b1467580bf04b9efcd7b2 +Subproject commit 9b36e612109fef8eee8edfe25d6868e47d13b6f2 diff --git a/plugins/plugins.cpp b/plugins/plugins.cpp index eb86948..4913ab6 100644 --- a/plugins/plugins.cpp +++ b/plugins/plugins.cpp @@ -1895,6 +1895,7 @@ static void initStatic__CVfunk() p->addModel(modelCollatz); p->addModel(modelStrings); p->addModel(modelMagnets); + p->addModel(modelOuros); #undef modelSteps } } From c80143148158eac412ef4cad452f3bdf915c9993 Mon Sep 17 00:00:00 2001 From: washikano Date: Sun, 7 Apr 2024 10:00:50 -0600 Subject: [PATCH 12/21] preliminary work to add Biset --- .gitmodules | 3 +++ docs/LICENSES.md | 4 ++++ plugins/Biset | 1 + plugins/Makefile | 13 +++++++++++++ plugins/plugins.cpp | 45 +++++++++++++++++++++++++++++++++++++++++++++ 5 files changed, 66 insertions(+) create mode 160000 plugins/Biset diff --git a/.gitmodules b/.gitmodules index 0c38e5e..33b61a8 100644 --- a/.gitmodules +++ b/.gitmodules @@ -242,3 +242,6 @@ [submodule "plugins/StarlingVia"] path = plugins/StarlingVia url = https://github.com/starlingcode/Via-for-Rack.git +[submodule "plugins/Biset"] + path = plugins/Biset + url = https://github.com/gibbonjoyeux/VCV-Biset.git diff --git a/docs/LICENSES.md b/docs/LICENSES.md index 16406f2..33e875f 100644 --- a/docs/LICENSES.md +++ b/docs/LICENSES.md @@ -29,6 +29,7 @@ Bellow follows a list of all code licenses used in Cardinal and linked submodule | Bacon Music | GPL-3.0-or-later | | | Befaco | GPL-3.0-or-later | | | Bidoo | GPL-3.0-or-later | | +| Biset | MIT | | | Bogaudio | GPL-3.0-or-later | | | Catro/Modulo | BSD-3-Clause | | | cf | BSD-3-Clause | | @@ -147,6 +148,9 @@ Below is a list of artwork licenses from plugins | Befaco/components/* | CC-BY-NC-4.0 | | | Befaco/fonts/Segment7Standard.otf | OFL-1.1-RFN | | | Befaco/panels/* | Custom | Copyright © [Befaco](https://www.befaco.org/), [used and distributed with permission](LICENSE-PERMISSIONS.md#befaco-manu-retamero--befaco) | +| Biset/* | MIT | No artwork specific license provided | +| Biset/FT88-Regular.ttf | OFL | | +| Biset/Recursive_VF_1.085.ttf | OFL-1.1-no-RFN | | | BogaudioModules/* | CC-BY-SA-4.0 | | | BogaudioModules/fonts/audiowide.ttf | OFL-1.1-RFN | | | BogaudioModules/fonts/inconsolata*.ttf | OFL-1.1-no-RFN | | diff --git a/plugins/Biset b/plugins/Biset new file mode 160000 index 0000000..a3acddc --- /dev/null +++ b/plugins/Biset @@ -0,0 +1 @@ +Subproject commit a3acddc30732700b91f27075488b914c38b9dcdf diff --git a/plugins/Makefile b/plugins/Makefile index 42e9436..b918334 100644 --- a/plugins/Makefile +++ b/plugins/Makefile @@ -572,6 +572,12 @@ PLUGIN_FILES += BidooDark/plugin.cpp BIDOO_CUSTOM = ChannelDisplay InstantiateExpanderItem LadderFilter PitchShifter $(DRWAV) BIDOO_CUSTOM_PER_FILE = channel channel filterType +# -------------------------------------------------------------- +# Biset + +PLUGIN_FILES += $(filter-out Biset/src/plugin.cpp,$(wildcard Biset/src/*.cpp)) +PLUGIN_FILES += $(wildcard Biset/src/*/*.cpp) + # -------------------------------------------------------------- # BogaudioModules @@ -2193,6 +2199,13 @@ $(BUILD_DIR)/Bidoo%.cpp.o: Bidoo%.cpp -Wno-sign-compare \ -Wno-unused-function +$(BUILD_DIR)/Biset/src/%.cpp.o: Biset/src/%.cpp + -@mkdir -p "$(shell dirname $(BUILD_DIR)/$<)" + @echo "Compiling $<" + $(SILENT)$(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@ \ + $(foreach m,$(BISET_CUSTOM),$(call custom_module_names,$(m),Biset)) \ + -DpluginInstance=pluginInstance__Biset + $(BUILD_DIR)/BogaudioModules/src/follower_base.cpp.o: BogaudioModules/src/follower_base.cpp -@mkdir -p "$(shell dirname $(BUILD_DIR)/$<)" @echo "Compiling $<" diff --git a/plugins/plugins.cpp b/plugins/plugins.cpp index 4913ab6..6e19beb 100644 --- a/plugins/plugins.cpp +++ b/plugins/plugins.cpp @@ -146,6 +146,13 @@ extern Model* modelChord; // Bidoo #include "Bidoo/src/plugin.hpp" +// Biset +#define Clock BisetClock +#define ButtonTrigger BisetButtonTrigger +#include "Biset/src/plugin.hpp" +#undef ButtonTrigger +#undef Clock + // BogaudioModules - integrate theme/skin support #include #include @@ -875,6 +882,7 @@ Plugin* pluginInstance__Axioma; Plugin* pluginInstance__Bacon; Plugin* pluginInstance__Befaco; Plugin* pluginInstance__Bidoo; +Plugin* pluginInstance__Biset; Plugin* pluginInstance__BogaudioModules; Plugin* pluginInstance__CatroModulo; Plugin* pluginInstance__cf; @@ -1613,6 +1621,42 @@ static void initStatic__Bidoo() } } +static void initStatic__Biset() +{ + Plugin* const p = new Plugin; + pluginInstance__Biset = p; + + const StaticPluginLoader spl(p, "Biset"); + if (spl.ok()) + { + p->addModel(modelTracker); + p->addModel(modelTrackerSynth); + p->addModel(modelTrackerDrum); + p->addModel(modelTrackerClock); + p->addModel(modelTrackerPhase); + p->addModel(modelTrackerQuant); + p->addModel(modelTrackerState); + p->addModel(modelTrackerControl); + + p->addModel(modelRegex); + p->addModel(modelRegexCondensed); + p->addModel(modelRegexExp); + + p->addModel(modelTree); + p->addModel(modelTreeSeed); + + p->addModel(modelGbu); + p->addModel(modelPkm); + + p->addModel(modelIgc); + p->addModel(modelOmega3); + p->addModel(modelOmega6); + + p->addModel(modelSegfault); + p->addModel(modelBlank); + } +} + static void initStatic__BogaudioModules() { Plugin* const p = new Plugin; @@ -3315,6 +3359,7 @@ void initStaticPlugins() initStatic__Bacon(); initStatic__Befaco(); initStatic__Bidoo(); + initStatic__Biset(); initStatic__BogaudioModules(); initStatic__CatroModulo(); initStatic__cf(); From 872e4d443441d308a15381e00708867db8b32ba4 Mon Sep 17 00:00:00 2001 From: washikano Date: Wed, 10 Apr 2024 00:03:59 -0600 Subject: [PATCH 13/21] Modified Biset Tree --- plugins/Biset | 2 +- plugins/plugins.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/plugins/Biset b/plugins/Biset index a3acddc..7a24e65 160000 --- a/plugins/Biset +++ b/plugins/Biset @@ -1 +1 @@ -Subproject commit a3acddc30732700b91f27075488b914c38b9dcdf +Subproject commit 7a24e65d338053369318cb5211cc4ebe8b19aa4c diff --git a/plugins/plugins.cpp b/plugins/plugins.cpp index 6e19beb..f9bad02 100644 --- a/plugins/plugins.cpp +++ b/plugins/plugins.cpp @@ -1642,8 +1642,8 @@ static void initStatic__Biset() p->addModel(modelRegexCondensed); p->addModel(modelRegexExp); - p->addModel(modelTree); - p->addModel(modelTreeSeed); + p->addModel(modelBisetTree); + p->addModel(modelBisetTreeSeed); p->addModel(modelGbu); p->addModel(modelPkm); From b75676a5bbba7a0b8cbf73565cef82e6326433f5 Mon Sep 17 00:00:00 2001 From: washikano Date: Wed, 10 Apr 2024 00:08:14 -0600 Subject: [PATCH 14/21] Temporary comment out lines related to MIDI devices for Tracker --- plugins/Biset | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/Biset b/plugins/Biset index 7a24e65..43dc87d 160000 --- a/plugins/Biset +++ b/plugins/Biset @@ -1 +1 @@ -Subproject commit 7a24e65d338053369318cb5211cc4ebe8b19aa4c +Subproject commit 43dc87d98e0da2e99b1f03f7f0c4b7e5bccab01d From 8e17cf4ece176bc3a7fb91bca31b6ec7ffc2fa29 Mon Sep 17 00:00:00 2001 From: washikano Date: Wed, 10 Apr 2024 00:36:01 -0600 Subject: [PATCH 15/21] Upd Makefile, added Blank to BISET_CUSTOM --- plugins/Makefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugins/Makefile b/plugins/Makefile index b918334..d64f6e6 100644 --- a/plugins/Makefile +++ b/plugins/Makefile @@ -578,6 +578,9 @@ BIDOO_CUSTOM_PER_FILE = channel channel filterType PLUGIN_FILES += $(filter-out Biset/src/plugin.cpp,$(wildcard Biset/src/*.cpp)) PLUGIN_FILES += $(wildcard Biset/src/*/*.cpp) +# # modules/types which are present in other plugins +BISET_CUSTOM = Blank + # -------------------------------------------------------------- # BogaudioModules From 7948f66eb4261c7bfeb7fdd7f6922a3a0c811c3f Mon Sep 17 00:00:00 2001 From: falkTX Date: Thu, 11 Apr 2024 10:34:10 +0200 Subject: [PATCH 16/21] Continue biset changes, plugin-accessible cardinal context Signed-off-by: falkTX --- include/midi.hpp | 14 ++- plugins/Biset | 2 +- plugins/Cardinal/src/AIDA-X.cpp | 10 +- plugins/Cardinal/src/AudioFile.cpp | 8 +- plugins/Cardinal/src/AudioToCVPitch.cpp | 6 +- plugins/Cardinal/src/Carla.cpp | 7 +- plugins/Cardinal/src/HostAudio.cpp | 4 +- plugins/Cardinal/src/HostCV.cpp | 4 +- plugins/Cardinal/src/HostMIDI-CC.cpp | 4 +- plugins/Cardinal/src/HostMIDI-Gate.cpp | 4 +- plugins/Cardinal/src/HostMIDI-Map.cpp | 4 +- plugins/Cardinal/src/HostMIDI.cpp | 4 +- plugins/Cardinal/src/HostParameters-Map.cpp | 4 +- plugins/Cardinal/src/HostParameters.cpp | 4 +- plugins/Cardinal/src/HostTime.cpp | 4 +- plugins/Cardinal/src/Ildaeil.cpp | 10 +- plugins/Cardinal/src/MPV.cpp | 5 +- plugins/Cardinal/src/SassyScope.cpp | 4 +- plugins/Cardinal/src/TextEditor.cpp | 6 +- plugins/Cardinal/src/plugin.hpp | 9 +- plugins/Cardinal/src/plugincontext.hpp | 89 -------------- plugins/Makefile | 5 +- plugins/plugins.cpp | 46 ++++--- src/CardinalCommon.cpp | 127 +++++++++++++++++++- src/CardinalCommon.hpp | 3 +- src/PluginContext.hpp | 95 +-------------- 26 files changed, 223 insertions(+), 259 deletions(-) delete mode 100644 plugins/Cardinal/src/plugincontext.hpp diff --git a/include/midi.hpp b/include/midi.hpp index 1a6425a..20f2cb1 100644 --- a/include/midi.hpp +++ b/include/midi.hpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -111,6 +111,18 @@ struct Message { }; +struct InputQueue { + struct Internal; + Internal* internal; + + InputQueue(); + ~InputQueue(); + bool tryPop(Message* const messageOut, int64_t maxFrame); + json_t* toJson() const; + void fromJson(json_t* rootJ); +}; + + /* NOTE all the other MIDI stuff (drivers, ports etc) is purposefully missing here, unwanted in Cardinal */ struct Port; diff --git a/plugins/Biset b/plugins/Biset index 43dc87d..a3acddc 160000 --- a/plugins/Biset +++ b/plugins/Biset @@ -1 +1 @@ -Subproject commit 43dc87d98e0da2e99b1f03f7f0c4b7e5bccab01d +Subproject commit a3acddc30732700b91f27075488b914c38b9dcdf diff --git a/plugins/Cardinal/src/AIDA-X.cpp b/plugins/Cardinal/src/AIDA-X.cpp index 5ec02cf..1c9f889 100644 --- a/plugins/Cardinal/src/AIDA-X.cpp +++ b/plugins/Cardinal/src/AIDA-X.cpp @@ -1,11 +1,11 @@ /* * AIDA-X Cardinal plugin * Copyright (C) 2022-2023 Massimo Pennazio - * Copyright (C) 2023 Filipe Coelho + * Copyright (C) 2023-2024 Filipe Coelho * SPDX-License-Identifier: GPL-3.0-or-later */ -#include "plugincontext.hpp" +#include "plugin.hpp" #include "ModuleWidgets.hpp" #ifndef HEADLESS @@ -250,7 +250,6 @@ struct AidaPluginModule : Module { NUM_LIGHTS }; - CardinalPluginContext* const pcontext; bool fileChanged = false; std::string currentFile; @@ -272,7 +271,6 @@ struct AidaPluginModule : Module { #endif AidaPluginModule() - : pcontext(static_cast(APP)) { config(NUM_PARAMS, NUM_INPUTS, NUM_OUTPUTS, NUM_LIGHTS); @@ -656,8 +654,6 @@ struct AidaPluginModule : Module { cachedParams[kParameterPRESENCE]); } #endif - - DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(AidaPluginModule) }; // -------------------------------------------------------------------------------------------------------------------- @@ -1093,8 +1089,6 @@ struct AidaWidget : ModuleWidgetWithSideScrews<23> { menu->addChild(new LoadModelFileItem(module)); } - - DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(AidaWidget) }; #else struct AidaWidget : ModuleWidget { diff --git a/plugins/Cardinal/src/AudioFile.cpp b/plugins/Cardinal/src/AudioFile.cpp index 699cb59..53e8933 100644 --- a/plugins/Cardinal/src/AudioFile.cpp +++ b/plugins/Cardinal/src/AudioFile.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -15,6 +15,7 @@ * For a full copy of the GNU General Public License see the LICENSE file. */ +#include "plugin.hpp" #include "plugincontext.hpp" #include "ModuleWidgets.hpp" #include "extra/Runner.hpp" @@ -39,6 +40,7 @@ const NativePluginDescriptor* carla_getNativePluginDescriptor(const std::size_t // -------------------------------------------------------------------------------------------------------------------- using namespace CARLA_BACKEND_NAMESPACE; +using namespace DISTRHO_NAMESPACE; static uint32_t host_get_buffer_size(NativeHostHandle); static double host_get_sample_rate(NativeHostHandle); @@ -335,8 +337,6 @@ struct CarlaInternalPluginModule : Module, Runner { 0, 0, nullptr, e.sampleRate); fCarlaPluginDescriptor->activate(fCarlaPluginHandle); } - - DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(CarlaInternalPluginModule) }; // ----------------------------------------------------------------------------------------------------------- @@ -679,8 +679,6 @@ struct AudioFileWidget : ModuleWidgetWithSideScrews<23> { menu->addChild(new LoadAudioFileItem(module)); } - - DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(AudioFileWidget) }; #else struct AudioFileWidget : ModuleWidget { diff --git a/plugins/Cardinal/src/AudioToCVPitch.cpp b/plugins/Cardinal/src/AudioToCVPitch.cpp index 2c79720..9fc982a 100644 --- a/plugins/Cardinal/src/AudioToCVPitch.cpp +++ b/plugins/Cardinal/src/AudioToCVPitch.cpp @@ -1,7 +1,7 @@ /* * DISTRHO Cardinal Plugin * Copyright (C) 2021-2022 Bram Giesen - * Copyright (C) 2022 Filipe Coelho + * Copyright (C) 2022-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -16,7 +16,7 @@ * For a full copy of the GNU General Public License see the LICENSE file. */ -#include "plugincontext.hpp" +#include "plugin.hpp" #include "ModuleWidgets.hpp" #include "Widgets.hpp" @@ -24,8 +24,6 @@ extern "C" { #include "aubio.h" } -USE_NAMESPACE_DISTRHO; - // -------------------------------------------------------------------------------------------------------------------- // aubio setup values (tested under 48 kHz sample rate) diff --git a/plugins/Cardinal/src/Carla.cpp b/plugins/Cardinal/src/Carla.cpp index b912283..bf51a29 100644 --- a/plugins/Cardinal/src/Carla.cpp +++ b/plugins/Cardinal/src/Carla.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2023 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -15,6 +15,7 @@ * For a full copy of the GNU General Public License see the LICENSE file. */ +#include "plugin.hpp" #include "plugincontext.hpp" #include "Expander.hpp" #include "ModuleWidgets.hpp" @@ -427,8 +428,6 @@ struct CarlaModule : Module { 0, 0, nullptr, e.sampleRate); fCarlaPluginDescriptor->activate(fCarlaPluginHandle); } - - DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(CarlaModule) }; static_assert((int)CarlaModule::NUM_INPUTS == (int)CarlaModule::NUM_OUTPUTS, "inputs must match outputs"); @@ -715,8 +714,6 @@ struct CarlaModuleWidget : ModuleWidgetWith9HP, IdleCallback { e.consume(this); showUI(); } - - DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(CarlaModuleWidget) }; static void host_ui_closed(NativeHostHandle handle) diff --git a/plugins/Cardinal/src/HostAudio.cpp b/plugins/Cardinal/src/HostAudio.cpp index 09c7949..7a5ad52 100644 --- a/plugins/Cardinal/src/HostAudio.cpp +++ b/plugins/Cardinal/src/HostAudio.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -15,9 +15,11 @@ * For a full copy of the GNU General Public License see the LICENSE file. */ +#include "plugin.hpp" #include "plugincontext.hpp" #include "ModuleWidgets.hpp" #include "Widgets.hpp" +#include "engine/TerminalModule.hpp" // ----------------------------------------------------------------------------------------------------------- diff --git a/plugins/Cardinal/src/HostCV.cpp b/plugins/Cardinal/src/HostCV.cpp index fee8aec..763922a 100644 --- a/plugins/Cardinal/src/HostCV.cpp +++ b/plugins/Cardinal/src/HostCV.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -15,8 +15,10 @@ * For a full copy of the GNU General Public License see the LICENSE file. */ +#include "plugin.hpp" #include "plugincontext.hpp" #include "ModuleWidgets.hpp" +#include "engine/TerminalModule.hpp" // ----------------------------------------------------------------------------------------------------------- diff --git a/plugins/Cardinal/src/HostMIDI-CC.cpp b/plugins/Cardinal/src/HostMIDI-CC.cpp index 3c71a86..2f5c103 100644 --- a/plugins/Cardinal/src/HostMIDI-CC.cpp +++ b/plugins/Cardinal/src/HostMIDI-CC.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -25,9 +25,11 @@ * the License, or (at your option) any later version. */ +#include "plugin.hpp" #include "plugincontext.hpp" #include "ModuleWidgets.hpp" #include "Widgets.hpp" +#include "engine/TerminalModule.hpp" #include diff --git a/plugins/Cardinal/src/HostMIDI-Gate.cpp b/plugins/Cardinal/src/HostMIDI-Gate.cpp index 77d34f7..c2153cd 100644 --- a/plugins/Cardinal/src/HostMIDI-Gate.cpp +++ b/plugins/Cardinal/src/HostMIDI-Gate.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -25,9 +25,11 @@ * the License, or (at your option) any later version. */ +#include "plugin.hpp" #include "plugincontext.hpp" #include "ModuleWidgets.hpp" #include "Widgets.hpp" +#include "engine/TerminalModule.hpp" #include diff --git a/plugins/Cardinal/src/HostMIDI-Map.cpp b/plugins/Cardinal/src/HostMIDI-Map.cpp index 46bb16e..1af8bf3 100644 --- a/plugins/Cardinal/src/HostMIDI-Map.cpp +++ b/plugins/Cardinal/src/HostMIDI-Map.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -25,9 +25,11 @@ * the License, or (at your option) any later version. */ +#include "plugin.hpp" #include "plugincontext.hpp" #include "ModuleWidgets.hpp" #include "Widgets.hpp" +#include "engine/TerminalModule.hpp" #include diff --git a/plugins/Cardinal/src/HostMIDI.cpp b/plugins/Cardinal/src/HostMIDI.cpp index ebb8105..22b8348 100644 --- a/plugins/Cardinal/src/HostMIDI.cpp +++ b/plugins/Cardinal/src/HostMIDI.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -25,7 +25,9 @@ * the License, or (at your option) any later version. */ +#include "plugin.hpp" #include "plugincontext.hpp" +#include "engine/TerminalModule.hpp" #include "ModuleWidgets.hpp" #include diff --git a/plugins/Cardinal/src/HostParameters-Map.cpp b/plugins/Cardinal/src/HostParameters-Map.cpp index eed89b5..d40d83b 100644 --- a/plugins/Cardinal/src/HostParameters-Map.cpp +++ b/plugins/Cardinal/src/HostParameters-Map.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -25,9 +25,11 @@ * the License, or (at your option) any later version. */ +#include "plugin.hpp" #include "plugincontext.hpp" #include "ModuleWidgets.hpp" #include "Widgets.hpp" +#include "engine/TerminalModule.hpp" // ----------------------------------------------------------------------------------------------------------- diff --git a/plugins/Cardinal/src/HostParameters.cpp b/plugins/Cardinal/src/HostParameters.cpp index 97c8912..1cbb37f 100644 --- a/plugins/Cardinal/src/HostParameters.cpp +++ b/plugins/Cardinal/src/HostParameters.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -15,8 +15,10 @@ * For a full copy of the GNU General Public License see the LICENSE file. */ +#include "plugin.hpp" #include "plugincontext.hpp" #include "ModuleWidgets.hpp" +#include "engine/TerminalModule.hpp" // ----------------------------------------------------------------------------------------------------------- diff --git a/plugins/Cardinal/src/HostTime.cpp b/plugins/Cardinal/src/HostTime.cpp index f853379..a28c4cd 100644 --- a/plugins/Cardinal/src/HostTime.cpp +++ b/plugins/Cardinal/src/HostTime.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -15,8 +15,10 @@ * For a full copy of the GNU General Public License see the LICENSE file. */ +#include "plugin.hpp" #include "plugincontext.hpp" #include "ModuleWidgets.hpp" +#include "engine/TerminalModule.hpp" // -------------------------------------------------------------------------------------------------------------------- diff --git a/plugins/Cardinal/src/Ildaeil.cpp b/plugins/Cardinal/src/Ildaeil.cpp index 55a2b65..9ed7212 100644 --- a/plugins/Cardinal/src/Ildaeil.cpp +++ b/plugins/Cardinal/src/Ildaeil.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2023 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -25,6 +25,7 @@ * the License, or (at your option) any later version. */ +#include "plugin.hpp" #include "plugincontext.hpp" #include "Expander.hpp" @@ -98,6 +99,7 @@ namespace ildaeil { // -------------------------------------------------------------------------------------------------------------------- using namespace CARLA_BACKEND_NAMESPACE; +using namespace DISTRHO_NAMESPACE; static uint32_t host_get_buffer_size(NativeHostHandle); static double host_get_sample_rate(NativeHostHandle); @@ -768,8 +770,6 @@ struct IldaeilModule : Module { 0, 0, nullptr, e.sampleRate); fCarlaPluginDescriptor->activate(fCarlaPluginHandle); } - - DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(IldaeilModule) }; // ----------------------------------------------------------------------------------------------------------- @@ -2252,8 +2252,6 @@ struct IldaeilWidget : ImGuiWidget, IdleCallback, Runner { ImGui::End(); } - - DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(IldaeilWidget) }; // -------------------------------------------------------------------------------------------------------------------- @@ -2435,8 +2433,6 @@ struct IldaeilModuleWidget : ModuleWidgetWithSideScrews<26> { ModuleWidgetWithSideScrews<26>::step(); } - - DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(IldaeilModuleWidget) }; #else static void host_ui_parameter_changed(NativeHostHandle, uint32_t, float) {} diff --git a/plugins/Cardinal/src/MPV.cpp b/plugins/Cardinal/src/MPV.cpp index df29019..acd0c1c 100644 --- a/plugins/Cardinal/src/MPV.cpp +++ b/plugins/Cardinal/src/MPV.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -15,12 +15,15 @@ * For a full copy of the GNU General Public License see the LICENSE file. */ +#include "plugin.hpp" #include "plugincontext.hpp" #ifndef HEADLESS # include "EmbedWidget.hpp" # include "extra/ExternalWindow.hpp" #endif +USE_NAMESPACE_DISTRHO; + // -------------------------------------------------------------------------------------------------------------------- struct CardinalEmbedModule : Module { diff --git a/plugins/Cardinal/src/SassyScope.cpp b/plugins/Cardinal/src/SassyScope.cpp index 392fa2a..bc836a1 100644 --- a/plugins/Cardinal/src/SassyScope.cpp +++ b/plugins/Cardinal/src/SassyScope.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -15,7 +15,7 @@ * For a full copy of the GNU General Public License see the LICENSE file. */ -#include "plugincontext.hpp" +#include "plugin.hpp" #include "ImGuiWidget.hpp" #include "sassy/sassy.hpp" #include "sassy/sassy_scope.cpp" diff --git a/plugins/Cardinal/src/TextEditor.cpp b/plugins/Cardinal/src/TextEditor.cpp index e16e9a2..5fa67ed 100644 --- a/plugins/Cardinal/src/TextEditor.cpp +++ b/plugins/Cardinal/src/TextEditor.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -15,7 +15,7 @@ * For a full copy of the GNU General Public License see the LICENSE file. */ -#include "plugincontext.hpp" +#include "plugin.hpp" #ifndef HEADLESS # include "ImGuiTextEditor.hpp" @@ -412,8 +412,6 @@ struct TextEditorModuleWidget : ModuleWidget { menu->addChild(new ui::MenuSeparator); menu->addChild(createMenuItem("Select all", RACK_MOD_CTRL_NAME "+A", [=]{ textEditorWidget->selectAll(); })); } - - DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(TextEditorModuleWidget) }; #else struct TextEditorModuleWidget : ModuleWidget { diff --git a/plugins/Cardinal/src/plugin.hpp b/plugins/Cardinal/src/plugin.hpp index 0b55a02..d31a261 100644 --- a/plugins/Cardinal/src/plugin.hpp +++ b/plugins/Cardinal/src/plugin.hpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -18,11 +18,8 @@ #pragma once #include "rack.hpp" -#include "engine/TerminalModule.hpp" - -#ifdef NDEBUG -# undef DEBUG -#endif +// #include "engine/TerminalModule.hpp" +// #include "plugincontext.hpp" using namespace rack; diff --git a/plugins/Cardinal/src/plugincontext.hpp b/plugins/Cardinal/src/plugincontext.hpp deleted file mode 100644 index f7fcc03..0000000 --- a/plugins/Cardinal/src/plugincontext.hpp +++ /dev/null @@ -1,89 +0,0 @@ -/* - * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License as - * published by the Free Software Foundation; either version 3 of - * the License, or any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * For a full copy of the GNU General Public License see the LICENSE file. - */ - -#pragma once - -#include "plugin.hpp" -#include "DistrhoUtils.hpp" - -#include "../dgl/Base.hpp" - -// ----------------------------------------------------------------------------------------------------------- -// from PluginContext.hpp - -START_NAMESPACE_DGL -class TopLevelWidget; -template class NanoBaseWidget; -typedef NanoBaseWidget NanoTopLevelWidget; -END_NAMESPACE_DGL - -START_NAMESPACE_DISTRHO - -static constexpr const uint32_t kModuleParameterCount = 24; - -enum CardinalVariant { - kCardinalVariantMain, - kCardinalVariantMini, - kCardinalVariantFX, - kCardinalVariantNative, - kCardinalVariantSynth, -}; - -class Plugin; -class UI; - -struct MidiEvent { - static const uint32_t kDataSize = 4; - uint32_t frame; - uint32_t size; - uint8_t data[kDataSize]; - const uint8_t* dataExt; -}; - -struct CardinalPluginContext : rack::Context { - uint32_t bufferSize, processCounter; - double sampleRate; - float parameters[kModuleParameterCount]; - CardinalVariant variant; - bool bypassed, playing, reset, bbtValid; - int32_t bar, beat, beatsPerBar, beatType; - uint64_t frame; - double barStartTick, beatsPerMinute; - double tick, tickClock, ticksPerBeat, ticksPerClock, ticksPerFrame; - uintptr_t nativeWindowId; - const float* const* dataIns; - float** dataOuts; - const MidiEvent* midiEvents; - uint32_t midiEventCount; - Plugin* const plugin; - DGL_NAMESPACE::NanoTopLevelWidget* tlw; - UI* ui; - CardinalPluginContext(Plugin* const p); - void writeMidiMessage(const rack::midi::Message& message, uint8_t channel); -#ifndef HEADLESS - bool addIdleCallback(IdleCallback* cb) const; - void removeIdleCallback(IdleCallback* cb) const; -#endif -}; - -#ifndef HEADLESS -void handleHostParameterDrag(const CardinalPluginContext* pcontext, uint index, bool started); -#endif - -END_NAMESPACE_DISTRHO - -// ----------------------------------------------------------------------------------------------------------- diff --git a/plugins/Makefile b/plugins/Makefile index d64f6e6..9536c73 100644 --- a/plugins/Makefile +++ b/plugins/Makefile @@ -578,8 +578,8 @@ BIDOO_CUSTOM_PER_FILE = channel channel filterType PLUGIN_FILES += $(filter-out Biset/src/plugin.cpp,$(wildcard Biset/src/*.cpp)) PLUGIN_FILES += $(wildcard Biset/src/*/*.cpp) -# # modules/types which are present in other plugins -BISET_CUSTOM = Blank +# modules/types which are present in other plugins +BISET_CUSTOM = Blank ButtonTrigger Clock Tree # -------------------------------------------------------------- # BogaudioModules @@ -1318,6 +1318,7 @@ BUILD_DIR = ../build/plugins endif BASE_FLAGS += -DBUILDING_PLUGIN_MODULES +BASE_FLAGS += -DDONT_SET_USING_DISTRHO_NAMESPACE BASE_FLAGS += -I$(abspath $(ROOT)/include/osdialog-stub) ifeq ($(BSD)$(WASM),true) diff --git a/plugins/plugins.cpp b/plugins/plugins.cpp index f9bad02..9fb9a15 100644 --- a/plugins/plugins.cpp +++ b/plugins/plugins.cpp @@ -147,9 +147,13 @@ extern Model* modelChord; #include "Bidoo/src/plugin.hpp" // Biset +#define modelBlank modelBisetBlank +#define modelTree modelBisetTree #define Clock BisetClock #define ButtonTrigger BisetButtonTrigger #include "Biset/src/plugin.hpp" +#undef modelBlank +#undef modelTree #undef ButtonTrigger #undef Clock @@ -1629,31 +1633,35 @@ static void initStatic__Biset() const StaticPluginLoader spl(p, "Biset"); if (spl.ok()) { +#define modelBlank modelBisetBlank +#define modelTree modelBisetTree p->addModel(modelTracker); - p->addModel(modelTrackerSynth); - p->addModel(modelTrackerDrum); - p->addModel(modelTrackerClock); - p->addModel(modelTrackerPhase); - p->addModel(modelTrackerQuant); - p->addModel(modelTrackerState); - p->addModel(modelTrackerControl); + p->addModel(modelTrackerSynth); + p->addModel(modelTrackerDrum); + p->addModel(modelTrackerClock); + p->addModel(modelTrackerPhase); + p->addModel(modelTrackerQuant); + p->addModel(modelTrackerState); + p->addModel(modelTrackerControl); - p->addModel(modelRegex); - p->addModel(modelRegexCondensed); - p->addModel(modelRegexExp); + p->addModel(modelRegex); + p->addModel(modelRegexCondensed); + p->addModel(modelRegexExp); - p->addModel(modelBisetTree); - p->addModel(modelBisetTreeSeed); + p->addModel(modelTree); + p->addModel(modelTreeSeed); - p->addModel(modelGbu); - p->addModel(modelPkm); + p->addModel(modelGbu); + p->addModel(modelPkm); - p->addModel(modelIgc); - p->addModel(modelOmega3); - p->addModel(modelOmega6); + p->addModel(modelIgc); + p->addModel(modelOmega3); + p->addModel(modelOmega6); - p->addModel(modelSegfault); - p->addModel(modelBlank); + p->addModel(modelSegfault); + p->addModel(modelBlank); +#undef modelBlank +#undef modelTree } } diff --git a/src/CardinalCommon.cpp b/src/CardinalCommon.cpp index b616872..003438a 100644 --- a/src/CardinalCommon.cpp +++ b/src/CardinalCommon.cpp @@ -101,8 +101,6 @@ void destroyStaticPlugins(); const std::string CARDINAL_VERSION = "24.04"; -START_NAMESPACE_DISTRHO - // ----------------------------------------------------------------------------------------------------------- #ifndef HEADLESS @@ -126,6 +124,51 @@ void handleHostParameterDrag(const CardinalPluginContext* pcontext, uint index, // -------------------------------------------------------------------------------------------------------------------- +CardinalPluginContext::CardinalPluginContext(Plugin* const p) + : bufferSize(p != nullptr ? p->getBufferSize() : 0), + processCounter(0), + sampleRate(p != nullptr ? p->getSampleRate() : 0.0), + #if CARDINAL_VARIANT_MAIN + variant(kCardinalVariantMain), + #elif CARDINAL_VARIANT_MINI + variant(kCardinalVariantMini), + #elif CARDINAL_VARIANT_FX + variant(kCardinalVariantFX), + #elif CARDINAL_VARIANT_NATIVE + variant(kCardinalVariantNative), + #elif CARDINAL_VARIANT_SYNTH + variant(kCardinalVariantSynth), + #else + #error cardinal variant not set + #endif + bypassed(false), + playing(false), + reset(false), + bbtValid(false), + bar(1), + beat(1), + beatsPerBar(4), + beatType(4), + frame(0), + barStartTick(0.0), + beatsPerMinute(120.0), + tick(0.0), + tickClock(0.0), + ticksPerBeat(0.0), + ticksPerClock(0.0), + ticksPerFrame(0.0), + nativeWindowId(0), + dataIns(nullptr), + dataOuts(nullptr), + midiEvents(nullptr), + midiEventCount(0), + plugin(p), + tlw(nullptr), + ui(nullptr) +{ + std::memset(parameters, 0, sizeof(parameters)); +} + #ifndef HEADLESS bool CardinalPluginContext::addIdleCallback(IdleCallback* const cb) const { @@ -224,6 +267,86 @@ void CardinalPluginContext::writeMidiMessage(const rack::midi::Message& message, // ----------------------------------------------------------------------------------------------------------- +namespace rack { +namespace midi { + +struct InputQueue::Internal { + CardinalPluginContext* const pcontext = static_cast(APP); + const CardinalDISTRHO::MidiEvent* midiEvents = nullptr; + uint32_t midiEventsLeft = 0; + uint32_t lastProcessCounter = 0; + int64_t lastBlockFrame = 0; +}; + +InputQueue::InputQueue() { + internal = new Internal; +} + +InputQueue::~InputQueue() { + delete internal; +} + +bool InputQueue::tryPop(Message* const messageOut, int64_t maxFrame) +{ + const uint32_t processCounter = internal->pcontext->processCounter; + const bool processCounterChanged = internal->lastProcessCounter != processCounter; + + if (processCounterChanged) + { + internal->lastBlockFrame = pcontext->engine->getBlockFrame(); + internal->lastProcessCounter = processCounter; + + internal->midiEvents = pcontext->midiEvents; + internal->midiEventsLeft = pcontext->midiEventCount; + } + + if (internal->midiEventsLeft == 0 || maxFrame < internal->lastBlockFrame) + return false; + + const uint32_t frame = maxFrame - internal->lastBlockFrame; + + if (frame > internal->midiEvents->frame) + return false; + + const CardinalDISTRHO::MidiEvent& midiEvent(*internal->midiEvents); + + const uint8_t* data; + if (midiEvent.size > CardinalDISTRHO::MidiEvent::kDataSize) + { + data = midiEvent.dataExt; + messageOut->bytes.resize(midiEvent.size); + } + else + { + data = midiEvent.data; + } + + messageOut->frame = frame; + std::memcpy(messageOut->bytes.data(), data, midiEvent.size); + + ++internal->midiEvents; + --internal->midiEventsLeft; + return true; +} + +json_t* InputQueue::toJson() const +{ + return nullptr; +} + +void InputQueue::fromJson(json_t* rootJ) +{ +} + +} +} + +// ----------------------------------------------------------------------------------------------------------- + +START_NAMESPACE_DISTRHO + +// ----------------------------------------------------------------------------------------------------------- + #ifdef HAVE_LIBLO static void osc_error_handler(int num, const char* msg, const char* path) { diff --git a/src/CardinalCommon.hpp b/src/CardinalCommon.hpp index 653b506..31b81b1 100644 --- a/src/CardinalCommon.hpp +++ b/src/CardinalCommon.hpp @@ -12,6 +12,8 @@ extern const std::string CARDINAL_VERSION; +struct CardinalPluginContext; + // ----------------------------------------------------------------------------------------------------------- namespace rack { @@ -84,7 +86,6 @@ START_NAMESPACE_DISTRHO class CardinalBasePlugin; class CardinalBaseUI; -struct CardinalPluginContext; struct Initializer { diff --git a/src/PluginContext.hpp b/src/PluginContext.hpp index fa5c97d..8c2f02b 100644 --- a/src/PluginContext.hpp +++ b/src/PluginContext.hpp @@ -36,29 +36,14 @@ #ifndef HEADLESS # include "DistrhoUI.hpp" -#else -# include "Base.hpp" -START_NAMESPACE_DGL -class TopLevelWidget; -template class NanoBaseWidget; -typedef NanoBaseWidget NanoTopLevelWidget; -END_NAMESPACE_DGL #endif +#include "plugincontext.hpp" + START_NAMESPACE_DISTRHO // ----------------------------------------------------------------------------------------------------------- -static constexpr const uint kModuleParameterCount = 24; - -enum CardinalVariant { - kCardinalVariantMain, - kCardinalVariantMini, - kCardinalVariantFX, - kCardinalVariantNative, - kCardinalVariantSynth, -}; - enum CardinalParameters { kCardinalParameterCountAtModules = kModuleParameterCount, kCardinalParameterBypass = kCardinalParameterCountAtModules, @@ -126,82 +111,6 @@ static_assert(kCardinalParameterCountAtWindow == kModuleParameterCount + kWindow static_assert(DISTRHO_PLUGIN_NUM_INPUTS == kCardinalParameterCountAtMiniBuffers - kCardinalParameterStartMiniBuffers, "valid parameter indexes"); #endif -class UI; - -// ----------------------------------------------------------------------------------------------------------- - -struct CardinalPluginContext : rack::Context { - uint32_t bufferSize, processCounter; - double sampleRate; - float parameters[kModuleParameterCount]; - CardinalVariant variant; - bool bypassed, playing, reset, bbtValid; - int32_t bar, beat, beatsPerBar, beatType; - uint64_t frame; - double barStartTick, beatsPerMinute; - double tick, tickClock, ticksPerBeat, ticksPerClock, ticksPerFrame; - uintptr_t nativeWindowId; - const float* const* dataIns; - float** dataOuts; - const MidiEvent* midiEvents; - uint32_t midiEventCount; - Plugin* const plugin; - NanoTopLevelWidget* tlw; - UI* ui; - - CardinalPluginContext(Plugin* const p) - : bufferSize(p != nullptr ? p->getBufferSize() : 0), - processCounter(0), - sampleRate(p != nullptr ? p->getSampleRate() : 0.0), - #if CARDINAL_VARIANT_MAIN - variant(kCardinalVariantMain), - #elif CARDINAL_VARIANT_MINI - variant(kCardinalVariantMini), - #elif CARDINAL_VARIANT_FX - variant(kCardinalVariantFX), - #elif CARDINAL_VARIANT_NATIVE - variant(kCardinalVariantNative), - #elif CARDINAL_VARIANT_SYNTH - variant(kCardinalVariantSynth), - #else - #error cardinal variant not set - #endif - bypassed(false), - playing(false), - reset(false), - bbtValid(false), - bar(1), - beat(1), - beatsPerBar(4), - beatType(4), - frame(0), - barStartTick(0.0), - beatsPerMinute(120.0), - tick(0.0), - tickClock(0.0), - ticksPerBeat(0.0), - ticksPerClock(0.0), - ticksPerFrame(0.0), - nativeWindowId(0), - dataIns(nullptr), - dataOuts(nullptr), - midiEvents(nullptr), - midiEventCount(0), - plugin(p), - tlw(nullptr), - ui(nullptr) - { - std::memset(parameters, 0, sizeof(parameters)); - } - - void writeMidiMessage(const rack::midi::Message& message, uint8_t channel); - - #ifndef HEADLESS - bool addIdleCallback(IdleCallback* cb) const; - void removeIdleCallback(IdleCallback* cb) const; - #endif -}; - // ----------------------------------------------------------------------------------------------------------- #if DISTRHO_PLUGIN_WANT_DIRECT_ACCESS From bc7c229ef465a5806d319c59db25985e2c51a704 Mon Sep 17 00:00:00 2001 From: falkTX Date: Thu, 11 Apr 2024 10:36:55 +0200 Subject: [PATCH 17/21] Use biset fork for now Signed-off-by: falkTX --- plugins/Biset | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/Biset b/plugins/Biset index a3acddc..a697109 160000 --- a/plugins/Biset +++ b/plugins/Biset @@ -1 +1 @@ -Subproject commit a3acddc30732700b91f27075488b914c38b9dcdf +Subproject commit a697109733cf0d0f022cf01e06896a1e78b236f6 From 3f0b370c0ecb7409b1bfb723626483e8f1c1198c Mon Sep 17 00:00:00 2001 From: falkTX Date: Thu, 11 Apr 2024 10:40:31 +0200 Subject: [PATCH 18/21] Add new plugin-accessible plugincontext.hpp Signed-off-by: falkTX --- include/plugincontext.hpp | 106 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 106 insertions(+) create mode 100644 include/plugincontext.hpp diff --git a/include/plugincontext.hpp b/include/plugincontext.hpp new file mode 100644 index 0000000..a25c6f0 --- /dev/null +++ b/include/plugincontext.hpp @@ -0,0 +1,106 @@ +/* + * DISTRHO Cardinal Plugin + * Copyright (C) 2021-2024 Filipe Coelho + * SPDX-License-Identifier: GPL-3.0-or-later + */ + +#pragma once + +#ifdef BUILDING_PLUGIN_MODULES +#include "rack.hpp" +#endif + +namespace rack { +namespace midi { +struct Message; +} +} + +// -------------------------------------------------------------------------------------------------------------------- +// Base DISTRHO classes + +#ifndef DISTRHO_DETAILS_HPP_INCLUDED + +namespace CardinalDISTRHO { + +class Plugin; +class UI; + +struct MidiEvent { + static const uint32_t kDataSize = 4; + uint32_t frame; + uint32_t size; + uint8_t data[kDataSize]; + const uint8_t* dataExt; +}; + +} + +#endif + +// -------------------------------------------------------------------------------------------------------------------- +// Base DGL classes + +#ifndef DGL_BASE_HPP_INCLUDED + +namespace CardinalDGL { + +class TopLevelWidget; +template class NanoBaseWidget; +typedef NanoBaseWidget NanoTopLevelWidget; + +struct IdleCallback { + virtual ~IdleCallback() {} + virtual void idleCallback() = 0; +}; + +} + +#endif + +using CardinalDGL::IdleCallback; + +// -------------------------------------------------------------------------------------------------------------------- +// Cardinal specific context + +static constexpr const uint32_t kModuleParameterCount = 24; + +enum CardinalVariant { + kCardinalVariantMain, + kCardinalVariantMini, + kCardinalVariantFX, + kCardinalVariantNative, + kCardinalVariantSynth, +}; + +struct CardinalPluginContext : rack::Context { + uint32_t bufferSize, processCounter; + double sampleRate; + float parameters[kModuleParameterCount]; + CardinalVariant variant; + bool bypassed, playing, reset, bbtValid; + int32_t bar, beat, beatsPerBar, beatType; + uint64_t frame; + double barStartTick, beatsPerMinute; + double tick, tickClock, ticksPerBeat, ticksPerClock, ticksPerFrame; + uintptr_t nativeWindowId; + const float* const* dataIns; + float** dataOuts; + const CardinalDISTRHO::MidiEvent* midiEvents; + uint32_t midiEventCount; + CardinalDISTRHO::Plugin* const plugin; + CardinalDGL::NanoTopLevelWidget* tlw; + CardinalDISTRHO::UI* ui; + CardinalPluginContext(CardinalDISTRHO::Plugin* const p); + void writeMidiMessage(const rack::midi::Message& message, uint8_t channel); +#ifndef HEADLESS + bool addIdleCallback(IdleCallback* cb) const; + void removeIdleCallback(IdleCallback* cb) const; +#endif +}; + +#ifndef HEADLESS +void handleHostParameterDrag(const CardinalPluginContext* pcontext, uint index, bool started); +#endif + +// -------------------------------------------------------------------------------------------------------------------- From 73e75ce012217f2779a8a70736026293a9327672 Mon Sep 17 00:00:00 2001 From: falkTX Date: Mon, 15 Apr 2024 14:21:09 +0200 Subject: [PATCH 19/21] Fix build Signed-off-by: falkTX --- include/midi.hpp | 2 ++ src/CardinalCommon.cpp | 10 +++++----- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/include/midi.hpp b/include/midi.hpp index 20f2cb1..7c2135e 100644 --- a/include/midi.hpp +++ b/include/midi.hpp @@ -29,6 +29,8 @@ #include "choc/choc_SmallVector.h" +#include + namespace rack { /** Abstraction for all MIDI drivers in Rack */ namespace midi { diff --git a/src/CardinalCommon.cpp b/src/CardinalCommon.cpp index 003438a..a26e5c9 100644 --- a/src/CardinalCommon.cpp +++ b/src/CardinalCommon.cpp @@ -279,11 +279,11 @@ struct InputQueue::Internal { }; InputQueue::InputQueue() { - internal = new Internal; + internal = new Internal; } InputQueue::~InputQueue() { - delete internal; + delete internal; } bool InputQueue::tryPop(Message* const messageOut, int64_t maxFrame) @@ -293,11 +293,11 @@ bool InputQueue::tryPop(Message* const messageOut, int64_t maxFrame) if (processCounterChanged) { - internal->lastBlockFrame = pcontext->engine->getBlockFrame(); + internal->lastBlockFrame = internal->pcontext->engine->getBlockFrame(); internal->lastProcessCounter = processCounter; - internal->midiEvents = pcontext->midiEvents; - internal->midiEventsLeft = pcontext->midiEventCount; + internal->midiEvents = internal->pcontext->midiEvents; + internal->midiEventsLeft = internal->pcontext->midiEventCount; } if (internal->midiEventsLeft == 0 || maxFrame < internal->lastBlockFrame) From a6a83f3dae802e18ceac982349fe13b483711102 Mon Sep 17 00:00:00 2001 From: falkTX Date: Mon, 15 Apr 2024 15:36:09 +0200 Subject: [PATCH 20/21] More build fixes Signed-off-by: falkTX --- include/plugincontext.hpp | 6 ++++-- plugins/Makefile | 2 +- plugins/plugins.cpp | 28 +++++++++++++++++++++++----- src/CardinalUI.cpp | 2 +- 4 files changed, 29 insertions(+), 9 deletions(-) diff --git a/include/plugincontext.hpp b/include/plugincontext.hpp index a25c6f0..74def30 100644 --- a/include/plugincontext.hpp +++ b/include/plugincontext.hpp @@ -89,14 +89,16 @@ struct CardinalPluginContext : rack::Context { const CardinalDISTRHO::MidiEvent* midiEvents; uint32_t midiEventCount; CardinalDISTRHO::Plugin* const plugin; + #ifndef HEADLESS CardinalDGL::NanoTopLevelWidget* tlw; CardinalDISTRHO::UI* ui; + #endif CardinalPluginContext(CardinalDISTRHO::Plugin* const p); void writeMidiMessage(const rack::midi::Message& message, uint8_t channel); -#ifndef HEADLESS + #ifndef HEADLESS bool addIdleCallback(IdleCallback* cb) const; void removeIdleCallback(IdleCallback* cb) const; -#endif + #endif }; #ifndef HEADLESS diff --git a/plugins/Makefile b/plugins/Makefile index 9536c73..d929601 100644 --- a/plugins/Makefile +++ b/plugins/Makefile @@ -579,7 +579,7 @@ PLUGIN_FILES += $(filter-out Biset/src/plugin.cpp,$(wildcard Biset/src/*.cpp)) PLUGIN_FILES += $(wildcard Biset/src/*/*.cpp) # modules/types which are present in other plugins -BISET_CUSTOM = Blank ButtonTrigger Clock Tree +BISET_CUSTOM = Blank ButtonTrigger Clock Tree TreeDisplay # -------------------------------------------------------------- # BogaudioModules diff --git a/plugins/plugins.cpp b/plugins/plugins.cpp index 9fb9a15..8b2d834 100644 --- a/plugins/plugins.cpp +++ b/plugins/plugins.cpp @@ -147,15 +147,33 @@ extern Model* modelChord; #include "Bidoo/src/plugin.hpp" // Biset +/* NOTE too much noise in original include, do this a different way +// #include "Biset/src/plugin.hpp" +*/ #define modelBlank modelBisetBlank #define modelTree modelBisetTree -#define Clock BisetClock -#define ButtonTrigger BisetButtonTrigger -#include "Biset/src/plugin.hpp" +extern Model* modelTracker; +extern Model* modelTrackerSynth; +extern Model* modelTrackerDrum; +extern Model* modelTrackerClock; +extern Model* modelTrackerPhase; +extern Model* modelTrackerQuant; +extern Model* modelTrackerState; +extern Model* modelTrackerControl; +extern Model* modelRegex; +extern Model* modelRegexCondensed; +extern Model* modelRegexExp; +extern Model* modelTree; +extern Model* modelTreeSeed; +extern Model* modelGbu; +extern Model* modelPkm; +extern Model* modelIgc; +extern Model* modelOmega3; +extern Model* modelOmega6; +extern Model* modelSegfault; +extern Model* modelBlank; #undef modelBlank #undef modelTree -#undef ButtonTrigger -#undef Clock // BogaudioModules - integrate theme/skin support #include diff --git a/src/CardinalUI.cpp b/src/CardinalUI.cpp index 27373cd..3f9cabb 100644 --- a/src/CardinalUI.cpp +++ b/src/CardinalUI.cpp @@ -1081,7 +1081,7 @@ protected: int key; switch (ev.key) { - case '\t': key = GLFW_KEY_TAB; break; + case kKeyTab: key = GLFW_KEY_TAB; break; case kKeyBackspace: key = GLFW_KEY_BACKSPACE; break; case kKeyEnter: key = GLFW_KEY_ENTER; break; case kKeyEscape: key = GLFW_KEY_ESCAPE; break; From df0f1ac1dbb7b623330eef75fced38983be9c1fb Mon Sep 17 00:00:00 2001 From: falkTX Date: Mon, 15 Apr 2024 17:58:44 +0200 Subject: [PATCH 21/21] Rename a file to prevent conflicts Signed-off-by: falkTX --- src/CardinalCommon.cpp | 10 ++++++---- src/CardinalPlugin.cpp | 2 +- src/{PluginContext.hpp => CardinalPluginContext.hpp} | 0 src/CardinalRemote.cpp | 4 ++-- src/CardinalRemote/RemoteUI.hpp | 4 ++-- src/CardinalRemote/main.cpp | 4 ++-- src/CardinalUI.cpp | 4 ++-- src/custom/glfw.cpp | 4 ++-- src/override/MenuBar.cpp | 4 ++-- src/override/Window.cpp | 4 ++-- 10 files changed, 21 insertions(+), 19 deletions(-) rename src/{PluginContext.hpp => CardinalPluginContext.hpp} (100%) diff --git a/src/CardinalCommon.cpp b/src/CardinalCommon.cpp index a26e5c9..5512e5e 100644 --- a/src/CardinalCommon.cpp +++ b/src/CardinalCommon.cpp @@ -17,7 +17,7 @@ #include "CardinalCommon.hpp" #include "AsyncDialog.hpp" -#include "PluginContext.hpp" +#include "CardinalPluginContext.hpp" #include "DistrhoPluginUtils.hpp" #include @@ -162,9 +162,11 @@ CardinalPluginContext::CardinalPluginContext(Plugin* const p) dataOuts(nullptr), midiEvents(nullptr), midiEventCount(0), - plugin(p), - tlw(nullptr), - ui(nullptr) + plugin(p) + #ifndef HEADLESS + , tlw(nullptr) + , ui(nullptr) + #endif { std::memset(parameters, 0, sizeof(parameters)); } diff --git a/src/CardinalPlugin.cpp b/src/CardinalPlugin.cpp index 09d6a1a..3ed2fe9 100644 --- a/src/CardinalPlugin.cpp +++ b/src/CardinalPlugin.cpp @@ -32,7 +32,7 @@ #include "CardinalCommon.hpp" #include "DistrhoPluginUtils.hpp" -#include "PluginContext.hpp" +#include "CardinalPluginContext.hpp" #include "extra/Base64.hpp" #include "extra/ScopedDenormalDisable.hpp" #include "extra/ScopedSafeLocale.hpp" diff --git a/src/PluginContext.hpp b/src/CardinalPluginContext.hpp similarity index 100% rename from src/PluginContext.hpp rename to src/CardinalPluginContext.hpp diff --git a/src/CardinalRemote.cpp b/src/CardinalRemote.cpp index c795137..14db71d 100644 --- a/src/CardinalRemote.cpp +++ b/src/CardinalRemote.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -24,7 +24,7 @@ #endif #include "CardinalRemote.hpp" -#include "PluginContext.hpp" +#include "CardinalPluginContext.hpp" #include "extra/Base64.hpp" #include "extra/ScopedSafeLocale.hpp" diff --git a/src/CardinalRemote/RemoteUI.hpp b/src/CardinalRemote/RemoteUI.hpp index 15b1c90..ab428fc 100644 --- a/src/CardinalRemote/RemoteUI.hpp +++ b/src/CardinalRemote/RemoteUI.hpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -18,7 +18,7 @@ #pragma once #include "NanoVG.hpp" -#include "PluginContext.hpp" +#include "CardinalPluginContext.hpp" #include "WindowParameters.hpp" #include diff --git a/src/CardinalRemote/main.cpp b/src/CardinalRemote/main.cpp index 381b086..c7fca63 100644 --- a/src/CardinalRemote/main.cpp +++ b/src/CardinalRemote/main.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2022 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -30,7 +30,7 @@ #include #include -#include "PluginContext.hpp" +#include "CardinalPluginContext.hpp" #include "extra/ScopedValueSetter.hpp" #define CARDINAL_TEMPLATE_NAME "init/main.vcv" diff --git a/src/CardinalUI.cpp b/src/CardinalUI.cpp index 3f9cabb..b088e59 100644 --- a/src/CardinalUI.cpp +++ b/src/CardinalUI.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2023 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -49,7 +49,7 @@ #include "Application.hpp" #include "AsyncDialog.hpp" #include "CardinalCommon.hpp" -#include "PluginContext.hpp" +#include "CardinalPluginContext.hpp" #include "WindowParameters.hpp" #include "extra/Base64.hpp" diff --git a/src/custom/glfw.cpp b/src/custom/glfw.cpp index e3718d7..b9c72b9 100644 --- a/src/custom/glfw.cpp +++ b/src/custom/glfw.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2023 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -16,7 +16,7 @@ */ #include "Application.hpp" -#include "PluginContext.hpp" +#include "CardinalPluginContext.hpp" #include diff --git a/src/override/MenuBar.cpp b/src/override/MenuBar.cpp index 7a13f17..77ad6d1 100644 --- a/src/override/MenuBar.cpp +++ b/src/override/MenuBar.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2023 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -53,7 +53,7 @@ #include "../CardinalCommon.hpp" #include "../CardinalRemote.hpp" -#include "../PluginContext.hpp" +#include "../CardinalPluginContext.hpp" #include "DistrhoPlugin.hpp" #include "DistrhoStandaloneUtils.hpp" diff --git a/src/override/Window.cpp b/src/override/Window.cpp index 2005652..e1b3bf3 100644 --- a/src/override/Window.cpp +++ b/src/override/Window.cpp @@ -1,6 +1,6 @@ /* * DISTRHO Cardinal Plugin - * Copyright (C) 2021-2023 Filipe Coelho + * Copyright (C) 2021-2024 Filipe Coelho * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -46,7 +46,7 @@ #include "Application.hpp" #include "extra/String.hpp" #include "../CardinalCommon.hpp" -#include "../PluginContext.hpp" +#include "../CardinalPluginContext.hpp" #include "../WindowParameters.hpp" #ifndef DGL_NO_SHARED_RESOURCES