From 3543b80f3a1468f28bd1e5a1bee1a64ae54817c7 Mon Sep 17 00:00:00 2001 From: xenakios Date: Fri, 16 Mar 2018 18:40:59 +0200 Subject: [PATCH] Initialize the module enabled parameters manually. Remove section from the constructor that made VS intellisense not work. --- Source/PluginProcessor.cpp | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/Source/PluginProcessor.cpp b/Source/PluginProcessor.cpp index f9182dd..d9162ec 100644 --- a/Source/PluginProcessor.cpp +++ b/Source/PluginProcessor.cpp @@ -66,16 +66,6 @@ inline AudioParameterFloat* make_floatpar(String id, String name, float minv, fl //============================================================================== PaulstretchpluginAudioProcessor::PaulstretchpluginAudioProcessor() : m_bufferingthread("pspluginprebufferthread") -#ifndef JucePlugin_PreferredChannelConfigurations - : AudioProcessor (BusesProperties() - #if ! JucePlugin_IsMidiEffect - #if ! JucePlugin_IsSynth - .withInput ("Input", AudioChannelSet::stereo(), true) - #endif - .withOutput ("Output", AudioChannelSet::stereo(), true) - #endif - ) -#endif { g_activeprocessors.insert(this); @@ -93,10 +83,17 @@ PaulstretchpluginAudioProcessor::PaulstretchpluginAudioProcessor() m_thumb = std::make_unique(512, *m_afm, *m_thumbcache); // The default priority of 2 is a bit too low in some cases, it seems... m_thumbcache->getTimeSliceThread().setPriority(3); - for (int i = 0; i < 9; ++i) // 41-49 - { - m_sm_enab_pars[i] = new AudioParameterBool("enab_specmodule" + String(i), "Enable spectral module " + String(i + 1), false); - } + + m_sm_enab_pars[0] = new AudioParameterBool("enab_specmodule0", "Enable spectral module 1", false); + m_sm_enab_pars[1] = new AudioParameterBool("enab_specmodule1", "Enable spectral module 2", false); + m_sm_enab_pars[2] = new AudioParameterBool("enab_specmodule2", "Enable spectral module 3", true); + m_sm_enab_pars[3] = new AudioParameterBool("enab_specmodule3", "Enable spectral module 4", true); + m_sm_enab_pars[4] = new AudioParameterBool("enab_specmodule4", "Enable spectral module 5", false); + m_sm_enab_pars[5] = new AudioParameterBool("enab_specmodule5", "Enable spectral module 6", true); + m_sm_enab_pars[6] = new AudioParameterBool("enab_specmodule6", "Enable spectral module 7", true); + m_sm_enab_pars[7] = new AudioParameterBool("enab_specmodule7", "Enable spectral module 8", true); + m_sm_enab_pars[8] = new AudioParameterBool("enab_specmodule8", "Enable spectral module 9", false); + m_stretch_source = std::make_unique(2, m_afm,m_sm_enab_pars); m_stretch_source->setOnsetDetection(0.0);