@@ -599,11 +599,8 @@ public: | |||||
void reload() override | void reload() override | ||||
{ | { | ||||
CARLA_SAFE_ASSERT_RETURN(pData->engine != nullptr,); | |||||
carla_debug("BridgePlugin::reload() - start"); | carla_debug("BridgePlugin::reload() - start"); | ||||
CARLA_ASSERT(pData->engine != nullptr); | |||||
if (pData->engine == nullptr) | |||||
return; | |||||
const ProcessMode processMode(pData->engine->getProccessMode()); | const ProcessMode processMode(pData->engine->getProccessMode()); | ||||
@@ -58,11 +58,17 @@ public: | |||||
void reload() override | void reload() override | ||||
{ | { | ||||
CARLA_SAFE_ASSERT_RETURN(pData->engine != nullptr,); | |||||
carla_debug("CsoundPlugin::reload() - start"); | |||||
bufferSizeChanged(pData->engine->getBufferSize()); | |||||
reloadPrograms(true); | |||||
carla_debug("CsoundPlugin::reload() - end"); | |||||
} | } | ||||
void process(float** const inBuffer, float** const outBuffer, const uint32_t frames) override | void process(float** const inBuffer, float** const outBuffer, const uint32_t frames) override | ||||
{ | { | ||||
} | } | ||||
private: | private: | ||||
@@ -382,11 +382,11 @@ public: | |||||
void reload() override | void reload() override | ||||
{ | { | ||||
carla_debug("DssiPlugin::reload() - start"); | |||||
CARLA_SAFE_ASSERT_RETURN(pData->engine != nullptr,); | CARLA_SAFE_ASSERT_RETURN(pData->engine != nullptr,); | ||||
CARLA_SAFE_ASSERT_RETURN(fDescriptor != nullptr,); | CARLA_SAFE_ASSERT_RETURN(fDescriptor != nullptr,); | ||||
CARLA_SAFE_ASSERT_RETURN(fDssiDescriptor != nullptr,); | CARLA_SAFE_ASSERT_RETURN(fDssiDescriptor != nullptr,); | ||||
CARLA_SAFE_ASSERT_RETURN(fHandle != nullptr,); | CARLA_SAFE_ASSERT_RETURN(fHandle != nullptr,); | ||||
carla_debug("DssiPlugin::reload() - start"); | |||||
const ProcessMode processMode(pData->engine->getProccessMode()); | const ProcessMode processMode(pData->engine->getProccessMode()); | ||||
@@ -510,14 +510,9 @@ public: | |||||
void reload() override | void reload() override | ||||
{ | { | ||||
CARLA_SAFE_ASSERT_RETURN(pData->engine != nullptr,); | |||||
CARLA_SAFE_ASSERT_RETURN(fSynth != nullptr,); | |||||
carla_debug("FluidSynthPlugin::reload() - start"); | carla_debug("FluidSynthPlugin::reload() - start"); | ||||
CARLA_ASSERT(pData->engine != nullptr); | |||||
CARLA_ASSERT(fSynth != nullptr); | |||||
if (pData->engine == nullptr) | |||||
return; | |||||
if (fSynth == nullptr) | |||||
return; | |||||
const ProcessMode processMode(pData->engine->getProccessMode()); | const ProcessMode processMode(pData->engine->getProccessMode()); | ||||
@@ -392,10 +392,10 @@ public: | |||||
void reload() override | void reload() override | ||||
{ | { | ||||
carla_debug("LadspaPlugin::reload() - start"); | |||||
CARLA_SAFE_ASSERT_RETURN(pData->engine != nullptr,); | CARLA_SAFE_ASSERT_RETURN(pData->engine != nullptr,); | ||||
CARLA_SAFE_ASSERT_RETURN(fDescriptor != nullptr,); | CARLA_SAFE_ASSERT_RETURN(fDescriptor != nullptr,); | ||||
CARLA_SAFE_ASSERT_RETURN(fHandle != nullptr,); | CARLA_SAFE_ASSERT_RETURN(fHandle != nullptr,); | ||||
carla_debug("LadspaPlugin::reload() - start"); | |||||
const ProcessMode processMode(pData->engine->getProccessMode()); | const ProcessMode processMode(pData->engine->getProccessMode()); | ||||
@@ -336,14 +336,9 @@ public: | |||||
void reload() override | void reload() override | ||||
{ | { | ||||
CARLA_SAFE_ASSERT_RETURN(pData->engine != nullptr,); | |||||
CARLA_SAFE_ASSERT_RETURN(fInstrument != nullptr,); | |||||
carla_debug("LinuxSamplerPlugin::reload() - start"); | carla_debug("LinuxSamplerPlugin::reload() - start"); | ||||
CARLA_ASSERT(pData->engine != nullptr); | |||||
CARLA_ASSERT(fInstrument != nullptr); | |||||
if (pData->engine == nullptr) | |||||
return; | |||||
if (fInstrument == nullptr) | |||||
return; | |||||
const ProcessMode processMode(pData->engine->getProccessMode()); | const ProcessMode processMode(pData->engine->getProccessMode()); | ||||
@@ -1283,20 +1283,11 @@ public: | |||||
void reload() override | void reload() override | ||||
{ | { | ||||
CARLA_SAFE_ASSERT_RETURN(pData->engine != nullptr,); | |||||
CARLA_SAFE_ASSERT_RETURN(fHandle != nullptr,); | |||||
CARLA_SAFE_ASSERT_RETURN(fDescriptor != nullptr,); | |||||
CARLA_SAFE_ASSERT_RETURN(fRdfDescriptor != nullptr,); | |||||
carla_debug("Lv2Plugin::reload() - start"); | carla_debug("Lv2Plugin::reload() - start"); | ||||
CARLA_ASSERT(pData->engine != nullptr); | |||||
CARLA_ASSERT(fHandle != nullptr); | |||||
CARLA_ASSERT(fDescriptor != nullptr); | |||||
CARLA_ASSERT(fRdfDescriptor != nullptr); | |||||
if (pData->engine == nullptr) | |||||
return; | |||||
if (fHandle == nullptr) | |||||
return; | |||||
if (fDescriptor == nullptr) | |||||
return; | |||||
if (fRdfDescriptor == nullptr) | |||||
return; | |||||
const ProcessMode processMode(pData->engine->getProccessMode()); | const ProcessMode processMode(pData->engine->getProccessMode()); | ||||
@@ -602,16 +602,10 @@ public: | |||||
{ | { | ||||
CARLA_SAFE_ASSERT_RETURN(fDescriptor != nullptr,); | CARLA_SAFE_ASSERT_RETURN(fDescriptor != nullptr,); | ||||
CARLA_SAFE_ASSERT_RETURN(fHandle != nullptr,); | CARLA_SAFE_ASSERT_RETURN(fHandle != nullptr,); | ||||
CARLA_ASSERT(index >= -1 && index < static_cast<int32_t>(pData->midiprog.count)); | |||||
CARLA_SAFE_ASSERT_RETURN(index >= -1 && index < static_cast<int32_t>(pData->midiprog.count),); | |||||
if (index < -1) | |||||
index = -1; | |||||
else if (index > static_cast<int32_t>(pData->midiprog.count)) | |||||
return; | |||||
// TODO | |||||
//if ((fHints & PLUGIN_IS_SYNTH) != 0 && (pData->ctrlChannel < 0 || pData->ctrlChannel >= MAX_MIDI_CHANNELS)) | |||||
// return; | |||||
if ((fHints & PLUGIN_IS_SYNTH) != 0 && (pData->ctrlChannel < 0 || pData->ctrlChannel >= MAX_MIDI_CHANNELS)) | |||||
return; | |||||
if (index >= 0) | if (index >= 0) | ||||
{ | { | ||||
@@ -691,10 +685,10 @@ public: | |||||
void reload() override | void reload() override | ||||
{ | { | ||||
carla_debug("NativePlugin::reload() - start"); | |||||
CARLA_SAFE_ASSERT_RETURN(pData->engine != nullptr,); | CARLA_SAFE_ASSERT_RETURN(pData->engine != nullptr,); | ||||
CARLA_SAFE_ASSERT_RETURN(fDescriptor != nullptr,); | CARLA_SAFE_ASSERT_RETURN(fDescriptor != nullptr,); | ||||
CARLA_SAFE_ASSERT_RETURN(fHandle != nullptr,); | CARLA_SAFE_ASSERT_RETURN(fHandle != nullptr,); | ||||
carla_debug("NativePlugin::reload() - start"); | |||||
const ProcessMode processMode(pData->engine->getProccessMode()); | const ProcessMode processMode(pData->engine->getProccessMode()); | ||||
@@ -494,14 +494,9 @@ public: | |||||
void reload() override | void reload() override | ||||
{ | { | ||||
CARLA_SAFE_ASSERT_RETURN(pData->engine != nullptr,); | |||||
CARLA_SAFE_ASSERT_RETURN(fEffect != nullptr,); | |||||
carla_debug("VstPlugin::reload() - start"); | carla_debug("VstPlugin::reload() - start"); | ||||
CARLA_ASSERT(pData->engine != nullptr); | |||||
CARLA_ASSERT(fEffect != nullptr); | |||||
if (pData->engine == nullptr) | |||||
return; | |||||
if (fEffect == nullptr) | |||||
return; | |||||
const ProcessMode processMode(pData->engine->getProccessMode()); | const ProcessMode processMode(pData->engine->getProccessMode()); | ||||
@@ -891,7 +891,7 @@ protected: | |||||
case 89: | case 89: | ||||
hints |= PARAMETER_IS_BOOLEAN; | hints |= PARAMETER_IS_BOOLEAN; | ||||
paramInfo.name = "Wave1 on/off"; | paramInfo.name = "Wave1 on/off"; | ||||
paramInfo.ranges.def = 0.1f; | |||||
paramInfo.ranges.def = 1.0f; | |||||
break; | break; | ||||
case 90: | case 90: | ||||
hints |= PARAMETER_IS_BOOLEAN; | hints |= PARAMETER_IS_BOOLEAN; | ||||