Issues with Intel Macs and writing MIDI files from MusicSequence
Issues with Intel Macs and writing MIDI files from MusicSequence
- Subject: Issues with Intel Macs and writing MIDI files from MusicSequence
- From: "Ian.O'Keeffe" <email@hidden>
- Date: Thu, 9 Nov 2006 13:08:07 -0000
- Thread-topic: Issues with Intel Macs and writing MIDI files from MusicSequence
Afternoon.
Am experiencing difficulties with creating playable MIDI files from MusicSequence on Intel Macs. On PPC machines there are no problems. Indeed, a MIDI file created on a PPC plays fine on an Intel machine...
I am using writeToFile.
What would the effect be of/how do you use:
MusicSequenceSaveSMF(<#MusicSequence inSequence#>,<#const FSSpec * inFileSpec#>,<#UInt16 inResolution#>)
or
MusicSequenceSaveMIDIFile(<#MusicSequence inSequence#>,<#const FSRef * inParentDirectory#>,<#CFStringRef inFileName#>,<#UInt16 inResolution#>,<#UInt32 inFlags#>)
?
Would these functions get over the issue?
The issues seem small when the files are viewed in a Hex editor, just a big/little endian problem here and there (like in the MThd values for example), so a fix would be welcomed.
Generated on PPC:
4D546864 00000006 0001 0002 01E0 4D54726B 0000000B 00FF 5103 05740000FF2F004D54726B 00000089 00FF03044261737300C02000902464836080240000902564836080250000902664836080260000902764836080270000902864836080280000902964836080290000902A648360802A0000902B648360802B0000902C648360802C0000902D648360802D0000902E648360802E0000902F648360802F000090306483608030008360FF2F0000FF2F00
Generated on Intel Mac:
4D546864 06000000 0100 0200 E001 4D54726B 0B000000 00FF 5103 05740000FF2F004D54726B 89000000 00FF03044261737300C0200090246483608024BF0090256483608025BF0090266483608026BF0090276483608027BF0090286483608028BF0090296483608029BF00902A648360802ABF00902B648360802BBF00902C648360802CBF00902D648360802DBF00902E648360802EBF00902F648360802FBF0090306483608030BF8360FF2F0000FF2F00
NSString *midifile;
midifile = [NSString stringWithString: @"testMIDI.mid"];
if (![(NSData *)dataRef writeToFile:[NSString stringWithString: midifile] atomically:YES])
[NSException raise:@"main" format:@"Cannot save SMF."];
Kind regards,
Ian
<<winmail.dat>>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden