Browse Source

Fix build

tags/1.9.4
falkTX 11 years ago
parent
commit
eed21889a0
7 changed files with 52 additions and 35 deletions
  1. +10
    -10
      source/backend/engine/CarlaEngine.cpp
  2. +1
    -1
      source/backend/engine/CarlaEngineOsc.cpp
  3. +1
    -1
      source/backend/plugin/BridgePlugin.cpp
  4. +12
    -2
      source/backend/plugin/VstPlugin.cpp
  5. +20
    -20
      source/backend/standalone/CarlaStandalone.cpp
  6. +1
    -1
      source/utils/CarlaStateUtils.hpp
  7. +7
    -0
      source/utils/CarlaUtils.hpp

+ 10
- 10
source/backend/engine/CarlaEngine.cpp View File

@@ -1291,37 +1291,37 @@ void CarlaEngine::setOption(const OptionsType option, const int value, const cha

#ifdef WANT_LV2
case OPTION_PATH_BRIDGE_LV2_GTK2:
fOptions.bridge_lv2gtk2 = valueStr;
fOptions.bridge_lv2Gtk2 = valueStr;
break;
case OPTION_PATH_BRIDGE_LV2_GTK3:
fOptions.bridge_lv2gtk3 = valueStr;
fOptions.bridge_lv2Gtk3 = valueStr;
break;
case OPTION_PATH_BRIDGE_LV2_QT4:
fOptions.bridge_lv2qt4 = valueStr;
fOptions.bridge_lv2Qt4 = valueStr;
break;
case OPTION_PATH_BRIDGE_LV2_QT5:
fOptions.bridge_lv2qt5 = valueStr;
fOptions.bridge_lv2Qt5 = valueStr;
break;
case OPTION_PATH_BRIDGE_LV2_COCOA:
fOptions.bridge_lv2cocoa = valueStr;
fOptions.bridge_lv2Cocoa = valueStr;
break;
case OPTION_PATH_BRIDGE_LV2_WINDOWS:
fOptions.bridge_lv2win = valueStr;
fOptions.bridge_lv2Win = valueStr;
break;
case OPTION_PATH_BRIDGE_LV2_X11:
fOptions.bridge_lv2x11 = valueStr;
fOptions.bridge_lv2X11 = valueStr;
break;
#endif

#ifdef WANT_VST
case OPTION_PATH_BRIDGE_VST_COCOA:
fOptions.bridge_vstcocoa = valueStr;
fOptions.bridge_vstCocoa = valueStr;
break;
case OPTION_PATH_BRIDGE_VST_HWND:
fOptions.bridge_vsthwnd = valueStr;
fOptions.bridge_vstHWND = valueStr;
break;
case OPTION_PATH_BRIDGE_VST_X11:
fOptions.bridge_vstx11 = valueStr;
fOptions.bridge_vstX11 = valueStr;
break;
#endif
}


+ 1
- 1
source/backend/engine/CarlaEngineOsc.cpp View File

@@ -22,7 +22,7 @@
#include "CarlaMIDI.h"

#ifndef BUILD_BRIDGE
# include "CarlaBridge.hpp"
# include "CarlaBridgeUtils.hpp"
#endif

CARLA_BACKEND_START_NAMESPACE


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

@@ -19,7 +19,7 @@

#ifndef BUILD_BRIDGE

#include "CarlaBridge.hpp"
#include "CarlaBridgeUtils.hpp"
#include "CarlaShmUtils.hpp"

#include <cerrno>


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

@@ -2180,9 +2180,19 @@ public:
{
const EngineOptions& engineOptions(kData->engine->getOptions());

if (engineOptions.preferUiBridges && engineOptions.bridge_vstx11.isNotEmpty() && (fEffect->flags & effFlagsProgramChunks) == 0)
#ifdef Q_WS_X11
CarlaString uiBridgeBinary(engineOptions.bridge_vstX11);
#elif CARLA_OS_MAC
CarlaString uiBridgeBinary(engineOptions.bridge_vstCocoa);
#elif CARLA_OS_WIN
CarlaString uiBridgeBinary(engineOptions.bridge_vstHWND);
#else
CarlaString uiBridgeBinary;
#endif

if (engineOptions.preferUiBridges && uiBridgeBinary.isNotEmpty() && (fEffect->flags & effFlagsProgramChunks) == 0)
{
kData->osc.thread.setOscData(engineOptions.bridge_vstx11, nullptr);
kData->osc.thread.setOscData(uiBridgeBinary, nullptr);
fGui.isOsc = true;
}
}


+ 20
- 20
source/backend/standalone/CarlaStandalone.cpp View File

