Hi PeeDee List, here's what I'm trying to accomplish:
At first I thought I could do this with a few Tabwrites and Tabplays in parallel, but
time? Would it get confused, or does MIDI do some kind of "staggering" where exactly one MIDI message is coming in at a time?
basically have to increase the size of the table by 1 at the MIDI control rate (500 Hz or whatever it is). I was concerned that this might lead to glitches.
At any rate, it seems like a fairly common task to accomplish, so I thought I'd ask here before reinventing the wheel...
Thanks for any thoughts! rs
Hi Ryan,
Ryan Supak wrote:
Hi PeeDee List, here's what I'm trying to accomplish:
- Record a MIDI stream of a non-predetermined length
- Play said MIDI stream back on-the-fly
At first I thought I could do this with a few Tabwrites and Tabplays in parallel, but
- then I thought "What if, say, CC25 and CC35 are coming in at the same
time? Would it get confused, or does MIDI do some kind of "staggering" where exactly one MIDI message is coming in at a time?
I'm don't have much experience with MIDI-devices, but in theory, one MIDI stream is always a serial stream, which means that you receive one command after another one (with appr. 31kBaud). I don't think your commands can get staggered.
- to create a variable-sized buffer with Tabwrite, it seems like I
would basically have to increase the size of the table by 1 at the MIDI control rate (500 Hz or whatever it is). I was concerned that this might lead to glitches.
Can you estimate a maximal length you need? You can get max. 5000 commands per second per stream with MIDI. Thus, thinking in terms of audio it's rather low rate - it's not a problem to allocate a table with length of, say, 500,000 at the begin of recording - which gives you a range up to 100 seconds.
br,
Piotr
i believe it can be done internally in pd, but may require a fair bit of work. i would personally suggest using an auxilary midi sequequencer and reroute the recording/playback through to it.
this can easily be achieved using virmidi and your choice of sequencer (rosegarden / muse / etc) on a gnu/linux workstation, or a similar virtual midi type app on a proprietry setup.
ciao..
dmotd
Ryan Supak wrote:
Hi PeeDee List, here's what I'm trying to accomplish:
- Record a MIDI stream of a non-predetermined length
- Play said MIDI stream back on-the-fly
At first I thought I could do this with a few Tabwrites and Tabplays in parallel, but
- then I thought "What if, say, CC25 and CC35 are coming in at the
same time? Would it get confused, or does MIDI do some kind of "staggering" where exactly one MIDI message is coming in at a time? 2) to create a variable-sized buffer with Tabwrite, it seems like I would basically have to increase the size of the table by 1 at the MIDI control rate (500 Hz or whatever it is). I was concerned that this might lead to glitches.
At any rate, it seems like a fairly common task to accomplish, so I thought I'd ask here before reinventing the wheel... Thanks for any thoughts! rs
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
Hallo, Ryan Supak hat gesagt: // Ryan Supak wrote:
Hi PeeDee List, here's what I'm trying to accomplish:
- Record a MIDI stream of a non-predetermined length
- Play said MIDI stream back on-the-fly
See ds-sequencer.pd at: http://royalrabbit.goto10.org/svn/goto10/pd-patches/fbar/pipeseq/ You need the other patches there as well, ds-sequencer.pd is the main app, no externals are used.
It records midi notes into a data structure window, which you can play back and also overdub on the fly. Currently the midi channel number is not recorded, but this would be trivial to add (there already is a field in the data struct for this.)
Alternatively you could record to a [qlist].
Frank Barknecht _ ______footils.org_ __goto10.org__
Thanks Gang,
I'll give [qlist] a shot -- it occurred to me that there are certain things I can do to optimize the input stream.
I'm thinking maybe the creation an alloca - based "buffer" external is in order. Now where did I put that C manual?
rs
On 10/14/05, Frank Barknecht fbar@footils.org wrote:
Hallo, Ryan Supak hat gesagt: // Ryan Supak wrote:
Hi PeeDee List, here's what I'm trying to accomplish:
- Record a MIDI stream of a non-predetermined length
- Play said MIDI stream back on-the-fly
See ds-sequencer.pd at: http://royalrabbit.goto10.org/svn/goto10/pd-patches/fbar/pipeseq/ You need the other patches there as well, ds-sequencer.pd is the main app, no externals are used.
It records midi notes into a data structure window, which you can play back and also overdub on the fly. Currently the midi channel number is not recorded, but this would be trivial to add (there already is a field in the data struct for this.)
Alternatively you could record to a [qlist].
Ciao
Frank Barknecht _ ______footils.org_ __goto10.org__
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list