mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-11 09:06:33 +01:00
Fixed compilation of CoreAudioSource
Seperated AUDIOUNITS support from COREAUDIO support. Fixed metadata saving in SfdbUI. git-svn-id: svn://localhost/ardour2/trunk@879 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
21d85f1854
commit
9bc22f6f86
17 changed files with 54 additions and 155 deletions
|
|
@ -26,6 +26,7 @@ subst_dict = { }
|
||||||
opts = Options('scache.conf')
|
opts = Options('scache.conf')
|
||||||
opts.AddOptions(
|
opts.AddOptions(
|
||||||
('ARCH', 'Set architecture-specific compilation flags by hand (all flags as 1 argument)',''),
|
('ARCH', 'Set architecture-specific compilation flags by hand (all flags as 1 argument)',''),
|
||||||
|
BoolOption('AUDIOUNITS', 'Compile with Apple\'s AudioUnit library. (experimental)', 0),
|
||||||
BoolOption('COREAUDIO', 'Compile with Apple\'s CoreAudio library', 0),
|
BoolOption('COREAUDIO', 'Compile with Apple\'s CoreAudio library', 0),
|
||||||
BoolOption('DEBUG', 'Set to build with debugging information and no optimizations', 0),
|
BoolOption('DEBUG', 'Set to build with debugging information and no optimizations', 0),
|
||||||
PathOption('DESTDIR', 'Set the intermediate install "prefix"', '/'),
|
PathOption('DESTDIR', 'Set the intermediate install "prefix"', '/'),
|
||||||
|
|
@ -508,8 +509,6 @@ else:
|
||||||
|
|
||||||
libraries['dmalloc'] = conf.Finish ()
|
libraries['dmalloc'] = conf.Finish ()
|
||||||
|
|
||||||
#
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Audio/MIDI library (needed for MIDI, since audio is all handled via JACK)
|
# Audio/MIDI library (needed for MIDI, since audio is all handled via JACK)
|
||||||
#
|
#
|
||||||
|
|
|
||||||
|
|
@ -61,7 +61,7 @@ skipped_files=Split("""
|
||||||
connection_editor.cc
|
connection_editor.cc
|
||||||
""")
|
""")
|
||||||
|
|
||||||
coreaudio_files=Split("""
|
audiounit_files=Split("""
|
||||||
au_pluginui.cc
|
au_pluginui.cc
|
||||||
""")
|
""")
|
||||||
|
|
||||||
|
|
@ -221,9 +221,9 @@ if env['VST']:
|
||||||
extra_sources += vst_files
|
extra_sources += vst_files
|
||||||
gtkardour.Append (CCFLAGS="-DVST_SUPPORT", CPPPATH="#libs/fst")
|
gtkardour.Append (CCFLAGS="-DVST_SUPPORT", CPPPATH="#libs/fst")
|
||||||
|
|
||||||
if gtkardour['COREAUDIO']:
|
if gtkardour['AUDIOUNITS']:
|
||||||
extra_sources += coreaudio_files
|
extra_sources += audiounit_files
|
||||||
gtkardour.Append(CCFLAGS='-DHAVE_COREAUDIO')
|
gtkardour.Append(CCFLAGS='-DHAVE_AUDIOUNITS')
|
||||||
gtkardour.Append(LINKFLAGS='-framework Carbon')
|
gtkardour.Append(LINKFLAGS='-framework Carbon')
|
||||||
gtkardour.Merge([libraries['appleutility']])
|
gtkardour.Merge([libraries['appleutility']])
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -43,77 +43,6 @@ AUPluginUI::AUPluginUI (boost::shared_ptr<PluginInsert> insert)
|
||||||
throw failed_constructor ();
|
throw failed_constructor ();
|
||||||
}
|
}
|
||||||
|
|
||||||
OSStatus err = noErr;
|
|
||||||
|
|
||||||
CAComponentDescription desc;
|
|
||||||
Component carbonViewComponent = NULL;
|
|
||||||
AudioUnitCarbonView carbonView = NULL;
|
|
||||||
|
|
||||||
GetComponentInfo(au->get_comp()->Comp(), &desc, 0, 0, 0);
|
|
||||||
carbonViewComponent = get_carbon_view_component(desc.componentSubType);
|
|
||||||
err = OpenAComponent(carbonViewComponent, &carbonView);
|
|
||||||
|
|
||||||
Rect rec;
|
|
||||||
rec.top = 0;
|
|
||||||
rec.left = 0;
|
|
||||||
rec.bottom = 400;
|
|
||||||
rec.right = 500;
|
|
||||||
|
|
||||||
ProcessSerialNumber ourPSN;
|
|
||||||
|
|
||||||
/* Here we will set the MacOSX native section of the process to the foreground for putting up this
|
|
||||||
* dialog box. First step is to get our process serial number. We do this by calling
|
|
||||||
* GetCurrentProcess.
|
|
||||||
* First Argument: On success this PSN will be our PSN on return.
|
|
||||||
* Return Value: A Macintosh error indicating success or failure.
|
|
||||||
*/
|
|
||||||
err = GetCurrentProcess(&ourPSN);
|
|
||||||
|
|
||||||
//If no error then set this process to be frontmost.
|
|
||||||
if (err == noErr) {
|
|
||||||
/* Calling SetFrontProcess to make us frontmost.
|
|
||||||
* First Argument: The Process Serial Number of the process we want to make frontmost. Here
|
|
||||||
* of course we pass our process serial number
|
|
||||||
* Return Value: An error value indicating success or failure. We just ignore the return
|
|
||||||
* value here.
|
|
||||||
*/
|
|
||||||
(void)SetFrontProcess(&ourPSN);
|
|
||||||
} else {
|
|
||||||
error << "couldn't get current process" << endmsg;
|
|
||||||
}
|
|
||||||
|
|
||||||
err = CreateNewWindow (kDocumentWindowClass, kWindowStandardFloatingAttributes, &rec, &wr);
|
|
||||||
|
|
||||||
ComponentResult auResult;
|
|
||||||
ControlRef rootControl = NULL;
|
|
||||||
GetRootControl(wr, &rootControl);
|
|
||||||
|
|
||||||
int width = 500;
|
|
||||||
int height = 400;
|
|
||||||
Float32Point location = {30, 30};
|
|
||||||
Float32Point size = {width, height};
|
|
||||||
ControlRef audioUnitControl = NULL;
|
|
||||||
|
|
||||||
auResult = AudioUnitCarbonViewCreate(carbonView,
|
|
||||||
au->get_au()->AU(),
|
|
||||||
wr,
|
|
||||||
rootControl,
|
|
||||||
&location,
|
|
||||||
&size,
|
|
||||||
&audioUnitControl);
|
|
||||||
|
|
||||||
ShowWindow (wr);
|
|
||||||
BringToFront (wr);
|
|
||||||
// AudioUnitCarbonViewSetEventListener(carbonView, EventListener, this);
|
|
||||||
#if 0
|
|
||||||
set_name ("PluginEditor");
|
|
||||||
add_events (Gdk::KEY_PRESS_MASK|Gdk::KEY_RELEASE_MASK|Gdk::BUTTON_PRESS_MASK|Gdk::BUTTON_RELEASE_MASK);
|
|
||||||
|
|
||||||
signal_delete_event().connect (bind (sigc::ptr_fun (just_hide_it), reinterpret_cast<Window*> (this)));
|
|
||||||
#endif
|
|
||||||
|
|
||||||
insert->GoingAway.connect (mem_fun(*this, &AUPluginUI::plugin_going_away));
|
|
||||||
|
|
||||||
info << "AUPluginUI created" << endmsg;
|
info << "AUPluginUI created" << endmsg;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -122,38 +51,3 @@ AUPluginUI::~AUPluginUI ()
|
||||||
// nothing to do here - plugin destructor destroys the GUI
|
// nothing to do here - plugin destructor destroys the GUI
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
AUPluginUI::plugin_going_away (ARDOUR::Redirect* ignored)
|
|
||||||
{
|
|
||||||
ENSURE_GUI_THREAD(bind (mem_fun(*this, &AUPluginUI::plugin_going_away), ignored));
|
|
||||||
|
|
||||||
delete_when_idle (this);
|
|
||||||
}
|
|
||||||
|
|
||||||
Component
|
|
||||||
AUPluginUI::get_carbon_view_component(OSType subtype)
|
|
||||||
{
|
|
||||||
ComponentDescription desc;
|
|
||||||
Component component;
|
|
||||||
|
|
||||||
desc.componentType = kAudioUnitCarbonViewComponentType; // 'auvw'
|
|
||||||
desc.componentSubType = subtype;
|
|
||||||
desc.componentManufacturer = 0;
|
|
||||||
desc.componentFlags = 0;
|
|
||||||
desc.componentFlagsMask = 0;
|
|
||||||
|
|
||||||
// First see if we can find a carbon view designed specifically for this
|
|
||||||
// plug-in:
|
|
||||||
|
|
||||||
component = FindNextComponent(NULL, &desc);
|
|
||||||
if (component)
|
|
||||||
return component;
|
|
||||||
|
|
||||||
// If not, grab the generic carbon view, which will create a GUI for
|
|
||||||
// any Audio Unit.
|
|
||||||
|
|
||||||
desc.componentSubType = kAUCarbonViewSubType_Generic;
|
|
||||||
component = FindNextComponent(NULL, &desc);
|
|
||||||
|
|
||||||
return component;
|
|
||||||
}
|
|
||||||
|
|
|
||||||
|
|
@ -38,11 +38,7 @@ class AUPluginUI
|
||||||
~AUPluginUI ();
|
~AUPluginUI ();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
WindowRef wr;
|
|
||||||
boost::shared_ptr<ARDOUR::AUPlugin> au;
|
boost::shared_ptr<ARDOUR::AUPlugin> au;
|
||||||
|
|
||||||
void plugin_going_away (ARDOUR::Redirect*);
|
|
||||||
Component get_carbon_view_component(OSType subtype);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // __au_plugin_ui_h__
|
#endif // __au_plugin_ui_h__
|
||||||
|
|
|
||||||
|
|
@ -92,7 +92,7 @@ PluginSelector::PluginSelector (PluginManager *mgr)
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNIT
|
||||||
aumodel = ListStore::create(aucols);
|
aumodel = ListStore::create(aucols);
|
||||||
au_display.set_model (aumodel);
|
au_display.set_model (aumodel);
|
||||||
au_display.append_column (_("Available plugins"), aucols.name);
|
au_display.append_column (_("Available plugins"), aucols.name);
|
||||||
|
|
@ -151,7 +151,7 @@ PluginSelector::PluginSelector (PluginManager *mgr)
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNIT
|
||||||
notebook.pages().push_back (TabElem (auscroller, _("AudioUnit")));
|
notebook.pages().push_back (TabElem (auscroller, _("AudioUnit")));
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
@ -171,7 +171,7 @@ PluginSelector::PluginSelector (PluginManager *mgr)
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNIT
|
||||||
au_display.signal_button_press_event().connect_notify (mem_fun(*this, &PluginSelector::row_clicked));
|
au_display.signal_button_press_event().connect_notify (mem_fun(*this, &PluginSelector::row_clicked));
|
||||||
au_display.get_selection()->signal_changed().connect (mem_fun(*this, &PluginSelector::au_display_selection_changed));
|
au_display.get_selection()->signal_changed().connect (mem_fun(*this, &PluginSelector::au_display_selection_changed));
|
||||||
#endif
|
#endif
|
||||||
|
|
@ -187,7 +187,7 @@ PluginSelector::PluginSelector (PluginManager *mgr)
|
||||||
vst_refiller ();
|
vst_refiller ();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNIT
|
||||||
au_refiller ();
|
au_refiller ();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
@ -219,7 +219,7 @@ PluginSelector::set_correct_focus()
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNIT
|
||||||
cp--;
|
cp--;
|
||||||
|
|
||||||
if (cp == 0) {
|
if (cp == 0) {
|
||||||
|
|
@ -330,7 +330,7 @@ PluginSelector::vst_display_selection_changed()
|
||||||
|
|
||||||
#endif //VST_SUPPORT
|
#endif //VST_SUPPORT
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNIT
|
||||||
|
|
||||||
void
|
void
|
||||||
PluginSelector::_au_refiller (void *arg)
|
PluginSelector::_au_refiller (void *arg)
|
||||||
|
|
@ -374,7 +374,7 @@ PluginSelector::au_display_selection_changed()
|
||||||
current_selection = ARDOUR::AudioUnit;
|
current_selection = ARDOUR::AudioUnit;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif //HAVE_COREAUDIO
|
#endif //HAVE_AUDIOUNIT
|
||||||
|
|
||||||
void
|
void
|
||||||
PluginSelector::use_plugin (PluginInfoPtr pi)
|
PluginSelector::use_plugin (PluginInfoPtr pi)
|
||||||
|
|
@ -413,7 +413,7 @@ PluginSelector::btn_add_clicked()
|
||||||
#endif
|
#endif
|
||||||
break;
|
break;
|
||||||
case ARDOUR::AudioUnit:
|
case ARDOUR::AudioUnit:
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNIT
|
||||||
row = *(au_display.get_selection()->get_selected());
|
row = *(au_display.get_selection()->get_selected());
|
||||||
name = row[aucols.name];
|
name = row[aucols.name];
|
||||||
pi = row[aucols.plugin];
|
pi = row[aucols.plugin];
|
||||||
|
|
@ -451,7 +451,7 @@ PluginSelector::btn_update_clicked()
|
||||||
#ifdef VST_SUPPORT
|
#ifdef VST_SUPPORT
|
||||||
vst_refiller ();
|
vst_refiller ();
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNIT
|
||||||
au_refiller ();
|
au_refiller ();
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -110,7 +110,7 @@ class PluginSelector : public ArdourDialog
|
||||||
void vst_display_selection_changed();
|
void vst_display_selection_changed();
|
||||||
#endif // VST_SUPPORT
|
#endif // VST_SUPPORT
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNIT
|
||||||
// page 3
|
// page 3
|
||||||
struct AUColumns : public Gtk::TreeModel::ColumnRecord {
|
struct AUColumns : public Gtk::TreeModel::ColumnRecord {
|
||||||
AUColumns () {
|
AUColumns () {
|
||||||
|
|
@ -131,7 +131,7 @@ class PluginSelector : public ArdourDialog
|
||||||
static void _au_refiller (void *);
|
static void _au_refiller (void *);
|
||||||
void au_refiller ();
|
void au_refiller ();
|
||||||
void au_display_selection_changed();
|
void au_display_selection_changed();
|
||||||
#endif //HAVE_COREAUDIO
|
#endif //HAVE_AUDIOUNIT
|
||||||
|
|
||||||
ARDOUR::PluginManager *manager;
|
ARDOUR::PluginManager *manager;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -62,7 +62,7 @@
|
||||||
|
|
||||||
#include "i18n.h"
|
#include "i18n.h"
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNIT
|
||||||
#include "au_pluginui.h"
|
#include "au_pluginui.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
@ -1000,7 +1000,7 @@ RedirectBox::edit_redirect (boost::shared_ptr<Redirect> redirect)
|
||||||
} else {
|
} else {
|
||||||
plugin_ui->show_all ();
|
plugin_ui->show_all ();
|
||||||
}
|
}
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNIT
|
||||||
} else if (type == ARDOUR::AudioUnit) {
|
} else if (type == ARDOUR::AudioUnit) {
|
||||||
AUPluginUI* plugin_ui;
|
AUPluginUI* plugin_ui;
|
||||||
if (plugin_insert->get_gui() == 0) {
|
if (plugin_insert->get_gui() == 0) {
|
||||||
|
|
|
||||||
|
|
@ -269,7 +269,11 @@ SoundFileBox::remove_field_clicked ()
|
||||||
void
|
void
|
||||||
SoundFileBox::field_edited (const Glib::ustring& str1, const Glib::ustring& str2)
|
SoundFileBox::field_edited (const Glib::ustring& str1, const Glib::ustring& str2)
|
||||||
{
|
{
|
||||||
cout << "field_edited" << endl;
|
Gtk::TreeModel::Children rows(fields->children());
|
||||||
|
Gtk::TreeModel::Row row(rows[atoi(str1.c_str())]);
|
||||||
|
|
||||||
|
Library->set_field (path, row[label_columns.field], str2);
|
||||||
|
|
||||||
Library->save_changes ();
|
Library->save_changes ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -102,7 +102,8 @@ arch_specific_objects = [ ]
|
||||||
|
|
||||||
osc_files = [ 'osc.cc' ]
|
osc_files = [ 'osc.cc' ]
|
||||||
vst_files = [ 'vst_plugin.cc', 'session_vst.cc' ]
|
vst_files = [ 'vst_plugin.cc', 'session_vst.cc' ]
|
||||||
coreaudio_files = [ 'audio_unit.cc', 'coreaudiosource.cc' ]
|
audiounit_files = [ 'audio_unit.cc' ]
|
||||||
|
coreaudio_files = [ 'coreaudiosource.cc' ]
|
||||||
extra_sources = [ ]
|
extra_sources = [ ]
|
||||||
|
|
||||||
if ardour['VST']:
|
if ardour['VST']:
|
||||||
|
|
@ -180,12 +181,16 @@ if conf.CheckCHeader('sys/vfs.h'):
|
||||||
if conf.CheckCHeader('/System/Library/Frameworks/CoreMIDI.framework/Headers/CoreMIDI.h'):
|
if conf.CheckCHeader('/System/Library/Frameworks/CoreMIDI.framework/Headers/CoreMIDI.h'):
|
||||||
ardour.Append(LINKFLAGS="-framework CoreMIDI")
|
ardour.Append(LINKFLAGS="-framework CoreMIDI")
|
||||||
|
|
||||||
if conf.CheckCHeader('/System/Library/Frameworks/AudioToolbox.framework/Headers/ExtendedAudioFile.h') and ardour['COREAUDIO'] == 1:
|
if conf.CheckCHeader('/System/Library/Frameworks/AudioUnit.framework/Headers/AudioUnit.h') and ardour['AUDIOUNITS']:
|
||||||
|
ardour.Append(CXXFLAGS="-DHAVE_AUDIOUNITS")
|
||||||
|
ardour.Append(LINKFLAGS="-framework AudioUnit")
|
||||||
|
extra_sources += audiounit_files
|
||||||
|
|
||||||
|
if conf.CheckCHeader('/System/Library/Frameworks/AudioToolbox.framework/Headers/ExtendedAudioFile.h') and ardour['COREAUDIO']:
|
||||||
ardour.Append(CXXFLAGS="-DHAVE_COREAUDIO")
|
ardour.Append(CXXFLAGS="-DHAVE_COREAUDIO")
|
||||||
ardour.Append(LINKFLAGS="-framework AudioToolbox")
|
ardour.Append(LINKFLAGS="-framework AudioToolbox")
|
||||||
extra_sources += coreaudio_files
|
extra_sources += coreaudio_files
|
||||||
|
|
||||||
|
|
||||||
if env['CONFIG_ARCH'] == 'apple':
|
if env['CONFIG_ARCH'] == 'apple':
|
||||||
# this next line avoids issues with circular dependencies between libardour and libardour_cp.
|
# this next line avoids issues with circular dependencies between libardour and libardour_cp.
|
||||||
# it is based on the (entirely reasonable) assumption that a system with CoreAudio is OS X
|
# it is based on the (entirely reasonable) assumption that a system with CoreAudio is OS X
|
||||||
|
|
@ -212,7 +217,7 @@ ardour.Merge ([
|
||||||
if ardour['LIBLO']:
|
if ardour['LIBLO']:
|
||||||
ardour.Merge ([ libraries['lo'] ])
|
ardour.Merge ([ libraries['lo'] ])
|
||||||
|
|
||||||
if ardour['COREAUDIO']:
|
if ardour['COREAUDIO'] or ardour['AUDIOUNITS']:
|
||||||
ardour.Merge ([ libraries['appleutility'] ])
|
ardour.Merge ([ libraries['appleutility'] ])
|
||||||
|
|
||||||
ardour.VersionBuild(['version.cc', 'ardour/version.h'], 'SConscript')
|
ardour.VersionBuild(['version.cc', 'ardour/version.h'], 'SConscript')
|
||||||
|
|
@ -242,12 +247,12 @@ libardour = ardour.SharedLibrary('ardour', ardour_files + extra_sources + arch_s
|
||||||
Default(libardour)
|
Default(libardour)
|
||||||
|
|
||||||
if env['NLS']:
|
if env['NLS']:
|
||||||
i18n (ardour, ardour_files + vst_files + coreaudio_files, env)
|
i18n (ardour, ardour_files + vst_files + coreaudio_files + audiounit_files, env)
|
||||||
|
|
||||||
|
|
||||||
env.Alias('install', env.Install(os.path.join(install_prefix, 'lib/ardour2'), libardour))
|
env.Alias('install', env.Install(os.path.join(install_prefix, 'lib/ardour2'), libardour))
|
||||||
|
|
||||||
env.Alias('tarball', env.Distribute (env['DISTTREE'],
|
env.Alias('tarball', env.Distribute (env['DISTTREE'],
|
||||||
[ 'SConscript', 'i18n.h', 'gettext.h', 'sse_functions.s', 'sse_functions_64bit.s' ] +
|
[ 'SConscript', 'i18n.h', 'gettext.h', 'sse_functions.s', 'sse_functions_64bit.s' ] +
|
||||||
ardour_files + vst_files + coreaudio_files +
|
ardour_files + vst_files + coreaudio_files + audiounit_files +
|
||||||
glob.glob('po/*.po') + glob.glob('ardour/*.h')))
|
glob.glob('po/*.po') + glob.glob('ardour/*.h')))
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <cmath>
|
#include <cmath>
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#if defined(HAVE_COREAUDIO) || defined(HAVE_AUDIOUNITS)
|
||||||
#include <CoreFoundation/CoreFoundation.h>
|
#include <CoreFoundation/CoreFoundation.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
@ -59,8 +59,9 @@ std::string path_expand (std::string);
|
||||||
|
|
||||||
void compute_equal_power_fades (jack_nframes_t nframes, float* in, float* out);
|
void compute_equal_power_fades (jack_nframes_t nframes, float* in, float* out);
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#if defined(HAVE_COREAUDIO) || defined(HAVE_AUDIOUNITS)
|
||||||
std::string CFStringRefToStdString(CFStringRef stringRef);
|
std::string CFStringRefToStdString(CFStringRef stringRef);
|
||||||
#endif // HAVE_COREAUDIO
|
#endif // HAVE_COREAUDIO
|
||||||
|
|
||||||
#endif /* __ardour_utils_h__ */
|
#endif /* __ardour_utils_h__ */
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -394,3 +394,4 @@ AUPluginInfo::setup_nchannels (CAComponentDescription& comp_desc)
|
||||||
0, &cinfo, &info_size);
|
0, &cinfo, &info_size);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -31,16 +31,12 @@ CoreAudioSource::CoreAudioSource (const XMLNode& node)
|
||||||
: AudioFileSource (node)
|
: AudioFileSource (node)
|
||||||
{
|
{
|
||||||
init (_name);
|
init (_name);
|
||||||
|
|
||||||
AudioSourceCreated (this); /* EMIT SIGNAL */
|
|
||||||
}
|
}
|
||||||
|
|
||||||
CoreAudioSource::CoreAudioSource (const string& idstr, Flag flags)
|
CoreAudioSource::CoreAudioSource (const string& idstr, Flag flags)
|
||||||
: AudioFileSource(idstr, flags)
|
: AudioFileSource(idstr, flags)
|
||||||
{
|
{
|
||||||
init (idstr);
|
init (idstr);
|
||||||
|
|
||||||
AudioSourceCreated (this); /* EMIT SIGNAL */
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,7 @@
|
||||||
#include <ardour/vst_plugin.h>
|
#include <ardour/vst_plugin.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNITS
|
||||||
#include <ardour/audio_unit.h>
|
#include <ardour/audio_unit.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
@ -513,7 +513,7 @@ PluginInsert::plugin_factory (boost::shared_ptr<Plugin> other)
|
||||||
#ifdef VST_SUPPORT
|
#ifdef VST_SUPPORT
|
||||||
boost::shared_ptr<VSTPlugin> vp;
|
boost::shared_ptr<VSTPlugin> vp;
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNITS
|
||||||
boost::shared_ptr<AUPlugin> ap;
|
boost::shared_ptr<AUPlugin> ap;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
@ -523,7 +523,7 @@ PluginInsert::plugin_factory (boost::shared_ptr<Plugin> other)
|
||||||
} else if ((vp = boost::dynamic_pointer_cast<VSTPlugin> (other)) != 0) {
|
} else if ((vp = boost::dynamic_pointer_cast<VSTPlugin> (other)) != 0) {
|
||||||
return boost::shared_ptr<Plugin> (new VSTPlugin (*vp));
|
return boost::shared_ptr<Plugin> (new VSTPlugin (*vp));
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNITS
|
||||||
} else if ((ap = boost::dynamic_pointer_cast<AUPlugin> (other)) != 0) {
|
} else if ((ap = boost::dynamic_pointer_cast<AUPlugin> (other)) != 0) {
|
||||||
return boost::shared_ptr<Plugin> (new AUPlugin (*ap));
|
return boost::shared_ptr<Plugin> (new AUPlugin (*ap));
|
||||||
#endif
|
#endif
|
||||||
|
|
@ -829,7 +829,7 @@ PluginInsert::type ()
|
||||||
#ifdef VST_SUPPORT
|
#ifdef VST_SUPPORT
|
||||||
boost::shared_ptr<VSTPlugin> vp;
|
boost::shared_ptr<VSTPlugin> vp;
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNITS
|
||||||
boost::shared_ptr<AUPlugin> ap;
|
boost::shared_ptr<AUPlugin> ap;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
@ -841,7 +841,7 @@ PluginInsert::type ()
|
||||||
} else if ((vp = boost::dynamic_pointer_cast<VSTPlugin> (other)) != 0) {
|
} else if ((vp = boost::dynamic_pointer_cast<VSTPlugin> (other)) != 0) {
|
||||||
return ARDOUR::VST;
|
return ARDOUR::VST;
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNITS
|
||||||
} else if ((ap = boost::dynamic_pointer_cast<AUPlugin> (other)) != 0) {
|
} else if ((ap = boost::dynamic_pointer_cast<AUPlugin> (other)) != 0) {
|
||||||
return ARDOUR::AudioUnit;
|
return ARDOUR::AudioUnit;
|
||||||
#endif
|
#endif
|
||||||
|
|
@ -1068,3 +1068,4 @@ PortInsert::input_streams() const
|
||||||
{
|
{
|
||||||
return n_outputs ();
|
return n_outputs ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -261,7 +261,7 @@ ARDOUR::find_plugin(Session& session, string name, long unique_id, PluginType ty
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_AUDIOUNITS
|
||||||
case ARDOUR::AudioUnit:
|
case ARDOUR::AudioUnit:
|
||||||
plugs = AUPluginInfo::discover ();
|
plugs = AUPluginInfo::discover ();
|
||||||
unique_id = 0; // Neither do AU.
|
unique_id = 0; // Neither do AU.
|
||||||
|
|
@ -282,3 +282,4 @@ ARDOUR::find_plugin(Session& session, string name, long unique_id, PluginType ty
|
||||||
|
|
||||||
return PluginPtr ((Plugin*) 0);
|
return PluginPtr ((Plugin*) 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -23,6 +23,10 @@
|
||||||
#include <ardour/destructive_filesource.h>
|
#include <ardour/destructive_filesource.h>
|
||||||
#include <ardour/configuration.h>
|
#include <ardour/configuration.h>
|
||||||
|
|
||||||
|
#ifdef HAVE_COREAUDIO
|
||||||
|
#include <ardour/coreaudiosource.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
#include "i18n.h"
|
#include "i18n.h"
|
||||||
|
|
||||||
using namespace ARDOUR;
|
using namespace ARDOUR;
|
||||||
|
|
@ -31,8 +35,6 @@ using namespace std;
|
||||||
sigc::signal<void,boost::shared_ptr<Source> > SourceFactory::SourceCreated;
|
sigc::signal<void,boost::shared_ptr<Source> > SourceFactory::SourceCreated;
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#ifdef HAVE_COREAUDIO
|
||||||
|
|
||||||
|
|
||||||
boost::shared_ptr<Source>
|
boost::shared_ptr<Source>
|
||||||
SourceFactory::create (const XMLNode& node)
|
SourceFactory::create (const XMLNode& node)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -253,7 +253,7 @@ path_expand (string path)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef HAVE_COREAUDIO
|
#if defined(HAVE_COREAUDIO) || defined(HAVE_AUDIOUNITS)
|
||||||
string
|
string
|
||||||
CFStringRefToStdString(CFStringRef stringRef)
|
CFStringRefToStdString(CFStringRef stringRef)
|
||||||
{
|
{
|
||||||
|
|
@ -297,4 +297,3 @@ compute_equal_power_fades (jack_nframes_t nframes, float* in, float* out)
|
||||||
in[n] = inVal * (scale * inVal + 1.0f - scale);
|
in[n] = inVal * (scale * inVal + 1.0f - scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue