• 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
Instrument Number, Banks and DLS/Soundfonts
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Instrument Number, Banks and DLS/Soundfonts


  • Subject: Instrument Number, Banks and DLS/Soundfonts
  • From: Jeremy Sagan <email@hidden>
  • Date: Thu, 6 Mar 2003 18:49:52 -0500

Does anybody know the correspondence between kMusicDeviceProperty_InstrumentNumber, banks and soundfont MIDI bank control changes?

I use this to get the instrument number.

err = AudioUnitGetProperty(au, kMusicDeviceProperty_InstrumentNumber,
kAudioUnitScope_Global, i, &MDID, &outDataSize);

later I do this to get the bank

long newBank = MDID >> 7; // shift off the program part of the instrument number

and finally to change the bank I issue this MIDI command:

MSB = bank >> 7;
LSB = bank & 0x7F;
ControlChange (0xB0), 0, MSB and
ControlChange (0xB0), 32, LSB

The results are very unpredictable if the bank is not equal to zero. Some soundfonts switch to the correct instrument and others do not. Please tell me what I am doing wrong?

Also, does anyone know how to switch a regular MIDI channel into a drum channel (Bill? Sysex?) when using Apple's DLS MusicDevice?

Thanks,
Jeremy
_______________________________________________
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.

  • Prev by Date: midiunits?
  • Next by Date: Re: MIDI driver documentation/sample source code ?
  • Previous by thread: Re: midiunits?
  • Next by thread: Problem sending midi notes from virtual source
  • Index(es):
    • Date
    • Thread