@@ -260,7 +260,7 @@ bool CarlaEngineClient::removePort(const EnginePortType portType, const char* co | |||||
#ifndef BUILD_BRIDGE_ALTERNATIVE_ARCH | #ifndef BUILD_BRIDGE_ALTERNATIVE_ARCH | ||||
CarlaEngineCVSourcePorts* CarlaEngineClient::createCVSourcePorts() | CarlaEngineCVSourcePorts* CarlaEngineClient::createCVSourcePorts() | ||||
{ | { | ||||
pData->cvSourcePorts.setGraphAndPlugin(pData->egraph.getPatchbayGraph(), pData->plugin); | |||||
pData->cvSourcePorts.setGraphAndPlugin(pData->egraph.getPatchbayGraphOrNull(), pData->plugin); | |||||
return &pData->cvSourcePorts; | return &pData->cvSourcePorts; | ||||
} | } | ||||
#endif | #endif | ||||
@@ -81,9 +81,9 @@ public: | |||||
} | } | ||||
protected: | protected: | ||||
inline PatchbayGraph* getPatchbayGraph() const noexcept | |||||
inline PatchbayGraph* getPatchbayGraphOrNull() const noexcept | |||||
{ | { | ||||
return pData->egraph.getPatchbayGraph(); | |||||
return pData->egraph.getPatchbayGraphOrNull(); | |||||
} | } | ||||
inline CarlaPlugin* getPlugin() const noexcept | inline CarlaPlugin* getPlugin() const noexcept | ||||
@@ -2490,6 +2490,11 @@ PatchbayGraph* EngineInternalGraph::getPatchbayGraph() const noexcept | |||||
return fPatchbay; | return fPatchbay; | ||||
} | } | ||||
PatchbayGraph* EngineInternalGraph::getPatchbayGraphOrNull() const noexcept | |||||
{ | |||||
return fIsRack ? nullptr : fPatchbay; | |||||
} | |||||
void EngineInternalGraph::process(CarlaEngine::ProtectedData* const data, const float* const* const inBuf, float* const* const outBuf, const uint32_t frames) | void EngineInternalGraph::process(CarlaEngine::ProtectedData* const data, const float* const* const inBuf, float* const* const outBuf, const uint32_t frames) | ||||
{ | { | ||||
if (fIsRack) | if (fIsRack) | ||||
@@ -88,6 +88,7 @@ public: | |||||
RackGraph* getRackGraph() const noexcept; | RackGraph* getRackGraph() const noexcept; | ||||
PatchbayGraph* getPatchbayGraph() const noexcept; | PatchbayGraph* getPatchbayGraph() const noexcept; | ||||
PatchbayGraph* getPatchbayGraphOrNull() const noexcept; | |||||
void process(CarlaEngine::ProtectedData* data, const float* const* inBuf, float* const* outBuf, uint32_t frames); | void process(CarlaEngine::ProtectedData* data, const float* const* inBuf, float* const* outBuf, uint32_t frames); | ||||
@@ -885,7 +885,7 @@ public: | |||||
#ifndef BUILD_BRIDGE_ALTERNATIVE_ARCH | #ifndef BUILD_BRIDGE_ALTERNATIVE_ARCH | ||||
CarlaEngineCVSourcePorts* createCVSourcePorts() override | CarlaEngineCVSourcePorts* createCVSourcePorts() override | ||||
{ | { | ||||
fCVSourcePorts.setGraphAndPlugin(getPatchbayGraph(), getPlugin()); | |||||
fCVSourcePorts.setGraphAndPlugin(getPatchbayGraphOrNull(), getPlugin()); | |||||
return &fCVSourcePorts; | return &fCVSourcePorts; | ||||
} | } | ||||