@@ -265,18 +265,18 @@ bool carla_engine_init(const char* driverName, const char* clientName)
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_WIN32, 0, standalone.options.bridge_win32);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_WIN64, 0, standalone.options.bridge_win64);
# ifdef WANT_LV2
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_GTK2, 0, standalone.options.bridge_lv2gtk2);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_GTK3, 0, standalone.options.bridge_lv2gtk3);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_QT4, 0, standalone.options.bridge_lv2qt4);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_QT5, 0, standalone.options.bridge_lv2qt5);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_COCOA, 0, standalone.options.bridge_lv2cocoa);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_WINDOWS, 0, standalone.options.bridge_lv2win);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_X11, 0, standalone.options.bridge_lv2qt4);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_GTK2, 0, standalone.options.bridge_lv2Gtk2);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_GTK3, 0, standalone.options.bridge_lv2Gtk3);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_QT4, 0, standalone.options.bridge_lv2Qt4);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_QT5, 0, standalone.options.bridge_lv2Qt5);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_COCOA, 0, standalone.options.bridge_lv2Cocoa);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_WINDOWS, 0, standalone.options.bridge_lv2Win);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_LV2_X11, 0, standalone.options.bridge_lv2X11);
# endif
# ifdef WANT_VST
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_VST_COCOA, 0, standalone.options.bridge_vstcocoa);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_VST_HWND, 0, standalone.options.bridge_vsthwnd);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_VST_X11, 0, standalone.options.bridge_vstx11);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_VST_COCOA, 0, standalone.options.bridge_vstCocoa);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_VST_HWND, 0, standalone.options.bridge_vstHWND);
standalone.engine->setOption(CarlaBackend::OPTION_PATH_BRIDGE_VST_X11, 0, standalone.options.bridge_vstX11);
# endif

if (standalone.procName.isNotEmpty())
@@ -442,36 +442,36 @@ void carla_set_engine_option(CarlaBackend::OptionsType option, int value, const
#endif
#ifdef WANT_LV2
case CarlaBackend::OPTION_PATH_BRIDGE_LV2_GTK2:
standalone.options.bridge_lv2gtk2 = valueStr;
standalone.options.bridge_lv2Gtk2 = valueStr;
break;
case CarlaBackend::OPTION_PATH_BRIDGE_LV2_GTK3:
standalone.options.bridge_lv2gtk3 = valueStr;
standalone.options.bridge_lv2Gtk3 = valueStr;
break;
case CarlaBackend::OPTION_PATH_BRIDGE_LV2_QT4:
standalone.options.bridge_lv2qt4 = valueStr;
standalone.options.bridge_lv2Qt4 = valueStr;
break;
case CarlaBackend::OPTION_PATH_BRIDGE_LV2_QT5:
standalone.options.bridge_lv2qt5 = valueStr;
standalone.options.bridge_lv2Qt5 = valueStr;
break;
case CarlaBackend::OPTION_PATH_BRIDGE_LV2_COCOA:
standalone.options.bridge_lv2cocoa = valueStr;
standalone.options.bridge_lv2Cocoa = valueStr;
break;
case CarlaBackend::OPTION_PATH_BRIDGE_LV2_WINDOWS:
standalone.options.bridge_lv2win = valueStr;
standalone.options.bridge_lv2Win = valueStr;
break;
case CarlaBackend::OPTION_PATH_BRIDGE_LV2_X11:
standalone.options.bridge_lv2x11 = valueStr;
standalone.options.bridge_lv2X11 = valueStr;
break;
#endif
#ifdef WANT_VST
case CarlaBackend::OPTION_PATH_BRIDGE_VST_COCOA:
standalone.options.bridge_vstcocoa = valueStr;
standalone.options.bridge_vstCocoa = valueStr;
break;
case CarlaBackend::OPTION_PATH_BRIDGE_VST_HWND:
standalone.options.bridge_vsthwnd = valueStr;
standalone.options.bridge_vstHWND = valueStr;
break;
case CarlaBackend::OPTION_PATH_BRIDGE_VST_X11:
standalone.options.bridge_vstx11 = valueStr;
standalone.options.bridge_vstX11 = valueStr;
break;
#endif
}


+ 1
- 1
source/utils/CarlaStateUtils.hpp View File

@@ -535,7 +535,7 @@ const QString& getXMLFromSaveState(const SaveState& saveState)

parameter += QString(" <Value>%1</Value>\n").arg(stateParameter->value);

if (stateParameter->midiCC > 0 && stateParameter->midiChannel >= 0)
if (stateParameter->midiCC > 0)
{
parameter += QString(" <MidiCC>%1</MidiCC>\n").arg(stateParameter->midiCC);
parameter += QString(" <MidiChannel>%1</MidiChannel>\n").arg(stateParameter->midiChannel+1);


+ 7
- 0
source/utils/CarlaUtils.hpp View File

@@ -361,6 +361,13 @@ void carla_zeroStruct(T& structure, const size_t count)
std::memset(&structure, 0, sizeof(T)*count);
}

template <typename T>
static inline
void carla_zeroStruct(T* const structure, const size_t count)
{
std::memset(structure, 0, sizeof(T)*count);
}

// -------------------------------------------------

#endif // __CARLA_UTILS_HPP__

Loading…
Cancel
Save