Commit 975ee452 authored by Ryan C. Gordon's avatar Ryan C. Gordon

Since we're not using the CoreAudio HAL now, we don't need to use EnableIO.

I think that's how it works.

Fixes failure to open audio device on Mac OS X.

--HG--
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%404388
parent 25ed4371
...@@ -420,7 +420,6 @@ prepare_audiounit(_THIS, const char *devname, int iscapture, ...@@ -420,7 +420,6 @@ prepare_audiounit(_THIS, const char *devname, int iscapture,
AURenderCallbackStruct callback; AURenderCallbackStruct callback;
ComponentDescription desc; ComponentDescription desc;
Component comp = NULL; Component comp = NULL;
UInt32 enableIO = 0;
const AudioUnitElement output_bus = 0; const AudioUnitElement output_bus = 0;
const AudioUnitElement input_bus = 1; const AudioUnitElement input_bus = 1;
const AudioUnitElement bus = ((iscapture) ? input_bus : output_bus); const AudioUnitElement bus = ((iscapture) ? input_bus : output_bus);
...@@ -449,22 +448,6 @@ prepare_audiounit(_THIS, const char *devname, int iscapture, ...@@ -449,22 +448,6 @@ prepare_audiounit(_THIS, const char *devname, int iscapture,
this->hidden->audioUnitOpened = 1; this->hidden->audioUnitOpened = 1;
// !!! FIXME: this is wrong?
enableIO = ((iscapture) ? 1 : 0);
result = AudioUnitSetProperty(this->hidden->audioUnit,
kAudioOutputUnitProperty_EnableIO,
kAudioUnitScope_Input, input_bus,
&enableIO, sizeof(enableIO));
CHECK_RESULT("AudioUnitSetProperty (kAudioUnitProperty_EnableIO input)");
// !!! FIXME: this is wrong?
enableIO = ((iscapture) ? 0 : 1);
result = AudioUnitSetProperty(this->hidden->audioUnit,
kAudioOutputUnitProperty_EnableIO,
kAudioUnitScope_Output, output_bus,
&enableIO, sizeof(enableIO));
CHECK_RESULT("AudioUnitSetProperty (kAudioUnitProperty_EnableIO output)");
result = AudioUnitSetProperty(this->hidden->audioUnit, result = AudioUnitSetProperty(this->hidden->audioUnit,
kAudioOutputUnitProperty_CurrentDevice, kAudioOutputUnitProperty_CurrentDevice,
kAudioUnitScope_Global, 0, kAudioUnitScope_Global, 0,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment