hello,
rj-library, the help file for [c_seqplay] contains an example how to convert a midi file to a text file, that [qlist] can read (using Cyclon's [seq] instead of [midifile]). Once you have the qlist-file, you can reverse it using for example the "tac" command in Linux/OS-X - "tac" is the opposite of "cat".
yeah this is nice. I will have to try it out this week when i get the chance....
This actually isn't too hard if some external tools are allowed.
yeah i have been using 'gnmidi' on windows to reverse midi files and do some other manipulations on them. also there is an interesting keykit webapp that does some nice stuff (http://www.nosuch.com/tjt/tunetoys.html) ... ableton also has added some nice midi functionality.
i was trying to figure out how to do some of these things (reversing, random tick sequence) directly in PD with midifile but i get a lot of hangs...
Actually doing it might be difficult though - MIDI
files have
variable-length fields, so you probably have to decode
*all* of it into
some other format or data structure before you start
playing from the
end.
... with this in mind. so, yeah, the midi -> text file / qlist stuff looks more promising...
Thanks for the responses! mark
--- On Mon, 11/2/09, Frank Barknecht fbar@footils.org wrote:
From: Frank Barknecht fbar@footils.org Subject: Re: [PD] midifile ... in reverse To: pd-list@iem.at Date: Monday, November 2, 2009, 4:35 AM Hallo, Claude Heiland-Allen hat gesagt: // Claude Heiland-Allen wrote:
mark edward grimm wrote:
Is is possible to play a midifile in reverse
Sure, if you want each note-off message to happen
before its
corresponding note-on messages!
Actually doing it might be difficult though - MIDI
files have
variable-length fields, so you probably have to decode
*all* of it into
some other format or data structure before you start
playing from the
end.
This actually isn't too hard if some external tools are allowed. In the rj-library, the help file for [c_seqplay] contains an example how to convert a midi file to a text file, that [qlist] can read (using Cyclon's [seq] instead of [midifile]). Once you have the qlist-file, you can reverse it using for example the "tac" command in Linux/OS-X - "tac" is the opposite of "cat".
As qlist-files encode delta times or times between events, loading this reversed file into qlist will make it play back the whole midi file backwards.
As you noted, the notoffs then happen before the noteoffs, so some additional tweaking may be wanted, either to the file format or to your Pd player logic.
Ciao
Frank
Pd-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list