[PD-dev] [ pure-data-Bugs-1911415 ] mrpeach/midifile writes invalid midi files

SourceForge.net noreply at sourceforge.net
Tue Mar 11 18:09:18 CET 2008


Bugs item #1911415, was opened at 2008-03-10 16:38
Message generated for change (Comment added) made by mrpeach
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=478070&aid=1911415&group_id=55736

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: externals
Group: None
>Status: Pending
Resolution: None
Priority: 5
Private: No
Submitted By: ClaudiusMaximus (claudiusmaximus)
Assigned to: Martin Peach (mrpeach)
Summary: mrpeach/midifile writes invalid midi files

Initial Comment:
The midifile external by Martin Peach writes invalid MIDI files that have a nasty habit of making other software crash.  The problem is in the header:

00000000  4d 54 68 64 00 00 00 06  00 00 00 01 00 00 4d 54  |MThd..........MT|

Which should be:

00000000  4d 54 68 64 00 00 00 06  00 00 00 01 ** ** 4d 54  |MThd..........MT|

Where **** is a valid MIDI file "time code" value, for example, 0x0060 for 96 ticks (I used hexedit to change it to this value and it mostly worked for what I was doing).

It would be good if midifile.c and midifile-help.pd could both be updated to:

1) disallow 0x0000 in the header
2) allow setting of the time code value in various ways (MIDI files support at least 'ticks' and 'SMPTE')
3) document and explain how to set the time code value

Thanks


----------------------------------------------------------------------

>Comment By: Martin Peach (mrpeach)
Date: 2008-03-11 13:09

Message:
Logged In: YES 
user_id=919007
Originator: NO

Changed to default 90 ticks per quarter note. Added frames per second and
ticks per frame fields to 'write' message. midifile-help shows how to set
these.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=478070&aid=1911415&group_id=55736




More information about the Pd-dev mailing list