| @@ -246,119 +246,126 @@ enum OptionsType { | |||||
| */ | */ | ||||
| OPTION_USE_DSSI_VST_CHUNKS = 7, | OPTION_USE_DSSI_VST_CHUNKS = 7, | ||||
| /*! | |||||
| * Use plugin bridges whenever possible.\n | |||||
| * Default is no, and not recommended at this point!. | |||||
| * EXPERIMENTAL! | |||||
| */ | |||||
| OPTION_PREFER_PLUGIN_BRIDGES = 8, | |||||
| /*! | /*! | ||||
| * Use OSC-UI bridges whenever possible, otherwise UIs will be handled in the main thread.\n | * Use OSC-UI bridges whenever possible, otherwise UIs will be handled in the main thread.\n | ||||
| * Default is yes. | * Default is yes. | ||||
| */ | */ | ||||
| OPTION_PREFER_UI_BRIDGES = 8, | |||||
| OPTION_PREFER_UI_BRIDGES = 9, | |||||
| /*! | /*! | ||||
| * Timeout value in ms for how much to wait for OSC-UIs to respond.\n | * Timeout value in ms for how much to wait for OSC-UIs to respond.\n | ||||
| * Default is 4000 ms (4 secs). | * Default is 4000 ms (4 secs). | ||||
| */ | */ | ||||
| OPTION_OSC_UI_TIMEOUT = 9, | |||||
| OPTION_OSC_UI_TIMEOUT = 10, | |||||
| /*! | /*! | ||||
| * Set LADSPA_PATH environment variable.\n | * Set LADSPA_PATH environment variable.\n | ||||
| * Default undefined. | * Default undefined. | ||||
| */ | */ | ||||
| OPTION_PATH_LADSPA = 10, | |||||
| OPTION_PATH_LADSPA = 11, | |||||
| /*! | /*! | ||||
| * Set DSSI_PATH environment variable.\n | * Set DSSI_PATH environment variable.\n | ||||
| * Default undefined. | * Default undefined. | ||||
| */ | */ | ||||
| OPTION_PATH_DSSI = 11, | |||||
| OPTION_PATH_DSSI = 12, | |||||
| /*! | /*! | ||||
| * Set LV2_PATH environment variable.\n | * Set LV2_PATH environment variable.\n | ||||
| * Default undefined. | * Default undefined. | ||||
| */ | */ | ||||
| OPTION_PATH_LV2 = 12, | |||||
| OPTION_PATH_LV2 = 13, | |||||
| /*! | /*! | ||||
| * Set VST_PATH environment variable.\n | * Set VST_PATH environment variable.\n | ||||
| * Default undefined. | * Default undefined. | ||||
| */ | */ | ||||
| OPTION_PATH_VST = 13, | |||||
| OPTION_PATH_VST = 14, | |||||
| /*! | /*! | ||||
| * Set GIG_PATH environment variable.\n | * Set GIG_PATH environment variable.\n | ||||
| * Default undefined. | * Default undefined. | ||||
| */ | */ | ||||
| OPTION_PATH_GIG = 14, | |||||
| OPTION_PATH_GIG = 15, | |||||
| /*! | /*! | ||||
| * Set SF2_PATH environment variable.\n | * Set SF2_PATH environment variable.\n | ||||
| * Default undefined. | * Default undefined. | ||||
| */ | */ | ||||
| OPTION_PATH_SF2 = 15, | |||||
| OPTION_PATH_SF2 = 16, | |||||
| /*! | /*! | ||||
| * Set SFZ_PATH environment variable.\n | * Set SFZ_PATH environment variable.\n | ||||
| * Default undefined. | * Default undefined. | ||||
| */ | */ | ||||
| OPTION_PATH_SFZ = 16, | |||||
| OPTION_PATH_SFZ = 17, | |||||
| /*! | /*! | ||||
| * Set path to the POSIX 32bit plugin bridge executable.\n | * Set path to the POSIX 32bit plugin bridge executable.\n | ||||
| * Default unset. | * Default unset. | ||||
| */ | */ | ||||
| OPTION_PATH_BRIDGE_POSIX32 = 17, | |||||
| OPTION_PATH_BRIDGE_POSIX32 = 18, | |||||
| /*! | /*! | ||||
| * Set path to the POSIX 64bit plugin bridge executable.\n | * Set path to the POSIX 64bit plugin bridge executable.\n | ||||
| * Default unset. | * Default unset. | ||||
| */ | */ | ||||
| OPTION_PATH_BRIDGE_POSIX64 = 18, | |||||
| OPTION_PATH_BRIDGE_POSIX64 = 19, | |||||
| /*! | /*! | ||||
| * Set path to the Windows 32bit plugin bridge executable.\n | * Set path to the Windows 32bit plugin bridge executable.\n | ||||
| * Default unset. | * Default unset. | ||||
| */ | */ | ||||
| OPTION_PATH_BRIDGE_WIN32 = 19, | |||||
| OPTION_PATH_BRIDGE_WIN32 = 20, | |||||
| /*! | /*! | ||||
| * Set path to the Windows 64bit plugin bridge executable.\n | * Set path to the Windows 64bit plugin bridge executable.\n | ||||
| * Default unset. | * Default unset. | ||||
| */ | */ | ||||
| OPTION_PATH_BRIDGE_WIN64 = 20, | |||||
| OPTION_PATH_BRIDGE_WIN64 = 21, | |||||
| /*! | /*! | ||||
| * Set path to the LV2 Gtk2 UI bridge executable.\n | * Set path to the LV2 Gtk2 UI bridge executable.\n | ||||
| * Default unset. | * Default unset. | ||||
| */ | */ | ||||
| OPTION_PATH_BRIDGE_LV2_GTK2 = 21, | |||||
| OPTION_PATH_BRIDGE_LV2_GTK2 = 22, | |||||
| /*! | /*! | ||||
| * Set path to the LV2 Gtk3 UI bridge executable.\n | * Set path to the LV2 Gtk3 UI bridge executable.\n | ||||
| * Default unset. | * Default unset. | ||||
| */ | */ | ||||
| OPTION_PATH_BRIDGE_LV2_GTK3 = 22, | |||||
| OPTION_PATH_BRIDGE_LV2_GTK3 = 23, | |||||
| /*! | /*! | ||||
| * Set path to the LV2 Qt4 UI bridge executable.\n | * Set path to the LV2 Qt4 UI bridge executable.\n | ||||
| * Default unset. | * Default unset. | ||||
| */ | */ | ||||
| OPTION_PATH_BRIDGE_LV2_QT4 = 23, | |||||
| OPTION_PATH_BRIDGE_LV2_QT4 = 24, | |||||
| /*! | /*! | ||||
| * Set path to the LV2 X11 UI bridge executable.\n | * Set path to the LV2 X11 UI bridge executable.\n | ||||
| * Default unset. | * Default unset. | ||||
| */ | */ | ||||
| OPTION_PATH_BRIDGE_LV2_X11 = 24, | |||||
| OPTION_PATH_BRIDGE_LV2_X11 = 25, | |||||
| /*! | /*! | ||||
| * Set path to the VST HWND UI bridge executable.\n | * Set path to the VST HWND UI bridge executable.\n | ||||
| * Default unset. | * Default unset. | ||||
| */ | */ | ||||
| OPTION_PATH_BRIDGE_VST_HWND = 25, | |||||
| OPTION_PATH_BRIDGE_VST_HWND = 26, | |||||
| /*! | /*! | ||||
| * Set path to the VST X11 UI bridge executable.\n | * Set path to the VST X11 UI bridge executable.\n | ||||
| * Default unset. | * Default unset. | ||||
| */ | */ | ||||
| OPTION_PATH_BRIDGE_VST_X11 = 26 | |||||
| OPTION_PATH_BRIDGE_VST_X11 = 27 | |||||
| }; | }; | ||||
| /*! | /*! | ||||
| @@ -245,11 +245,13 @@ short CarlaEngine::addPlugin(const BinaryType btype, const PluginType ptype, con | |||||
| CARLA_ASSERT(label); | CARLA_ASSERT(label); | ||||
| if (m_maxPluginNumber == 0) | if (m_maxPluginNumber == 0) | ||||
| { | |||||
| #ifdef BUILD_BRIDGE | #ifdef BUILD_BRIDGE | ||||
| m_maxPluginNumber = MAX_PLUGINS; | m_maxPluginNumber = MAX_PLUGINS; | ||||
| #else | #else | ||||
| m_maxPluginNumber = (carlaOptions.processMode == PROCESS_MODE_CONTINUOUS_RACK) ? 16 : MAX_PLUGINS; | m_maxPluginNumber = (carlaOptions.processMode == PROCESS_MODE_CONTINUOUS_RACK) ? 16 : MAX_PLUGINS; | ||||
| #endif | #endif | ||||
| } | |||||
| CarlaPlugin::initializer init = { | CarlaPlugin::initializer init = { | ||||
| this, | this, | ||||
| @@ -261,7 +263,7 @@ short CarlaEngine::addPlugin(const BinaryType btype, const PluginType ptype, con | |||||
| CarlaPlugin* plugin = nullptr; | CarlaPlugin* plugin = nullptr; | ||||
| #ifndef BUILD_BRIDGE | #ifndef BUILD_BRIDGE | ||||
| if (btype != BINARY_NATIVE /*|| true*/) | |||||
| if (btype != BINARY_NATIVE || carlaOptions.preferPluginBridges) | |||||
| { | { | ||||
| # ifdef CARLA_ENGINE_JACK | # ifdef CARLA_ENGINE_JACK | ||||
| if (carlaOptions.processMode != CarlaBackend::PROCESS_MODE_MULTIPLE_CLIENTS) | if (carlaOptions.processMode != CarlaBackend::PROCESS_MODE_MULTIPLE_CLIENTS) | ||||
| @@ -224,6 +224,8 @@ const char* OptionsType2str(const OptionsType type) | |||||
| return "OPTION_FORCE_STEREO"; | return "OPTION_FORCE_STEREO"; | ||||
| case OPTION_USE_DSSI_VST_CHUNKS: | case OPTION_USE_DSSI_VST_CHUNKS: | ||||
| return "OPTION_USE_DSSI_VST_CHUNKS"; | return "OPTION_USE_DSSI_VST_CHUNKS"; | ||||
| case OPTION_PREFER_PLUGIN_BRIDGES: | |||||
| return "OPTION_PREFER_PLUGIN_BRIDGES"; | |||||
| case OPTION_PREFER_UI_BRIDGES: | case OPTION_PREFER_UI_BRIDGES: | ||||
| return "OPTION_PREFER_UI_BRIDGES"; | return "OPTION_PREFER_UI_BRIDGES"; | ||||
| case OPTION_OSC_UI_TIMEOUT: | case OPTION_OSC_UI_TIMEOUT: | ||||
| @@ -574,6 +576,9 @@ void setOption(const OptionsType option, const int value, const char* const valu | |||||
| case OPTION_USE_DSSI_VST_CHUNKS: | case OPTION_USE_DSSI_VST_CHUNKS: | ||||
| carlaOptions.useDssiVstChunks = value; | carlaOptions.useDssiVstChunks = value; | ||||
| break; | break; | ||||
| case OPTION_PREFER_PLUGIN_BRIDGES: | |||||
| carlaOptions.preferPluginBridges = value; | |||||
| break; | |||||
| case OPTION_PREFER_UI_BRIDGES: | case OPTION_PREFER_UI_BRIDGES: | ||||
| carlaOptions.preferUiBridges = value; | carlaOptions.preferUiBridges = value; | ||||
| break; | break; | ||||
| @@ -675,6 +680,7 @@ void resetOptions() | |||||
| carlaOptions.preferredSampleRate = 44100; | carlaOptions.preferredSampleRate = 44100; | ||||
| carlaOptions.forceStereo = false; | carlaOptions.forceStereo = false; | ||||
| carlaOptions.useDssiVstChunks = false; | carlaOptions.useDssiVstChunks = false; | ||||
| carlaOptions.preferPluginBridges = false; | |||||
| carlaOptions.preferUiBridges = true; | carlaOptions.preferUiBridges = true; | ||||
| carlaOptions.oscUiTimeout = 4000/100; | carlaOptions.oscUiTimeout = 4000/100; | ||||
| @@ -68,6 +68,7 @@ struct carla_options_t { | |||||
| bool forceStereo; | bool forceStereo; | ||||
| bool useDssiVstChunks; | bool useDssiVstChunks; | ||||
| bool preferPluginBridges; | |||||
| bool preferUiBridges; | bool preferUiBridges; | ||||
| uint oscUiTimeout; | uint oscUiTimeout; | ||||
| @@ -90,6 +91,7 @@ struct carla_options_t { | |||||
| preferredSampleRate(44100), | preferredSampleRate(44100), | ||||
| forceStereo(false), | forceStereo(false), | ||||
| useDssiVstChunks(false), | useDssiVstChunks(false), | ||||
| preferPluginBridges(false), | |||||
| preferUiBridges(true), | preferUiBridges(true), | ||||
| oscUiTimeout(4000/100), | oscUiTimeout(4000/100), | ||||
| bridge_posix32(nullptr), | bridge_posix32(nullptr), | ||||
| @@ -152,25 +152,26 @@ OPTION_PREFERRED_BUFFER_SIZE = 4 | |||||
| OPTION_PREFERRED_SAMPLE_RATE = 5 | OPTION_PREFERRED_SAMPLE_RATE = 5 | ||||
| OPTION_FORCE_STEREO = 6 | OPTION_FORCE_STEREO = 6 | ||||
| OPTION_USE_DSSI_VST_CHUNKS = 7 | OPTION_USE_DSSI_VST_CHUNKS = 7 | ||||
| OPTION_PREFER_UI_BRIDGES = 8 | |||||
| OPTION_OSC_UI_TIMEOUT = 9 | |||||
| OPTION_PATH_LADSPA = 10 | |||||
| OPTION_PATH_DSSI = 11 | |||||
| OPTION_PATH_LV2 = 12 | |||||
| OPTION_PATH_VST = 13 | |||||
| OPTION_PATH_GIG = 14 | |||||
| OPTION_PATH_SF2 = 15 | |||||
| OPTION_PATH_SFZ = 16 | |||||
| OPTION_PATH_BRIDGE_POSIX32 = 17 | |||||
| OPTION_PATH_BRIDGE_POSIX64 = 18 | |||||
| OPTION_PATH_BRIDGE_WIN32 = 19 | |||||
| OPTION_PATH_BRIDGE_WIN64 = 20 | |||||
| OPTION_PATH_BRIDGE_LV2_GTK2 = 21 | |||||
| OPTION_PATH_BRIDGE_LV2_GTK3 = 22 | |||||
| OPTION_PATH_BRIDGE_LV2_QT4 = 23 | |||||
| OPTION_PATH_BRIDGE_LV2_X11 = 24 | |||||
| OPTION_PATH_BRIDGE_VST_HWND = 25 | |||||
| OPTION_PATH_BRIDGE_VST_X11 = 26 | |||||
| OPTION_PREFER_PLUGIN_BRIDGES = 8 | |||||
| OPTION_PREFER_UI_BRIDGES = 9 | |||||
| OPTION_OSC_UI_TIMEOUT = 10 | |||||
| OPTION_PATH_LADSPA = 11 | |||||
| OPTION_PATH_DSSI = 12 | |||||
| OPTION_PATH_LV2 = 13 | |||||
| OPTION_PATH_VST = 14 | |||||
| OPTION_PATH_GIG = 15 | |||||
| OPTION_PATH_SF2 = 16 | |||||
| OPTION_PATH_SFZ = 17 | |||||
| OPTION_PATH_BRIDGE_POSIX32 = 18 | |||||
| OPTION_PATH_BRIDGE_POSIX64 = 19 | |||||
| OPTION_PATH_BRIDGE_WIN32 = 20 | |||||
| OPTION_PATH_BRIDGE_WIN64 = 21 | |||||
| OPTION_PATH_BRIDGE_LV2_GTK2 = 22 | |||||
| OPTION_PATH_BRIDGE_LV2_GTK3 = 23 | |||||
| OPTION_PATH_BRIDGE_LV2_QT4 = 24 | |||||
| OPTION_PATH_BRIDGE_LV2_X11 = 25 | |||||
| OPTION_PATH_BRIDGE_VST_HWND = 26 | |||||
| OPTION_PATH_BRIDGE_VST_X11 = 27 | |||||
| # enum CallbackType | # enum CallbackType | ||||
| CALLBACK_DEBUG = 0 | CALLBACK_DEBUG = 0 | ||||