Browse Source

Misc cleanup

tags/1.9.4
falkTX 11 years ago
parent
commit
e2aa9e3b42
10 changed files with 25 additions and 52 deletions
  1. +1
    -4
      source/backend/plugin/BridgePlugin.cpp
  2. +7
    -1
      source/backend/plugin/CsoundPlugin.cpp
  3. +1
    -1
      source/backend/plugin/DssiPlugin.cpp
  4. +2
    -7
      source/backend/plugin/FluidSynthPlugin.cpp
  5. +1
    -1
      source/backend/plugin/LadspaPlugin.cpp
  6. +2
    -7
      source/backend/plugin/LinuxSamplerPlugin.cpp
  7. +4
    -13
      source/backend/plugin/Lv2Plugin.cpp
  8. +4
    -10
      source/backend/plugin/NativePlugin.cpp
  9. +2
    -7
      source/backend/plugin/VstPlugin.cpp
  10. +1
    -1
      source/modules/carla_native/vex-synth.cpp

+ 1
- 4
source/backend/plugin/BridgePlugin.cpp View File

@@ -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());




+ 7
- 1
source/backend/plugin/CsoundPlugin.cpp View File

@@ -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:


+ 1
- 1
source/backend/plugin/DssiPlugin.cpp View File

@@ -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());




+ 2
- 7
source/backend/plugin/FluidSynthPlugin.cpp View File

@@ -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());




+ 1
- 1
source/backend/plugin/LadspaPlugin.cpp View File

@@ -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());




+ 2
- 7
source/backend/plugin/LinuxSamplerPlugin.cpp View File

@@ -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());




+ 4
- 13
source/backend/plugin/Lv2Plugin.cpp View File

@@ -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());




+ 4
- 10
source/backend/plugin/NativePlugin.cpp View File

@@ -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());




+ 2
- 7
source/backend/plugin/VstPlugin.cpp View File

@@ -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());




+ 1
- 1
source/modules/carla_native/vex-synth.cpp View File

@@ -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;


Loading…
Cancel
Save