Skip to content

Commit

Permalink
add DrumKit, JW, and unless modules; fix duplicate Dexter wavetables;…
Browse files Browse the repository at this point in the history
… fix MPEToCV debug output; add+use RACK_PLUGIN_UI_* macro calls
  • Loading branch information
bsp2 committed Jul 11, 2018
1 parent 5b0be5f commit a3dc2e5
Show file tree
Hide file tree
Showing 403 changed files with 270,435 additions and 304 deletions.
22 changes: 20 additions & 2 deletions README.md
Expand Up @@ -23,7 +23,7 @@ Tested in
# Downloads
The current release can be found in the [vst2_bin/](vst2_bin/) folder.

Here's a snapshot of it: [veeseevstrack_0_6_1_win64_bin-10Jul2018.7z](dist/veeseevstrack_0_6_1_win64_bin-10Jul2018.7z) (64bit)
Here's a snapshot of it: [veeseevstrack_0_6_1_win64_bin-11Jul2018.7z](dist/veeseevstrack_0_6_1_win64_bin-11Jul2018.7z) (64bit)

**WARNING: DON'T TRY TO USE THE INSTRUMENT AND EFFECT PLUGINS IN THE SAME PROJECT OR YOUR DAW WILL CRASH.**

Expand All @@ -41,7 +41,7 @@ Here's a demo video of it: https://vimeo.com/277703414

# Add-on modules

The following (441) add-on modules are statically linked with the VST plugin:
The following (459) add-on modules are statically linked with the VST plugin:
- Alikins.IdleSwitch
- Alikins.MomentaryOnButtons
- Alikins.BigMuteButton
Expand Down Expand Up @@ -210,6 +210,11 @@ The following (441) add-on modules are statically linked with the VST plugin:
- DHE-Modules.Stage
- DHE-Modules.Swave
- DHE-Modules.Upstage
- DrumKit.BD9
- DrumKit.Snare
- DrumKit.ClosedHH
- DrumKit.OpenHH
- DrumKit.DMX
- ESeries.E340
- ErraticInstruments.MPEToCV
- ErraticInstruments.QuadMPEToCV
Expand Down Expand Up @@ -286,6 +291,17 @@ The following (441) add-on modules are statically linked with the VST plugin:
- HetrickCV.Waveshape
- huaba.EQ3
- huaba.ABBus
- JW_Modules.Cat
- JW_Modules.BouncyBalls
- JW_Modules.FullScope
- JW_Modules.GridSeq
- JW_Modules.Quantizer
- JW_Modules.MinMax
- JW_Modules.NoteSeq
- JW_Modules.SimpleClock
- JW_Modules.ThingThing
- JW_Modules.WavHead
- JW_Modules.XYPad
- Koralfx.Beatovnik
- Koralfx.Mixovnik
- Koralfx.Nullovnik4
Expand Down Expand Up @@ -471,6 +487,8 @@ The following (441) add-on modules are statically linked with the VST plugin:
- trowaSoft.OscCV
- trowaSoft.MultiScope
- trowaSoft.MultiOscillator
- unless_modules.Piong
- unless_modules.Markov
- Valley.Topograph
- Valley.UGraph
- Valley.Dexter
Expand Down
41 changes: 41 additions & 0 deletions include/plugin.hpp
Expand Up @@ -136,13 +136,17 @@ You must implement this in your plugin
#define RACK_PLUGIN_INIT_ID_INTERNAL p->slug = TOSTRING(SLUG); p->version = TOSTRING(VERSION)

#ifdef USE_VST2

#define RACK_PLUGIN_DECLARE(pluginname)
#define RACK_PLUGIN_INIT(pluginname) extern "C" void init_plugin_##pluginname##(rack::Plugin *p)
#define RACK_PLUGIN_INIT_ID() RACK_PLUGIN_INIT_ID_INTERNAL

#else

#define RACK_PLUGIN_DECLARE(pluginname) extern Plugin *plugin
#define RACK_PLUGIN_INIT(pluginname) extern "C" RACK_PLUGIN_EXPORT void init(rack::Plugin *p)
#define RACK_PLUGIN_INIT_ID() plugin = p; RACK_PLUGIN_INIT_ID_INTERNAL

#endif // USE_VST2

#define RACK_PLUGIN_INIT_WEBSITE(url) p->website = url
Expand All @@ -151,3 +155,40 @@ You must implement this in your plugin
#define RACK_PLUGIN_MODEL_DECLARE(pluginname, modelname) extern Model *create_model_##pluginname##_##modelname##(void)
#define RACK_PLUGIN_MODEL_INIT(pluginname, modelname) Model *create_model_##pluginname##_##modelname##(void)
#define RACK_PLUGIN_MODEL_ADD(pluginname, modelname) p->addModel(create_model_##pluginname##_##modelname##())

// Access helpers for global UI vars
//
// (note) these avoid accessing the global rack vars directly
// (global TLS vars cannot be exported to dynamically loaded plugins)
//
// (note) please use the macros and do _not_ call the functions directly!
//
#include "global_pre.hpp"
#include "global_ui.hpp"

extern rack::RackScene *rack_plugin_ui_get_rackscene(void);
#define RACK_PLUGIN_UI_RACKSCENE rack_plugin_ui_get_rackscene()

extern rack::RackWidget *rack_plugin_ui_get_rackwidget(void);
#define RACK_PLUGIN_UI_RACKWIDGET rack_plugin_ui_get_rackwidget()

extern rack::Toolbar *rack_plugin_ui_get_toolbar(void);
#define RACK_PLUGIN_UI_TOOLBAR rack_plugin_ui_get_toolbar()

extern rack::Widget *rack_plugin_ui_get_hovered_widget(void);
#define RACK_PLUGIN_UI_HOVERED_WIDGET rack_plugin_ui_get_hovered_widget()

extern rack::Widget *rack_plugin_ui_get_dragged_widget(void);
#define RACK_PLUGIN_UI_DRAGGED_WIDGET rack_plugin_ui_get_dragged_widget()

extern void rack_plugin_ui_set_dragged_widget(rack::Widget *);
#define RACK_PLUGIN_UI_DRAGGED_WIDGET_SET(a) rack_plugin_ui_set_dragged_widget(a)

extern rack::Widget *rack_plugin_ui_get_draghovered_widget(void);
#define RACK_PLUGIN_UI_DRAGHOVERED_WIDGET rack_plugin_ui_get_draghovered_widget()

extern rack::Widget *rack_plugin_ui_get_focused_widget(void);
#define RACK_PLUGIN_UI_FOCUSED_WIDGET rack_plugin_ui_get_focused_widget()

extern void rack_plugin_ui_set_focused_widget(rack::Widget *);
#define RACK_PLUGIN_UI_FOCUSED_WIDGET_SET(a) rack_plugin_ui_set_focused_widget(a)
13 changes: 0 additions & 13 deletions plugins/build_plugin.mk

This file was deleted.

5 changes: 5 additions & 0 deletions plugins/build_plugin_msvc_pre.mk
@@ -0,0 +1,5 @@
EXTRAFLAGS+= -DARCH_WIN
EXTRAFLAGS+=

EXTRALIBS+=
# ../../Rack.lib -LIBPATH:../../dep/lib/msvc/ glew.lib glfw.lib opengl32.lib gdi32.lib user32.lib kernel32.lib Comdlg32.lib Shell32.lib
6 changes: 6 additions & 0 deletions plugins/build_plugin_post.mk
@@ -0,0 +1,6 @@

#ifdef ARCH_WIN
# (note) " data with thread storage duration may not have dll interface"
####include ../../dep/yac/sharedlib_msvc.mk
include ../../../../dep/yac/staticlib_msvc.mk
#endif
19 changes: 19 additions & 0 deletions plugins/build_plugin_pre.mk
@@ -0,0 +1,19 @@
# called from plugin directory (plugins/community/repos/<pluginname>/)
#
#include ../../../../arch.mk
#ifdef ARCH_WIN
include ../../../../dep/yac/install_msvc.mk
#endif

TARGET_BASENAME=$(SLUG)

EXTRAFLAGS+= -DVERSION=0.6.1 -D_USE_MATH_DEFINES -DUSE_VST2 -DRACK_PLUGIN -DSLUG=$(SLUG) -I../../../../include/ -I../../../../dep/include -Idep/include
EXTRAFLAGS+=

EXTRALIBS+=

PLAF_OBJ+=

#ifdef ARCH_WIN
include ../../../build_plugin_msvc_pre.mk
#endif
4 changes: 2 additions & 2 deletions plugins/community/repos/AS/makefile.msvc
@@ -1,7 +1,7 @@
SLUG=AS

include ../../../../dep/yac/install_msvc.mk
include ../../../build_plugin_pre.mk

include make.objects

include ../../../build_plugin.mk
include ../../../build_plugin_post.mk
4 changes: 2 additions & 2 deletions plugins/community/repos/Alikins/makefile.msvc
@@ -1,7 +1,7 @@
SLUG=Alikins

include ../../../../dep/yac/install_msvc.mk
include ../../../build_plugin_pre.mk

include make.objects

include ../../../build_plugin.mk
include ../../../build_plugin_post.mk
6 changes: 3 additions & 3 deletions plugins/community/repos/Alikins/src/ColorPanel.cpp
Expand Up @@ -110,15 +110,15 @@ struct ColorPanelModuleResizeHandle : Widget {
}

void onDragStart(EventDragStart &e) override {
dragX = rack::global_ui->app.gRackWidget->lastMousePos.x;
dragX = RACK_PLUGIN_UI_RACKWIDGET->lastMousePos.x;
ModuleWidget *m = getAncestorOfType<ModuleWidget>();
originalBox = m->box;
}

void onDragMove(EventDragMove &e) override {
ModuleWidget *m = getAncestorOfType<ModuleWidget>();

float newDragX = rack::global_ui->app.gRackWidget->lastMousePos.x;
float newDragX = RACK_PLUGIN_UI_RACKWIDGET->lastMousePos.x;
float deltaX = newDragX - dragX;

Rect newBox = originalBox;
Expand All @@ -135,7 +135,7 @@ struct ColorPanelModuleResizeHandle : Widget {
newBox.size.x = roundf(newBox.size.x / RACK_GRID_WIDTH) * RACK_GRID_WIDTH;
newBox.pos.x = originalBox.pos.x + originalBox.size.x - newBox.size.x;
}
rack::global_ui->app.gRackWidget->requestModuleBox(m, newBox);
RACK_PLUGIN_UI_RACKWIDGET->requestModuleBox(m, newBox);
}
};

