I've done a quick search on the archive for help on this topic, but I didn't find anything crystal clear.
Basically, I'm running a PD patch on a Mac which is sending (internally, not through hardware) MIDI note on/off pairs to another program (Arkaos). I would like to be able to capture the MIDI stream within PD (or the numeric values on which the MIDI notes are based) into a file for later retrieval. So
is there a purpose-built object which will handle this? or
can a file be written to disc as a qlist? If so, could someone
describe how to write such a file?
Any help will be greatly appreciated.
Many thanks,
--Richard.
You could use timer combined with list to record a sequence (see the sequencers in the list example docs) and then write the final message to disk using textfile.
~Kle
On 10/11/06, Richard Bowers richard.bowers@ntlworld.com wrote:
I've done a quick search on the archive for help on this topic, but I didn't find anything crystal clear.
Basically, I'm running a PD patch on a Mac which is sending (internally, not through hardware) MIDI note on/off pairs to another program (Arkaos). I would like to be able to capture the MIDI stream within PD (or the numeric values on which the MIDI notes are based) into a file for later retrieval. So
is there a purpose-built object which will handle this? or
can a file be written to disc as a qlist? If so, could someone describe
how to write such a file?
Any help will be greatly appreciated.
Many thanks,
--Richard.
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
Hallo, Richard Bowers hat gesagt: // Richard Bowers wrote:
Basically, I'm running a PD patch on a Mac which is sending (internally, not through hardware) MIDI note on/off pairs to another program (Arkaos). I would like to be able to capture the MIDI stream within PD (or the numeric values on which the MIDI notes are based) into a file for later retrieval. So
is there a purpose-built object which will handle this? or
can a file be written to disc as a qlist? If so, could someone
describe how to write such a file?
You can write a qlist's content using "write FILENAME", but I guess, you know this already. The important thing to remember with qlist is that it stores lists conisting of at least three elements: First the "Inter Onset Interval" or IOI, which is the time between successive events, then the name of a receiver, which receives the qlist data, if the qlist is playing back, and after that the actual data to record:
qlist: IOI receiver data ...
"data" can be a list itself, in your case it is a note events consisting of note number and velocities. Then you need to build the other two elements: Just decide on a receiver name (attached patch uses "NOTEIN") and calculate the IOI. IOI-calculation is very simply done by double-banging a [timer]:
"events, events, ..." | [t b b] | | [timer] | "IOI"
At the start of a recording, you should reset the [timer] to 0 through its left(!) inlet, and you should "clear" the qlist.
Attached is a working example, but maybe you want to try to build a qlist-recorder on your own first. It shouldn't be too hard if you follow the hints above.
Frank Barknecht _ ______footils.org_ __goto10.org__
Many, many thanks, Frank (and Kyle). I'll get on the case when I'm more alert. Tiredness can kill when driving PD ... So I'll pick up the thread tomorrow.
--Richard.
-----Original Message----- From: pd-list-bounces@iem.at [mailto:pd-list-bounces@iem.at] On Behalf Of Frank Barknecht Sent: 11 October 2006 22:14 To: pd-list@iem.at Subject: Re: [PD] Writing a MIDI file...or at least a qlist...to disc
Hallo, Richard Bowers hat gesagt: // Richard Bowers wrote:
Basically, I'm running a PD patch on a Mac which is sending (internally, not through hardware) MIDI note on/off pairs to another program (Arkaos). I would like to be able to capture the MIDI stream within PD (or the numeric values on which the MIDI notes are based) into a file for later retrieval. So
is there a purpose-built object which will handle this? or
can a file be written to disc as a qlist? If so, could someone
describe how to write such a file?
You can write a qlist's content using "write FILENAME", but I guess, you know this already. The important thing to remember with qlist is that it stores lists conisting of at least three elements: First the "Inter Onset Interval" or IOI, which is the time between successive events, then the name of a receiver, which receives the qlist data, if the qlist is playing back, and after that the actual data to record:
qlist: IOI receiver data ...
"data" can be a list itself, in your case it is a note events consisting of note number and velocities. Then you need to build the other two elements: Just decide on a receiver name (attached patch uses "NOTEIN") and calculate the IOI. IOI-calculation is very simply done by double-banging a [timer]:
"events, events, ..." | [t b b] | | [timer] | "IOI"
At the start of a recording, you should reset the [timer] to 0 through its left(!) inlet, and you should "clear" the qlist.
Attached is a working example, but maybe you want to try to build a qlist-recorder on your own first. It shouldn't be too hard if you follow the hints above.
Frank Barknecht _ ______footils.org_ __goto10.org__
Thanks to you all for your help.
I've stripped down Kyle's patch (because I understood it - also I had a little trouble with Frank's patch - Pd couldn't create certain objects).
It does exactly what I need. I'm assuming the size of the file will be limited to available memory, is that right? I shall give it a thorough test tomorrow to see if it holds up.
And thank you, Martin, for pointing me towards the midifile object. I shall take a look at this when I'm in less of a hurry.
Best,
Rwb.
Hallo, Richard Bowers hat gesagt: // Richard Bowers wrote:
I've stripped down Kyle's patch (because I understood it - also I had a little trouble with Frank's patch - Pd couldn't create certain objects).
You're using a Pd in version older than pd-0.39, right? Then all the [list]-objects won't create.
I would really recommend to upgrade to a list-enabled Pd. It has enlightement included.
Frank Barknecht _ ______footils.org_ __goto10.org__
Thanks. You're absolutely right. 0.38.4 extended (this is on my PC - my colleagues with the Macs should have the latest release). --rwb -----Original Message----- Hallo, Richard Bowers hat gesagt: // Richard Bowers wrote:
I've stripped down Kyle's patch (because I understood it - also I had a little trouble with Frank's patch - Pd couldn't create certain objects).
You're using a Pd in version older than pd-0.39, right? Then all the [list]-objects won't create.
I would really recommend to upgrade to a list-enabled Pd. It has enlightement included.
Frank Barknecht _ ______footils.org_ __goto10.org__
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
Frank Barknecht a écrit :
Hallo, Richard Bowers hat gesagt: // Richard Bowers wrote:
I've stripped down Kyle's patch (because I understood it - also I had a little trouble with Frank's patch - Pd couldn't create certain objects).
You're using a Pd in version older than pd-0.39, right? Then all the [list]-objects won't create.
I would really recommend to upgrade to a list-enabled Pd. It has enlightement included.
Ciao
Hello, this is not really in the topic, what about replacing [tosymbol] and [fromsymbol] used in rradical/OSCprepend by [list]-objects, or something else. Many other people would then be able to use rradical, without having to replace these two objects that uses to crash pd (on win32 at least). And rradical will only need too externals, if I'm right, [pool] and OSCx. Patco.
___________________________________________________________________________ Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions ! Demandez à ceux qui savent sur Yahoo! Questions/Réponses http://fr.answers.yahoo.com
Hallo, megalegoland hat gesagt: // megalegoland wrote:
Hello, this is not really in the topic, what about replacing [tosymbol] and [fromsymbol] used in rradical/OSCprepend by [list]-objects, or something else. Many other people would then be able to use rradical, without having to replace these two objects that uses to crash pd (on win32 at least).
Oh, adapting RRADical for list is on my TODO-List. There is a version of OSCprepend in the list-abs collection already, but there are some other issues I would like to reimplement as well (for example maybe using settable sends).
However I'm a bit reluctant to do too many changes now, as I would like to marry sssad and Memento and I need to do some thinking about this first.
Frank Barknecht _ ______footils.org_ __goto10.org__
Hello, Frank Barknecht a écrit :
Hallo,
Oh, adapting RRADical for list is on my TODO-List. There is a version of OSCprepend in the list-abs collection already,
Oh I didn't pay attention to it, ...
but there are some other issues I would like to reimplement as well (for example maybe using settable sends).
Well, I use to send data with OSC, it is relatively easy to format message into OSCx, but unfortunately we're obliged to use [commun] with only one routing:
[commun /MyAbstraction/MyValue $0] doesn't work [commun /MyAbstraction-MyValue $0] works
Then if we want to have values recall on the remote patch, at a preset change, we have to use both format (/MyAbstraction-MyValue for sending, /MyAbstraction/MyValue for receiving) there might be other solutions but I didn't figured it out yet, fortunately the $1$2$3... feature of pd-40 saves a lot of time and room for patching these kind of objects.
However I'm a bit reluctant to do too many changes now, as I would like to marry sssad and Memento and I need to do some thinking about this first.
Great, then memento would work with pd core. Patco/
___________________________________________________________________________ Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions ! Demandez à ceux qui savent sur Yahoo! Questions/Réponses http://fr.answers.yahoo.com
Hallo, megalegoland hat gesagt: // megalegoland wrote:
However I'm a bit reluctant to do too many changes now, as I would like to marry sssad and Memento and I need to do some thinking about this first.
Great, then memento would work with pd core.
That's the goal. Saving itself should be independent from the system and should be "pluggable", so that you can save into a pool as well as into a textfile or a message box. This already is possible with sssad but sssad lacks some convenience functions of Memento, and I would like to keep all RRADical patches working with minimal changes.
Frank Barknecht _ ______footils.org_ __goto10.org__
On 10/12/06, Frank Barknecht fbar@footils.org wrote:
I would really recommend to upgrade to a list-enabled Pd. It has enlightement included.
Frank, what's "enlightenment"?
Mike
Ciao
Frank Barknecht _ ______footils.org_ __goto10.org__
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
I hope that was a (second) joke!
~Kyle
On 10/13/06, Mike McGonagle mjmogo@gmail.com wrote:
On 10/12/06, Frank Barknecht fbar@footils.org wrote:
I would really recommend to upgrade to a list-enabled Pd. It has enlightement included.
Frank, what's "enlightenment"?
Mike
Ciao
Frank Barknecht _ ______footils.org_ __goto10.org__
PD-list@iem.at mailing list UNSUBSCRIBE and account-management ->
http://lists.puredata.info/listinfo/pd-list
-- Help the Environment, Plant a Bush back in Texas!
"I place economy among the first and most important republican virtues, and public debt as the greatest of the dangers to be feared. To preserve our independence, we must not let our rulers load us with perpetual debt." -- Thomas Jefferson, third US president, architect and author (1743-1826)
"Give Peace a Chance" -- John Lennon (9 October 1940 – 8 December 1980)
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
Actually I heard Miller say that he was holding off on the "enlightenment" features for Pd until version 1.0.
...so in about 15 years.
~Kyle
On 10/13/06, Mike McGonagle mjmogo@gmail.com wrote:
On 10/12/06, Frank Barknecht fbar@footils.org wrote:
I would really recommend to upgrade to a list-enabled Pd. It has enlightement included.
Frank, what's "enlightenment"?
Mike
Ciao
Frank Barknecht _ ______footils.org_ __goto10.org__
PD-list@iem.at mailing list UNSUBSCRIBE and account-management ->
http://lists.puredata.info/listinfo/pd-list
-- Help the Environment, Plant a Bush back in Texas!
"I place economy among the first and most important republican virtues, and public debt as the greatest of the dangers to be feared. To preserve our independence, we must not let our rulers load us with perpetual debt." -- Thomas Jefferson, third US president, architect and author (1743-1826)
"Give Peace a Chance" -- John Lennon (9 October 1940 – 8 December 1980)
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
Hallo, Mike McGonagle hat gesagt: // Mike McGonagle wrote:
On 10/12/06, Frank Barknecht fbar@footils.org wrote:
I would really recommend to upgrade to a list-enabled Pd. It has enlightement included.
Frank, what's "enlightenment"?
Good question.
I'll try to limit my answer to [list]: Studying and using [list] is a good way to understand the message system of Pd (meta-messages etc.) not only theoretically, but by making actual use of it. One step on the road to enlightenment could be to use [list prepend] instead of [swap]. Then you may start to replace a lot more objects in your patches with variants of [list]. For example most of the time I was using [symbol] in the past I'm now using [list].
An important step may be to put [list trim] in front of most instances of [route] you use, because this leads to the next bigger step:
Which is to realize that by letting messages pass through a [list] object they enter a realm where all messages are list-messages and start to be very nice and friendly to each other. Here the real message-work can be done in a way, that simply feels good, because everyone understands each other.
By sending them through a [list trim] later on they leave this friendly world and start to become very powerful, but also possibly dangerous meta-messages. It's a cruel world out there, but you already know that there also is a different one.
Maybe then the final step would be to use Lisp instead of Pd. Or Forth.
Or just to ignore my silly ramblings and listen to a Joanna Newsom record instead. ;)
Frank Barknecht _ ______footils.org_ __goto10.org__
Richard Bowers wrote:
I've done a quick search on the archive for help on this topic, but I didn't find anything crystal clear.
Basically, I'm running a PD patch on a Mac which is sending (internally, not through hardware) MIDI note on/off pairs to another program (Arkaos). I would like to be able to capture the MIDI stream within PD (or the numeric values on which the MIDI notes are based) into a file for later retrieval. So
- is there a purpose-built object which will handle this? or
There's [midifile] in cvs at externals/mrpeach/midifile. (or here : http://pure-data.iem.at/Members/martinrp/midifile) I don't know if it compiles on OS X but it should.
- can a file be written to disc as a qlist? If so, could someone
describe how to write such a file?
You could take the outputs of [notein], [pack] them into a list along with some kind of time counter, and add them to a qlist.
Martin