Browse Source

Don't try to build VST/VST3 hosting code on iOS and add missing header

tags/2021-05-28
hogliux 9 years ago
parent
commit
7196e57f4d
7 changed files with 23 additions and 19 deletions
  1. +1
    -1
      extras/Projucer/Source/Project/jucer_Module.cpp
  2. +4
    -4
      modules/juce_audio_processors/format/juce_AudioPluginFormatManager.cpp
  3. +14
    -10
      modules/juce_audio_processors/format_types/juce_AudioUnitPluginFormat.mm
  4. +1
    -1
      modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp
  5. +1
    -1
      modules/juce_audio_processors/format_types/juce_VST3PluginFormat.h
  6. +1
    -1
      modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp
  7. +1
    -1
      modules/juce_audio_processors/format_types/juce_VSTPluginFormat.h

+ 1
- 1
extras/Projucer/Source/Project/jucer_Module.cpp View File

@@ -328,7 +328,7 @@ void LibraryModule::addSettingsForModuleToExporter (ProjectExporter& exporter, P
XCodeProjectExporter& xcodeExporter = dynamic_cast<XCodeProjectExporter&> (exporter);
if (project.isAUPluginHost())
xcodeExporter.xcodeFrameworks.addTokens ("AudioUnit CoreAudioKit", false);
xcodeExporter.xcodeFrameworks.addTokens (xcodeExporter.isOSX() ? "AudioUnit CoreAudioKit" : "CoreAudioKit", false);
const String frameworks (moduleInfo.moduleInfo [xcodeExporter.isOSX() ? "OSXFrameworks" : "iOSFrameworks"].toString());
xcodeExporter.xcodeFrameworks.addTokens (frameworks, ", ", StringRef());


+ 4
- 4
modules/juce_audio_processors/format/juce_AudioPluginFormatManager.cpp View File

@@ -65,11 +65,11 @@ void AudioPluginFormatManager::addDefaultFormats()
// you should only call this method once!
for (int i = formats.size(); --i >= 0;)
{
#if JUCE_PLUGINHOST_VST
#if JUCE_PLUGINHOST_VST && (JUCE_MAC || JUCE_WIN || JUCE_LINUX)
jassert (dynamic_cast<VSTPluginFormat*> (formats[i]) == nullptr);
#endif
#if JUCE_PLUGINHOST_VST3
#if JUCE_PLUGINHOST_VST3 && (JUCE_MAC || JUCE_WIN)
jassert (dynamic_cast<VST3PluginFormat*> (formats[i]) == nullptr);
#endif
@@ -87,11 +87,11 @@ void AudioPluginFormatManager::addDefaultFormats()
formats.add (new AudioUnitPluginFormat());
#endif
#if JUCE_PLUGINHOST_VST
#if JUCE_PLUGINHOST_VST && (JUCE_MAC || JUCE_WIN || JUCE_LINUX)
formats.add (new VSTPluginFormat());
#endif
#if JUCE_PLUGINHOST_VST3
#if JUCE_PLUGINHOST_VST3 && (JUCE_MAC || JUCE_WIN)
formats.add (new VST3PluginFormat());
#endif


+ 14
- 10
modules/juce_audio_processors/format_types/juce_AudioUnitPluginFormat.mm View File

@@ -39,6 +39,18 @@
#include <AudioUnit/AudioUnitCarbonView.h>
#endif
#ifndef JUCE_SUPPORTS_AUv3
#if JUCE_COMPILER_SUPPORTS_VARIADIC_TEMPLATES && defined (MAC_OS_X_VERSION_MIN_REQUIRED) && (MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_8) && __OBJC2__
#define JUCE_SUPPORTS_AUv3 1
#else
#define JUCE_SUPPORTS_AUv3 0
#endif
#endif
#if JUCE_SUPPORTS_AUv3
#include <CoreAudioKit/AUViewController.h>
#endif
namespace juce
{
@@ -61,14 +73,6 @@ namespace juce
#define JUCE_AU_LOG(a)
#endif
#ifndef JUCE_SUPPORTS_AUv3
#if JUCE_COMPILER_SUPPORTS_VARIADIC_TEMPLATES
#define JUCE_SUPPORTS_AUv3 1
#else
#define JUCE_SUPPORTS_AUv3 0
#endif
#endif
namespace AudioUnitFormatHelpers
{
#if JUCE_DEBUG
@@ -1516,7 +1520,7 @@ private:
AutoResizingNSViewComponent wrapper;
#if JUCE_SUPPORTS_AUv3
typedef void (^ViewControllerCallbackBlock)(NSViewController *);
typedef void (^ViewControllerCallbackBlock)(AUViewControllerBase *);
ObjCBlock<ViewControllerCallbackBlock> viewControllerCallback;
#endif
@@ -1617,7 +1621,7 @@ private:
}
#if JUCE_SUPPORTS_AUv3
void requestViewControllerCallback (NSViewController* controller)
void requestViewControllerCallback (AUViewControllerBase* controller)
{
auto nsSize = [controller preferredContentSize];
auto viewSize = CGSizeMake (nsSize.width, nsSize.height);


+ 1
- 1
modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp View File

@@ -22,7 +22,7 @@
==============================================================================
*/
#if JUCE_PLUGINHOST_VST3
#if JUCE_PLUGINHOST_VST3 && (JUCE_MAC || JUCE_WIN)
} // namespace juce


+ 1
- 1
modules/juce_audio_processors/format_types/juce_VST3PluginFormat.h View File

@@ -25,7 +25,7 @@
#ifndef JUCE_VST3PLUGINFORMAT_H_INCLUDED
#define JUCE_VST3PLUGINFORMAT_H_INCLUDED
#if JUCE_PLUGINHOST_VST3
#if (JUCE_PLUGINHOST_VST3 && (JUCE_MAC || JUCE_WIN)) || DOXYGEN
/**
Implements a plugin format for VST3s.


+ 1
- 1
modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp View File

@@ -22,7 +22,7 @@
==============================================================================
*/
#if JUCE_PLUGINHOST_VST
#if JUCE_PLUGINHOST_VST && (JUCE_MAC || JUCE_WIN || JUCE_LINUX)
//==============================================================================
#if JUCE_MAC && JUCE_SUPPORT_CARBON


+ 1
- 1
modules/juce_audio_processors/format_types/juce_VSTPluginFormat.h View File

@@ -22,7 +22,7 @@
==============================================================================
*/
#if JUCE_PLUGINHOST_VST || DOXYGEN
#if (JUCE_PLUGINHOST_VST && (JUCE_MAC || JUCE_WIN || JUCE_LINUX)) || DOXYGEN
//==============================================================================
/**


Loading…
Cancel
Save