Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix build, make sure to not enable OSC
Signed-off-by: falkTX <falktx@falktx.com>
  • Loading branch information
falkTX committed Sep 3, 2023
1 parent 3c5793b commit 3c47c49
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 5 deletions.
2 changes: 1 addition & 1 deletion carla
23 changes: 19 additions & 4 deletions main.cpp
Expand Up @@ -72,22 +72,37 @@ int main(int argc, char *argv[])

const CarlaHostHandle handle = carla_standalone_host_init();

if (handle == nullptr || !carla_engine_init(handle, "JACK", "Chibi"))
if (handle == nullptr)
{
QMessageBox::critical(nullptr, "Error", carla_get_last_error(handle));
QMessageBox::critical(nullptr, "Error", carla_get_last_error(nullptr));
return 1;
}

carla_set_engine_option(handle, ENGINE_OPTION_OSC_ENABLED, 0, nullptr);
carla_set_engine_option(handle, ENGINE_OPTION_OSC_PORT_TCP, -1, nullptr);
carla_set_engine_option(handle, ENGINE_OPTION_OSC_PORT_UDP, -1, nullptr);
carla_set_engine_option(handle, ENGINE_OPTION_PATH_BINARIES, 0, carla_get_library_folder());
carla_set_engine_option(handle, ENGINE_OPTION_PREFER_UI_BRIDGES, 0, nullptr);

// TODO check CLI args and use it instead of plugin list dialog
if (!carla_engine_init(handle, "JACK", "Chibi"))
{
QMessageBox::critical(nullptr, "Error", carla_get_last_error(handle));
return 1;
}

const PluginListDialogResults* const res = carla_frontend_createAndExecPluginListDialog(nullptr);
// TODO check CLI args and use it instead of plugin list dialog

int r = 1;

const HostSettings hostSettings = {};
PluginListDialog* const dialog = carla_frontend_createPluginListDialog(nullptr, &hostSettings);
const PluginListDialogResults* res;

if (dialog == nullptr)
goto cleanup;

res = carla_frontend_execPluginListDialog(dialog);

if (res == nullptr)
goto cleanup;

Expand Down

0 comments on commit 3c47c49

Please sign in to comment.