Re: Multiple Connections to an Output Node
Re: Multiple Connections to an Output Node
- Subject: Re: Multiple Connections to an Output Node
- From: Robert Grant <email@hidden>
- Date: Thu, 6 Nov 2003 17:44:05 -0500
Craig,
If you don't know about it CAShow is a great utility for dumping CA
info.
Try
CAShow(mainGraph);
to see what's connected to what - or if there's trouble.
Also you might want to start checking return codes from the CA
functions.
Robert.
On Nov 6, 2003, at 4:24 PM, Craig Bakalian wrote:
Hi,
Well, I updated the code after some research, yet, it ain't working.
-(void)createOutputNodeForTracks
{
ComponentDescription mixer;
mixer.componentFlags = 0;
mixer.componentFlagsMask = 0;
mixer.componentType = kAudioUnitType_Mixer;
mixer.componentSubType = kAudioUnitSubType_StereoMixer;
mixer.componentManufacturer = kAudioUnitManufacturer_Apple;
AUNode mixerNode;
AUGraphNewNode(mainGraph, &mixer, 0, NULL, &mixerNode);
ComponentDescription outUnit;
outUnit.componentFlags = 0;
outUnit.componentFlagsMask = 0;
outUnit.componentType = kAudioUnitType_Output;
outUnit.componentSubType = kAudioUnitSubType_DefaultOutput;
outUnit.componentManufacturer = kAudioUnitManufacturer_Apple;
AUNode outPutNode;
AUGraphNewNode(mainGraph, &outUnit, 0, NULL, &outPutNode);
AUGraphConnectNodeInput(mainGraph, mixerNode, 0, outPutNode, 0);
AUGraphInitialize(mainGraph);
}
-(void)createSynthUnitForTrack: (MusicTrack)track
{
ComponentDescription synth;
synth.componentFlags = 0;
synth.componentFlagsMask = 0;
synth.componentType = kAudioUnitType_MusicDevice;
synth.componentSubType = kAudioUnitSubType_DLSSynth;
synth.componentManufacturer = kAudioUnitManufacturer_Apple;
AUNode synthNode;
AUGraphNewNode(mainGraph, &synth, 0, NULL, &synthNode);
[self setInternalReverbForSynthNode: synthNode isOn: NO ];
OSStatus err;
AUNode mixer;
err = AUGraphGetIndNode(mainGraph, 0, &mixer);
UInt32 i;
MusicSequenceGetTrackIndex(sequence, track, &i);
err = AUGraphConnectNodeInput(mainGraph, synthNode, 0, mixer, i);
///This is making a weird error!!!!!!
Boolean b;
AUGraphUpdate(mainGraph, &b);
AUGraphInitialize(mainGraph);
}
Craig Bakalian
www.eThinkingCap.com
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.