Expand Down
12 changes: 6 additions & 6 deletions plugins/community/repos/Alikins/src/SpecificValue.cpp
Expand Up @@ -177,7 +177,7 @@ std::string FloatField::voltsToText(float param_volts){
void FloatField::onChange(EventChange &e) {
//debug("FloatField onChange text=%s param=%f", text.c_str(), module->params[SpecificValue::VALUE1_PARAM].value);

if (this != rack::global_ui->widgets.gFocusedWidget) {
if (this != RACK_PLUGIN_UI_FOCUSED_WIDGET) {
std::string new_text = voltsToText(module->params[SpecificValue::VALUE1_PARAM].value);
setText(new_text);
}
Expand Down Expand Up @@ -236,7 +236,7 @@ void HZFloatField::onChange(EventChange &e) {

//TextField::onChange(e);

if (this != rack::global_ui->widgets.gFocusedWidget)
if (this != RACK_PLUGIN_UI_FOCUSED_WIDGET)
{
std::string new_text = voltsToText(module->params[SpecificValue::VALUE1_PARAM].value);
setText(new_text);
Expand Down Expand Up @@ -292,7 +292,7 @@ void SecondsFloatField::onChange(EventChange &e) {

//TextField::onChange(e);

if (this != rack::global_ui->widgets.gFocusedWidget)
if (this != RACK_PLUGIN_UI_FOCUSED_WIDGET)
{
std::string new_text = voltsToText(module->params[SpecificValue::VALUE1_PARAM].value);
setText(new_text);
Expand Down Expand Up @@ -332,7 +332,7 @@ void CentsField::onChange(EventChange &e) {
module->params[SpecificValue::OCTAVE_PARAM].value);

// debug("CentsField onChange cents: %f", cents);
if (this != rack::global_ui->widgets.gFocusedWidget || fabs(cents) >= 0.50f)
if (this != RACK_PLUGIN_UI_FOCUSED_WIDGET || fabs(cents) >= 0.50f)
{
float cents = volts_to_note_cents(module->params[SpecificValue::VALUE1_PARAM].value,
module->params[SpecificValue::OCTAVE_PARAM].value);
Expand Down Expand Up @@ -379,7 +379,7 @@ void NoteNameField::onChange(EventChange &e) {

//TextField::onChange(e);

if (this != rack::global_ui->widgets.gFocusedWidget)
if (this != RACK_PLUGIN_UI_FOCUSED_WIDGET)
{
float cv_volts = module->params[SpecificValue::VALUE1_PARAM].value;
int octave = volts_to_octave(cv_volts, module->params[SpecificValue::OCTAVE_PARAM].value);
Expand Down Expand Up @@ -454,7 +454,7 @@ void PurpleTrimpot::step() {
// paramId, this->initialized, initialized, this->value, value, module->params[paramId].value);

if (this->value != module->params[paramId].value) {
if (this != rack::global_ui->widgets.gHoveredWidget && this->initialized) {
if (this != RACK_PLUGIN_UI_HOVERED_WIDGET && this->initialized) {
// this->value = module->params[paramId].value;
setValue(module->params[paramId].value);
} else {
Expand Down
5 changes: 2 additions & 3 deletions plugins/community/repos/AudibleInstruments/makefile.msvc
@@ -1,10 +1,9 @@

SLUG=AudibleInstruments

include ../../../../dep/yac/install_msvc.mk
include ../../../build_plugin_pre.mk

EXTRAFLAGS+= -Ieurorack/ -DTEST -Ieurorack/stmlib/third_party/STM -Ieurorack/stmlib/third_party/STM/STM32F0xx_StdPeriph_Driver/inc/

include make.objects

include ../../../build_plugin.mk
include ../../../build_plugin_post.mk
4 changes: 2 additions & 2 deletions plugins/community/repos/BaconMusic/makefile.msvc
@@ -1,9 +1,9 @@
SLUG=BaconMusic

include ../../../../dep/yac/install_msvc.mk
include ../../../build_plugin_pre.mk

EXTRAFLAGS+= -DBUILD_SORTACHORUS

include make.objects

include ../../../build_plugin.mk
include ../../../build_plugin_post.mk
4 changes: 2 additions & 2 deletions plugins/community/repos/Befaco/makefile.msvc
@@ -1,7 +1,7 @@
SLUG=Befaco

include ../../../../dep/yac/install_msvc.mk
include ../../../build_plugin_pre.mk

include make.objects

include ../../../build_plugin.mk
include ../../../build_plugin_post.mk
6 changes: 3 additions & 3 deletions plugins/community/repos/Bidoo/makefile.msvc
@@ -1,12 +1,12 @@
SLUG=Bidoo

include ../../../../dep/yac/install_msvc.mk
include ../../../build_plugin_pre.mk

EXTRAFLAGS=-DUSE_KISS_FFT -Idep/include -I./src/dep/audiofile -I./src/dep/filters -I./src/dep/freeverb \
EXTRAFLAGS+= -DUSE_KISS_FFT -Idep/include -I./src/dep/audiofile -I./src/dep/filters -I./src/dep/freeverb \
-I./src/dep/gist/libs/kiss_fft130 -I./src/dep/gist/src -I./src/dep/minimp3\
-I./src/dep/gist/src/mfcc -I./src/dep/gist/src/core -I./src/dep/gist/src/fft \
-I./src/dep/gist/src/onset-detection-functions -I./src/dep/gist/src/pitch

include make.objects

include ../../../build_plugin.mk
include ../../../build_plugin_post.mk
4 changes: 2 additions & 2 deletions plugins/community/repos/Bidoo/src/BORDL.cpp
Expand Up @@ -1274,14 +1274,14 @@ struct RandomizeMenuItem : MenuItem {
struct CloneMenuItem : MenuItem {
ModuleWidget *moduleWidget;
void onAction(EventAction &e) override {
rack::global_ui->app.gRackWidget->cloneModule(moduleWidget);
RACK_PLUGIN_UI_RACKWIDGET->cloneModule(moduleWidget);
}
};

struct DeleteMenuItem : MenuItem {
ModuleWidget *moduleWidget;
void onAction(EventAction &e) override {
rack::global_ui->app.gRackWidget->deleteModule(moduleWidget);
RACK_PLUGIN_UI_RACKWIDGET->deleteModule(moduleWidget);
moduleWidget->finalizeEvents();
delete moduleWidget;
}
Expand Down
8 changes: 4 additions & 4 deletions plugins/community/repos/Bidoo/src/CLACOS.cpp
Expand Up @@ -310,14 +310,14 @@ struct CLACOSDisplay : TransparentWidget {
CLACOSDisplay() {}

void onDragStart(EventDragStart &e) override {
dragX = rack::global_ui->app.gRackWidget->lastMousePos.x;
dragY = rack::global_ui->app.gRackWidget->lastMousePos.y;
dragX = RACK_PLUGIN_UI_RACKWIDGET->lastMousePos.x;
dragY = RACK_PLUGIN_UI_RACKWIDGET->lastMousePos.y;
}

void onDragMove(EventDragMove &e) override {
if ((!module->inputs[CLACOS::DIST_X_INPUT + segmentNumber].active) && (!module->inputs[CLACOS::DIST_X_INPUT + segmentNumber].active)) {
float newDragX = rack::global_ui->app.gRackWidget->lastMousePos.x;
float newDragY = rack::global_ui->app.gRackWidget->lastMousePos.y;
float newDragX = RACK_PLUGIN_UI_RACKWIDGET->lastMousePos.x;
float newDragY = RACK_PLUGIN_UI_RACKWIDGET->lastMousePos.y;
module->phaseDistX[segmentNumber] = rescale(clamp(initX+(newDragX-dragX),0.0f,70.0f), 0.0f, 70.0f, 0.01f,0.99f);
module->phaseDistY[segmentNumber] = rescale(clamp(initY-(newDragY-dragY),0.0f,70.0f), 0.0f, 70.0f, 0.01f,0.99f);
}
Expand Down
4 changes: 2 additions & 2 deletions plugins/community/repos/Bidoo/src/DTROY.cpp
Expand Up @@ -1057,14 +1057,14 @@ struct RandomizeMenuItem : MenuItem {
struct CloneMenuItem : MenuItem {
ModuleWidget *moduleWidget;
void onAction(EventAction &e) override {
rack::global_ui->app.gRackWidget->cloneModule(moduleWidget);
RACK_PLUGIN_UI_RACKWIDGET->cloneModule(moduleWidget);
}
};

struct DeleteMenuItem : MenuItem {
ModuleWidget *moduleWidget;
void onAction(EventAction &e) override {
rack::global_ui->app.gRackWidget->deleteModule(moduleWidget);
RACK_PLUGIN_UI_RACKWIDGET->deleteModule(moduleWidget);
moduleWidget->finalizeEvents();
delete moduleWidget;
}
Expand Down
8 changes: 4 additions & 4 deletions plugins/community/repos/Bidoo/src/TIARE.cpp
Expand Up @@ -286,14 +286,14 @@ struct TIAREDisplay : TransparentWidget {
TIAREDisplay() {}

void onDragStart(EventDragStart &e) override {
dragX = rack::global_ui->app.gRackWidget->lastMousePos.x;
dragY = rack::global_ui->app.gRackWidget->lastMousePos.y;
dragX = RACK_PLUGIN_UI_RACKWIDGET->lastMousePos.x;
dragY = RACK_PLUGIN_UI_RACKWIDGET->lastMousePos.y;
}

void onDragMove(EventDragMove &e) override {
if ((!module->inputs[TIARE::DIST_X_INPUT].active) && (!module->inputs[TIARE::DIST_X_INPUT].active)) {
float newDragX = rack::global_ui->app.gRackWidget->lastMousePos.x;
float newDragY = rack::global_ui->app.gRackWidget->lastMousePos.y;
float newDragX = RACK_PLUGIN_UI_RACKWIDGET->lastMousePos.x;
float newDragY = RACK_PLUGIN_UI_RACKWIDGET->lastMousePos.y;
module->phaseDistX = rescale(clamp(initX+(newDragX-dragX),0.0f,140.0f), 0.0f, 140.0f, 0.01f,0.98f);
module->phaseDistY = rescale(clamp(initY-(newDragY-dragY),0.0f,140.0f), 0.0f, 140.0f, 0.01f,1.0f);
}
Expand Down
4 changes: 2 additions & 2 deletions plugins/community/repos/Bogaudio/makefile.msvc
@@ -1,9 +1,9 @@
SLUG=Bogaudio

include ../../../../dep/yac/install_msvc.mk
include ../../../build_plugin_pre.mk

EXTRAFLAGS+= -Isrc/dsp/

include make.objects

include ../../../build_plugin.mk
include ../../../build_plugin_post.mk

0 comments on commit a3dc2e5

Please sign in to comment.