Skip to content

Commit 39c6c21

Browse files
committed
Update all plugins, enable clap
Signed-off-by: falkTX <falktx@falktx.com>
1 parent ac0e5ee commit 39c6c21

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

75 files changed

+3541
-1152
lines changed

Makefile

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -79,18 +79,26 @@ ifneq ($(HAVE_PROJECTM),true)
7979
ln -sf $(CURDIR)/plugins/ProM/projectM/presets/presets_* bin/ProM.lv2/resources/presets/
8080

8181
ifeq ($(MACOS),true)
82-
# VST2 fonts
82+
# CLAP + VST2 fonts
83+
install -d bin/ProM.clap/Contents/Resources/fonts
8384
install -d bin/ProM.vst/Contents/Resources/fonts
85+
ln -sf $(CURDIR)/plugins/ProM/projectM/fonts/*.ttf bin/ProM.clap/Contents/Resources/fonts/
8486
ln -sf $(CURDIR)/plugins/ProM/projectM/fonts/*.ttf bin/ProM.vst/Contents/Resources/fonts/
85-
# VST2 presets
87+
# CLAP + VST2 presets
88+
install -d bin/ProM.clap/Contents/Resources/presets
8689
install -d bin/ProM.vst/Contents/Resources/presets
90+
ln -sf $(CURDIR)/plugins/ProM/projectM/presets/presets_* bin/ProM.clap/Contents/Resources/presets/
8791
ln -sf $(CURDIR)/plugins/ProM/projectM/presets/presets_* bin/ProM.vst/Contents/Resources/presets/
8892
else
89-
# VST2 fonts
93+
# CLAP + VST2 fonts
94+
install -d bin/ProM.clap/resources/fonts
9095
install -d bin/ProM.vst/resources/fonts
96+
ln -sf $(CURDIR)/plugins/ProM/projectM/fonts/*.ttf bin/ProM.clap/resources/fonts/
9197
ln -sf $(CURDIR)/plugins/ProM/projectM/fonts/*.ttf bin/ProM.vst/resources/fonts/
92-
# VST2 presets
98+
# CLAP + VST2 presets
99+
install -d bin/ProM.clap/resources/presets
93100
install -d bin/ProM.vst/resources/presets
101+
ln -sf $(CURDIR)/plugins/ProM/projectM/presets/presets_* bin/ProM.clap/resources/presets/
94102
ln -sf $(CURDIR)/plugins/ProM/projectM/presets/presets_* bin/ProM.vst/resources/presets/
95103
endif
96104

@@ -160,6 +168,7 @@ install:
160168
install -d $(DESTDIR)$(PREFIX)/lib/lv2/
161169
install -d $(DESTDIR)$(PREFIX)/lib/vst/
162170
install -d $(DESTDIR)$(PREFIX)/lib/vst3/
171+
install -d $(DESTDIR)$(PREFIX)/lib/clap/
163172
install -d $(DESTDIR)$(PREFIX)/bin/
164173

165174
install -m 644 bin/*-ladspa.* $(DESTDIR)$(PREFIX)/lib/ladspa/
@@ -176,6 +185,7 @@ ifeq ($(HAVE_OPENGL),true)
176185
cp -rL bin/*.vst $(DESTDIR)$(PREFIX)/lib/vst/
177186
endif # HAVE_OPENGL
178187
cp -rL bin/*.vst3 $(DESTDIR)$(PREFIX)/lib/vst3/
188+
cp -rL bin/*.clap $(DESTDIR)$(PREFIX)/lib/clap/
179189

180190
install -m 755 bin/Kars$(APP_EXT) $(DESTDIR)$(PREFIX)/bin/
181191
install -m 755 bin/3BandEQ$(APP_EXT) $(DESTDIR)$(PREFIX)/bin/

dpf/LICENSING.md

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,7 @@
22

33
Even though DPF is quite liberally licensed, not all plugin formats follow the same ideals.
44
This is usually due to plugin APIs/headers being tied to a specific license or having commercial restrictions.
5-
This file describes the licensing that applies to each individual plugin format as a way to make it clear what is possible and compatible.
6-
Note that if you are making GPLv2+ licensed plugins this does not apply to you, as so far everything is GPLv2+ compatible.
5+
This file describes the licensing that applies to each individual plugin format as a way to make it clear what is possible and compatible.
76

87
Regardless of target format, DPF itself needs to be mentioned in attribution.
98
See the [LICENSE](LICENSE) file for copyright details.
@@ -14,8 +13,9 @@ See the [LICENSE](LICENSE) file for copyright details.
1413
| LADSPA | LGPLv2.1+ | ??? (*) | 2000-2002 Richard W. E. Furse, Paul Barton-Davis, Stefan Westerfeld |
1514
| DSSI | LGPLv2.1+ | ??? (*) | **DSSI**: 2004, 2009 Chris Cannam, Steve Harris and Sean Bolton;<br/> **ALSA**: 1998-2001 Jaroslav Kysela, Abramo Bagnara, Takashi Iwai |
1615
| LV2 | ISC | Copyright attribution | 2006-2020 Steve Harris, David Robillard;<br/> 2000-2002 Richard W.E. Furse, Paul Barton-Davis, Stefan Westerfeld |
17-
| VST2 | GPLv2+ or commercial | Must be GPLv2+ compatible or alternatively use Steinberg VST2 SDK (no longer available for new plugins) | GPLv2+ compatible license or custom agreement with Steinberg |
16+
| VST2 | BSD-3 | Copyright attribution | 2020-2022 Michael Fabian 'Xaymar' Dirks |
1817
| VST3 | ISC | Copyright attribution | (none, only DPF files used) |
18+
| CLAP | MIT | Copyright attribution | 2014-2022 Alexandre Bique |
1919

2020
### LADSPA and DSSI special note
2121

@@ -32,12 +32,9 @@ These formats are very limited and not much used anymore anyway, feel free to sk
3232

3333
### VST2 special note
3434

35-
By default DPF uses the free reverse-engineered [vestige header](distrho/src/vestige/vestige.h) file.
36-
This file is GPLv2+ licensed, so that applies to plugins built with it as well.
37-
You can alternatively build DPF-based VST2 plugins using the official Steinberg VST2 SDK,
38-
simply set the `VESTIGE_HEADER` compiler macro to `0` during build.
39-
You will need to provide your own VST2 SDK files then, as DPF does not ship with them.
40-
Note there are legal issues surrounding releasing new VST2 plugins using the official SDK, as that is no longer supported by Steinberg.
35+
The DPF's VST2 implementation uses https://github.com/Xaymar/vst2sdk which is a liberally-licensed "clean room" untainted reverse engineered "SDK" for the VST2 interface.
36+
Previously "vestige" was used, but was problematic due to it being GPLv2 licensed.
37+
With the Xaymar's work, both open-source and proprietary plugins can be created from the same source, which helps in maintenance on DPF side.
4138

4239
### VST3 special note
4340

dpf/Makefile.base.mk

Lines changed: 58 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,11 @@ DPF_MAKEFILE_BASE_INCLUDED = true
3535
# ---------------------------------------------------------------------------------------------------------------------
3636
# Auto-detect target compiler if not defined
3737

38+
ifeq ($(shell echo '\#test' | grep -- '\#test'),\#test)
3839
TARGET_COMPILER = $(shell echo '\#ifdef __clang__\nclang\n\#else\ngcc\n\#endif' | $(CC) -E -P -x c - 2>/dev/null)
40+
else
41+
TARGET_COMPILER = $(shell echo '#ifdef __clang__\nclang\n#else\ngcc\n#endif' | $(CC) -E -P -x c - 2>/dev/null)
42+
endif
3943

4044
ifneq ($(CLANG),true)
4145
ifneq ($(GCC),true)
@@ -119,6 +123,9 @@ ifneq (,$(filter aarch64%,$(TARGET_PROCESSOR)))
119123
CPU_ARM64 = true
120124
CPU_ARM_OR_ARM64 = true
121125
endif
126+
ifneq (,$(filter riscv64%,$(TARGET_PROCESSOR)))
127+
CPU_RISCV64 = true
128+
endif
122129

123130
ifeq ($(CPU_ARM),true)
124131
ifneq ($(CPU_ARM64),true)
@@ -246,8 +253,7 @@ else ifeq ($(WASM),true)
246253
LINK_OPTS += -O3
247254
LINK_OPTS += -Wl,--gc-sections
248255
else
249-
LINK_OPTS += -Wl,-O1,--gc-sections
250-
LINK_OPTS += -Wl,--as-needed
256+
LINK_OPTS += -Wl,-O1,--as-needed,--gc-sections
251257
endif
252258

253259
ifneq ($(SKIP_STRIPPING),true)
@@ -658,6 +664,8 @@ features:
658664
$(call print_available,CPU_ARM_OR_ARM64)
659665
$(call print_available,CPU_I386)
660666
$(call print_available,CPU_I386_OR_X86_64)
667+
$(call print_available,CPU_RISCV64)
668+
$(call print_available,CPU_X86_64)
661669
@echo === Detected OS
662670
$(call print_available,BSD)
663671
$(call print_available,HAIKU)
@@ -677,6 +685,7 @@ features:
677685
$(call print_available,HAVE_DBUS)
678686
$(call print_available,HAVE_CAIRO)
679687
$(call print_available,HAVE_DGL)
688+
$(call print_available,HAVE_JACK)
680689
$(call print_available,HAVE_LIBLO)
681690
$(call print_available,HAVE_OPENGL)
682691
$(call print_available,HAVE_PULSEAUDIO)
@@ -689,6 +698,53 @@ features:
689698
$(call print_available,HAVE_XEXT)
690699
$(call print_available,HAVE_XRANDR)
691700

701+
# ---------------------------------------------------------------------------------------------------------------------
702+
# Extra rules for MOD Audio stuff
703+
704+
# NOTE: note path must be absolute
705+
MOD_WORKDIR ?= $(HOME)/mod-workdir
706+
MOD_ENVIRONMENT = \
707+
AR=${1}/host/usr/bin/${2}-gcc-ar \
708+
CC=${1}/host/usr/bin/${2}-gcc \
709+
CPP=${1}/host/usr/bin/${2}-cpp \
710+
CXX=${1}/host/usr/bin/${2}-g++ \
711+
LD=${1}/host/usr/bin/${2}-ld \
712+
PKG_CONFIG=${1}/host/usr/bin/pkg-config \
713+
STRIP=${1}/host/usr/bin/${2}-strip \
714+
CFLAGS="-I${1}/staging/usr/include $(EXTRA_MOD_FLAGS)" \
715+
CPPFLAGS= \
716+
CXXFLAGS="-I${1}/staging/usr/include $(EXTRA_MOD_FLAGS)" \
717+
LDFLAGS="-L${1}/staging/usr/lib $(EXTRA_MOD_FLAGS)" \
718+
EXE_WRAPPER="qemu-${3}-static -L ${1}/target" \
719+
NOOPT=true
720+
721+
modduo:
722+
$(MAKE) $(call MOD_ENVIRONMENT,$(MOD_WORKDIR)/modduo-static,arm-mod-linux-gnueabihf.static,arm)
723+
724+
modduox:
725+
$(MAKE) $(call MOD_ENVIRONMENT,$(MOD_WORKDIR)/modduox-static,aarch64-mod-linux-gnueabi.static,aarch64)
726+
727+
moddwarf:
728+
$(MAKE) $(call MOD_ENVIRONMENT,$(MOD_WORKDIR)/moddwarf,aarch64-mod-linux-gnu,aarch64)
729+
730+
modpush:
731+
tar -C bin -cz $(subst bin/,,$(wildcard bin/*.lv2)) | base64 | curl -F 'package=@-' http://192.168.51.1/sdk/install && echo
732+
733+
ifneq (,$(findstring modduo-,$(MAKECMDGOALS)))
734+
$(MAKECMDGOALS):
735+
$(MAKE) $(call MOD_ENVIRONMENT,$(MOD_WORKDIR)/modduo,arm-mod-linux-gnueabihf,arm) $(subst modduo-,,$(MAKECMDGOALS))
736+
endif
737+
738+
ifneq (,$(findstring modduox-,$(MAKECMDGOALS)))
739+
$(MAKECMDGOALS):
740+
$(MAKE) $(call MOD_ENVIRONMENT,$(MOD_WORKDIR)/modduox,aarch64-mod-linux-gnueabi,aarch64) $(subst modduox-,,$(MAKECMDGOALS))
741+
endif
742+
743+
ifneq (,$(findstring moddwarf-,$(MAKECMDGOALS)))
744+
$(MAKECMDGOALS):
745+
$(MAKE) $(call MOD_ENVIRONMENT,$(MOD_WORKDIR)/moddwarf,aarch64-mod-linux-gnu,aarch64) $(subst moddwarf-,,$(MAKECMDGOALS))
746+
endif
747+
692748
# ---------------------------------------------------------------------------------------------------------------------
693749
# Protect against multiple inclusion
694750

dpf/README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ DPF is designed to make development of new plugins an easy and enjoyable task.<b
77
It allows developers to create plugins with custom UIs using a simple C++ API.<br/>
88
The framework facilitates exporting various different plugin formats from the same code-base.<br/>
99

10-
DPF can build for LADSPA, DSSI, LV2, VST2 and VST3 formats.<br/>
10+
DPF can build for LADSPA, DSSI, LV2, VST2, VST3 and CLAP formats.<br/>
1111
All current plugin format implementations are complete.<br/>
1212
A JACK/Standalone mode is also available, allowing you to quickly test plugins.<br/>
1313

@@ -44,6 +44,7 @@ Online help and discussion about DPF happens in the [kx.studio chat, DPF room](h
4444
- [DISTRHO ProM](https://github.com/DISTRHO/ProM)
4545
- [Dragonfly Reverb](https://michaelwillis.github.io/dragonfly-reverb)
4646
- [Fogpad-port](https://github.com/linuxmao-org/fogpad-port)
47+
- [master_me](https://github.com/trummerschlunk/master_me)
4748
- [Ninjas2](https://github.com/rghvdberg/ninjas2)
4849
- [osamc-lv2-workshop](https://github.com/osamc-lv2-workshop/lv2-workshop) (simple plugins code examples)
4950
- [QuadraFuzz](https://github.com/jpcima/quadrafuzz)

dpf/dgl/NanoVG.hpp

Lines changed: 20 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -319,10 +319,9 @@ class NanoVG
319319

320320
/**
321321
Constructor reusing a NanoVG context, used for subwidgets.
322+
Context will not be deleted on class destructor.
322323
*/
323-
/*
324-
NanoVG(NanoWidget* groupWidget);
325-
*/
324+
explicit NanoVG(NVGcontext* context);
326325

327326
/**
328327
Destructor.
@@ -917,7 +916,17 @@ class NanoBaseWidget : public BaseWidget,
917916
Constructor for a NanoSubWidget.
918917
@see CreateFlags
919918
*/
920-
explicit NanoBaseWidget(Widget* parentGroupWidget, int flags = CREATE_ANTIALIAS);
919+
explicit NanoBaseWidget(Widget* parentWidget, int flags = CREATE_ANTIALIAS);
920+
921+
/**
922+
Constructor for a NanoSubWidget reusing a parent subwidget nanovg context.
923+
*/
924+
explicit NanoBaseWidget(NanoBaseWidget<SubWidget>* parentWidget);
925+
926+
/**
927+
Constructor for a NanoSubWidget reusing a parent top-level-widget nanovg context.
928+
*/
929+
explicit NanoBaseWidget(NanoBaseWidget<TopLevelWidget>* parentWidget);
921930

922931
/**
923932
Constructor for a NanoTopLevelWidget.
@@ -954,13 +963,7 @@ class NanoBaseWidget : public BaseWidget,
954963
Widget display function.
955964
Implemented internally to wrap begin/endFrame() automatically.
956965
*/
957-
inline void onDisplay() override
958-
{
959-
// NOTE maybe should use BaseWidget::getWindow().getScaleFactor() as 3rd arg ?
960-
NanoVG::beginFrame(BaseWidget::getWidth(), BaseWidget::getHeight());
961-
onNanoDisplay();
962-
NanoVG::endFrame();
963-
}
966+
void onDisplay() override;
964967

965968
// these should not be used
966969
void beginFrame(uint,uint) {}
@@ -969,6 +972,12 @@ class NanoBaseWidget : public BaseWidget,
969972
void cancelFrame() {}
970973
void endFrame() {}
971974

975+
/** @internal */
976+
const bool fUsingParentContext;
977+
void displayChildren();
978+
friend class NanoBaseWidget<TopLevelWidget>;
979+
friend class NanoBaseWidget<StandaloneWindow>;
980+
972981
DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(NanoBaseWidget)
973982
};
974983

dpf/dgl/Window.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -541,7 +541,7 @@ class DISTRHO_API Window
541541
uint height,
542542
double scaleFactor,
543543
bool resizable,
544-
bool isVST3,
544+
bool usesSizeRequest,
545545
bool doPostInit);
546546

547547
DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(Window)

0 commit comments

Comments
 (0)