• R/O
  • SSH
  • HTTPS

alchemusica: Commit


Commit MetaInfo

Revision161 (tree)
Time2019-08-13 17:01:22
Authortoshinagata1964

Log Message

Improve handling of the internal audio format of the music devices

Change Summary

Incremental Difference

--- trunk/MD_package/MDAudio_MacOSX.c (revision 160)
+++ trunk/MD_package/MDAudio_MacOSX.c (revision 161)
@@ -670,22 +670,7 @@
670670 if (err == noErr) {
671671 propSize = sizeof(MDAudioFormat);
672672 err = AudioUnitGetProperty(unit, kAudioUnitProperty_StreamFormat, kAudioUnitScope_Output, 0, &info.format, &propSize);
673- if (err) {
674- err = AudioUnitSetProperty(unit, kAudioUnitProperty_StreamFormat, kAudioUnitScope_Output, 0, &gAudio->preferredFormat, sizeof(AudioStreamBasicDescription));
675- info.acceptsCanonicalFormat = 1;
676- info.format = gAudio->preferredFormat;
677- } else {
678- info.acceptsCanonicalFormat = 0;
679- }
680-
681- /* if (err != noErr) {
682- info.acceptsCanonicalFormat = 0;
683- propSize = sizeof(MDAudioFormat);
684- err = AudioUnitGetProperty(unit, kAudioUnitProperty_StreamFormat, kAudioUnitScope_Output, 0, &info.format, &propSize);
685- } else {
686- info.acceptsCanonicalFormat = 1;
687- info.format = gAudio->preferredFormat;
688- } */
673+ info.acceptsCanonicalFormat = sMDAudioCompareFormat(&info.format, &gAudio->preferredFormat);
689674 } else {
690675 unit = NULL;
691676 }
Show on old repository browser