• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
kMusicDeviceProperty_InstrumentCount
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

kMusicDeviceProperty_InstrumentCount


  • Subject: kMusicDeviceProperty_InstrumentCount
  • From: Craig Bakalian <email@hidden>
  • Date: Thu, 30 Oct 2003 09:50:31 -0500

Hi,
I know this code isn't working. I am getting a -50 on there err. I
am sure this type of question has been answered before but, how does
one get the instrument count of Apple's DLSSynth?

ComponentDescription synth;
synth.componentFlags = 0;
synth.componentFlagsMask = 0;
synth.componentType = kAudioUnitType_MusicDevice;
synth.componentSubType = kAudioUnitSubType_DLSSynth;
synth.componentManufacturer = kAudioUnitManufacturer_Apple;
AUNode synthNode;
AUGraphNewNode(graph, &synth, 0, NULL, &synthNode);

the above is popped first into a AUGraph called graph.

I am using this code to get the instrument count with a -50.

-(NSArray *)instrumentArray
{
AUNode synthNode;
AudioUnit theSynth;
UInt32 count =0;
UInt32 size = 0;

OSStatus err;
AUGraphGetIndNode(graph, 0, &synthNode);
err = AUGraphGetNodeInfo(graph, synthNode, NULL, NULL, NULL,
&theSynth);
err = AudioUnitGetProperty(theSynth,
kMusicDeviceProperty_InstrumentCount, kAudioUnitScope_Output, 2,
&count, &size);
NSLog(@"%d", err);

return blahblah...
}




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.

  • Follow-Ups:
    • Re: kMusicDeviceProperty_InstrumentCount
      • From: Jeremy Sagan <email@hidden>
    • Re: kMusicDeviceProperty_InstrumentCount
      • From: Marc Poirier <email@hidden>
  • Prev by Date: Re: Progress bar in Audio Unit, crashes Logic
  • Next by Date: Re: kMusicDeviceProperty_InstrumentCount
  • Previous by thread: AUHosting doesn't clean up AU graph on quit
  • Next by thread: Re: kMusicDeviceProperty_InstrumentCount
  • Index(es):
    • Date
    • Thread