Browse Source

Fix discovery with juce

tags/1.9.4
falkTX 11 years ago
parent
commit
5fa73f6a4f
4 changed files with 39 additions and 17 deletions
  1. +1
    -1
      source/discovery/Makefile
  2. +34
    -12
      source/discovery/carla-discovery.cpp
  3. +3
    -3
      source/modules/juce_audio_processors.h
  4. +1
    -1
      source/modules/juce_core/AppConfig.h

+ 1
- 1
source/discovery/Makefile View File

@@ -23,7 +23,7 @@ LINK_FLAGS += $(QTCORE_LIBS)
BUILD_CXX_FLAGS += -DWANT_NATIVE

ifeq ($(CARLA_PLUGIN_SUPPORT),true)
BUILD_CXX_FLAGS += -DWANT_LADSPA -DWANT_DSSI -DWANT_LV2 -DWANT_VST
BUILD_CXX_FLAGS += -DWANT_LADSPA -DWANT_DSSI -DWANT_LV2 -DWANT_VST -DWANT_VST3 -DWANT_AU
ifeq ($(CARLA_VESTIGE_HEADER),true)
BUILD_CXX_FLAGS += -DVESTIGE_HEADER
endif


+ 34
- 12
source/discovery/carla-discovery.cpp View File

@@ -15,8 +15,6 @@
* For a full copy of the GNU General Public License see the doc/GPL.txt file.
*/

#undef HAVE_JUCE // FIXME

#include "CarlaBackendUtils.hpp"
#include "CarlaLibUtils.hpp"
#include "CarlaMathUtils.hpp"
@@ -1464,22 +1462,39 @@ static void do_juce_check(const char* const filename, const char* const stype, c

if (stype == nullptr)
return;
#if JUCE_PLUGINHOST_AU && defined(JUCE_MAC)
else if (std::strcmp(stype, "AU") == 0)
pluginFormat = new AudioUnitPluginFormat();
#endif
#if JUCE_PLUGINHOST_LADSPA && defined(JUCE_LINUX)

else if (std::strcmp(stype, "LADSPA") == 0)
{
#if defined(WANT_LADSPA) && JUCE_PLUGINHOST_LADSPA && defined(JUCE_LINUX)
pluginFormat = new LADSPAPluginFormat();
#else
DISCOVERY_OUT("error", "LADSPA support not available");
#endif
#if JUCE_PLUGINHOST_VST // && ! defined(VESTIGE_HEADER)
}
else if (std::strcmp(stype, "VST") == 0)
{
#if defined(WANT_VST) && JUCE_PLUGINHOST_VST && ! defined(VESTIGE_HEADER)
pluginFormat = new VSTPluginFormat();
#else
DISCOVERY_OUT("error", "VST support not available");
#endif
#if JUCE_PLUGINHOST_VST3
}
else if (std::strcmp(stype, "VST3") == 0)
{
#if defined(WANT_VST3) && JUCE_PLUGINHOST_VST3
pluginFormat = new VSTPluginFormat();
#else
DISCOVERY_OUT("error", "VST3 support not available");
#endif
}
else if (std::strcmp(stype, "AU") == 0)
{
#if defined(WANT_AU) && JUCE_PLUGINHOST_AU && defined(JUCE_MAC)
pluginFormat = new AudioUnitPluginFormat();
#else
DISCOVERY_OUT("error", "AU support not available");
#endif
}

if (pluginFormat == nullptr)
{
@@ -1496,7 +1511,7 @@ static void do_juce_check(const char* const filename, const char* const stype, c
carla_stderr2("LOOKING FOR PLUGIN %i", iv++);
PluginDescription* const desc(*it);

int hints = 0x0;
uint hints = 0x0;
int audioIns = desc->numInputChannels;
int audioOuts = desc->numOutputChannels;
int midiIns = 0;
@@ -1960,11 +1975,18 @@ bool arrayContainsPlugin(const OwnedArray<PluginDescription>& list, const Plugin
#include "juce_audio_processors/processors/juce_AudioProcessor.cpp"
#include "juce_audio_processors/processors/juce_PluginDescription.cpp"

#ifndef CARLA_OS_MAC // FIXME later
# include "juce_audio_processors/format_types/juce_AudioUnitPluginFormat.mm"
#ifdef WANT_LADSPA
# include "juce_audio_processors/format_types/juce_LADSPAPluginFormat.cpp"
#endif
#if defined(WANT_VST) && ! defined(VESTIGE_HEADER)
# include "juce_audio_processors/format_types/juce_VSTPluginFormat.cpp"
#endif
#ifdef WANT_VST3
# include "juce_audio_processors/format_types/juce_VST3PluginFormat.cpp"
#endif
#ifdef WANT_AU
# include "juce_audio_processors/format_types/juce_AudioUnitPluginFormat.mm"
#endif
}
#endif



+ 3
- 3
source/modules/juce_audio_processors.h View File

@@ -15,8 +15,8 @@
* For a full copy of the GNU General Public License see the doc/GPL.txt file.
*/

#ifndef CARLA_JUCE_AUDIO_BASICS_H_INCLUDED
#define CARLA_JUCE_AUDIO_BASICS_H_INCLUDED
#ifndef CARLA_JUCE_AUDIO_PROCESSORS_H_INCLUDED
#define CARLA_JUCE_AUDIO_PROCESSORS_H_INCLUDED

#include "juce_gui_basics.h"
#include "juce_audio_basics.h"
@@ -24,4 +24,4 @@
#include "juce_audio_processors/AppConfig.h"
#include "juce_audio_processors/juce_audio_processors.h"

#endif // CARLA_JUCE_AUDIO_BASICS_H_INCLUDED
#endif // CARLA_JUCE_AUDIO_PROCESSORS_H_INCLUDED

+ 1
- 1
source/modules/juce_core/AppConfig.h View File

@@ -78,7 +78,7 @@
#define JUCE_MODULE_AVAILABLE_juce_events 1
#define JUCE_MODULE_AVAILABLE_juce_graphics 1
#define JUCE_MODULE_AVAILABLE_juce_gui_basics 1
#define JUCE_MODULE_AVAILABLE_juce_gui_extra 0
#define JUCE_MODULE_AVAILABLE_juce_gui_extra 1
#define JUCE_MODULE_AVAILABLE_juce_opengl 0
#define JUCE_MODULE_AVAILABLE_juce_video 0


Loading…
Cancel
Save