diff --git a/README.md b/README.md index 3f73f64..6171742 100644 --- a/README.md +++ b/README.md @@ -7,3 +7,6 @@ plus a nicer UI with a simple cat animation. 🐈 ## Screenshot ![Nekobi](https://raw.githubusercontent.com/DISTRHO/nekobi/master/plugins/Nekobi/Screenshot.png "Nekobi")
+ +## Building +Don't forget to do `git submodule update --init --recursive` to pull in dependencies diff --git a/plugins/Nekobi/DistrhoPluginInfo.h b/plugins/Nekobi/DistrhoPluginInfo.h index 3b11bb9..016f621 100644 --- a/plugins/Nekobi/DistrhoPluginInfo.h +++ b/plugins/Nekobi/DistrhoPluginInfo.h @@ -1,5 +1,6 @@ /* - * DISTRHO Nekobi Plugin, based on Nekobee by Sean Bolton and others. + * DISTRHO Nekobi Plugin, based on Nekobee by Gordon JC Pearce + * using code originally by Sean Bolton and others. * Copyright (C) 2013-2022 Filipe Coelho * * This program is free software; you can redistribute it and/or @@ -21,9 +22,9 @@ #include "DistrhoArtworkNekobi.hpp" #define DISTRHO_PLUGIN_BRAND "DISTRHO" -#define DISTRHO_PLUGIN_NAME "Nekobi" -#define DISTRHO_PLUGIN_URI "http://distrho.sf.net/plugins/Nekobi" -#define DISTRHO_PLUGIN_CLAP_ID "studio.kx.distrho.Nekobi" +#define DISTRHO_PLUGIN_NAME "Nekobi-v8" +#define DISTRHO_PLUGIN_URI "http://distrho.sf.net/plugins/Nekobi-v8" +#define DISTRHO_PLUGIN_CLAP_ID "studio.kx.distrho.Nekobi-v8" #define DISTRHO_PLUGIN_HAS_UI 1 #define DISTRHO_PLUGIN_IS_RT_SAFE 1 diff --git a/plugins/Nekobi/DistrhoPluginNekobi.cpp b/plugins/Nekobi/DistrhoPluginNekobi.cpp index ca73cde..d224eb2 100644 --- a/plugins/Nekobi/DistrhoPluginNekobi.cpp +++ b/plugins/Nekobi/DistrhoPluginNekobi.cpp @@ -24,33 +24,6 @@ #include "nekobee-src/nekobee_voice_render.c" #include "nekobee-src/minblep_tables.c" -// ----------------------------------------------------------------------- -// mutual exclusion - -bool dssp_voicelist_mutex_trylock(nekobee_synth_t* const synth) -{ - /* Attempt the mutex lock */ - if (!synth->voicelist_mutex.try_lock()) - { - synth->voicelist_mutex_grab_failed = 1; - return false; - } - - /* Clean up if a previous mutex grab failed */ - if (synth->voicelist_mutex_grab_failed) - { - nekobee_synth_all_voices_off(synth); - synth->voicelist_mutex_grab_failed = 0; - } - - return true; -} - -void dssp_voicelist_mutex_unlock(nekobee_synth_t* const synth) -{ - synth->voicelist_mutex.unlock(); -} - // ----------------------------------------------------------------------- // nekobee_handle_raw_event @@ -106,7 +79,6 @@ DistrhoPluginNekobi::DistrhoPluginNekobi() fSynth.held_keys[i] = -1; fSynth.voice = nekobee_voice_new(); - fSynth.voicelist_mutex_grab_failed = 0; fSynth.channel_pressure = 0; fSynth.pitch_wheel_sensitivity = 0; @@ -358,7 +330,7 @@ void DistrhoPluginNekobi::run(const float**, float** outputs, uint32_t frames, c float* out = outputs[0]; - if (fSynth.voice == nullptr || ! dssp_voicelist_mutex_trylock(&fSynth)) + if (fSynth.voice == nullptr) { std::memset(out, 0, sizeof(float)*frames); return; @@ -404,8 +376,6 @@ void DistrhoPluginNekobi::run(const float**, float** outputs, uint32_t frames, c framesDone += burstSize; fSynth.nugget_remains -= burstSize; } - - dssp_voicelist_mutex_unlock(&fSynth); } // ----------------------------------------------------------------------- diff --git a/plugins/Nekobi/DistrhoPluginNekobi.hpp b/plugins/Nekobi/DistrhoPluginNekobi.hpp index 19621a1..4cb2566 100644 --- a/plugins/Nekobi/DistrhoPluginNekobi.hpp +++ b/plugins/Nekobi/DistrhoPluginNekobi.hpp @@ -1,6 +1,8 @@ /* - * DISTRHO Nekobi Plugin, based on Nekobee by Sean Bolton and others. + * DISTRHO Nekobi Plugin, based on Nekobee by Gordonjcp + * using code originally by Sean Bolton and others. * Copyright (C) 2004 Sean Bolton and others + * Copyright (C) 2005 Gordonjcp * Copyright (C) 2013-2022 Filipe Coelho * * This program is free software; you can redistribute it and/or @@ -52,7 +54,7 @@ protected: const char* getLabel() const noexcept override { - return "Nekobi"; + return "Nekobi-v8"; } const char* getDescription() const override @@ -62,12 +64,12 @@ protected: const char* getMaker() const noexcept override { - return "Sean Bolton, falkTX"; + return "Gordon JC Pearce, falkTX"; } const char* getHomePage() const override { - return "https://github.com/DISTRHO/Nekobi"; + return "https://gjcp.net/plugins/Nekobi-v8"; } const char* getLicense() const noexcept override @@ -82,7 +84,7 @@ protected: int64_t getUniqueId() const noexcept override { - return d_cconst('D', 'N', 'e', 'k'); + return d_cconst('D', 'N', 'e', '8'); } // ------------------------------------------------------------------- diff --git a/plugins/Nekobi/nekobee-src/nekobee_synth.c b/plugins/Nekobi/nekobee-src/nekobee_synth.c index a021151..90f14ce 100644 --- a/plugins/Nekobi/nekobee-src/nekobee_synth.c +++ b/plugins/Nekobi/nekobee-src/nekobee_synth.c @@ -29,7 +29,6 @@ #include #include #include -#include #include "nekobee.h" #include "nekobee_synth.h" diff --git a/plugins/Nekobi/nekobee-src/nekobee_synth.h b/plugins/Nekobi/nekobee-src/nekobee_synth.h index aa2e72b..66479b2 100644 --- a/plugins/Nekobi/nekobee-src/nekobee_synth.h +++ b/plugins/Nekobi/nekobee-src/nekobee_synth.h @@ -26,8 +26,6 @@ #ifndef _XSYNTH_SYNTH_H #define _XSYNTH_SYNTH_H -#include - #include "nekobee.h" #include "nekobee_types.h" @@ -64,8 +62,6 @@ struct _nekobee_synth_t { //nekobee_voice_t *voice[XSYNTH_MAX_POLYPHONY]; nekobee_voice_t *voice; - std::mutex voicelist_mutex; - int voicelist_mutex_grab_failed; /* current non-paramter-mapped controller values */ unsigned char key_pressure[128];