hi nicholas
On Tue, 2007-07-17 at 10:59 +0100, nicholas ward wrote:
Hi all, Wondering if you could lend a hand. I have a patch with about 9
number boxes i vary over a 15 minute performance. I wish to record
the twiddling of these parameters so i can play back the performance.
there are a lot of approaches around, i think. you might want to have a look at [qlist], which would be my choice in your case (which is probably based only on my personal taste). [qlist] works very similar to [textfile], but it has some additional specialized functionality for sequencing purposes (or in other words: parameter automation purposes). the advantage of using [qlist], as opposed to the table approach, is that it doesn't use a time grid, but uses kind of a time stamp. the most difficult part about using [qlist] is, that you need to feed it with messages, that can be 'played back' by [qlist] afterwards. a line in [qlist] typically looks like this:
312 param1 65 <timestamp> <receiver> <value>
(<value> doesn't need to be a number, but it could also be a symbol or a list)
the timestamp is simply the delta-time to the previous line (in ms). that means, the value '65' is sent to the [r param1] 315ms after the previous line in your recorded sequence.
in order to record your 9 numberboxes, you need to generate such (as shown above) messages, that are sent to [qlist]. that means, you need to assign a receiver-name (e.g. 'param1') to each of your numberboxes. then you need to measure each time between two events. this can easily be achieved with [timer]. then you need to prepend the output of [timer] to your messages with [list prepend].
the output would look like something like this:
2349 param2 12 94 param1 127 304 param3 34 10 param3 35 12 param3 36
send this over a [list prepend add]-[list trim] to [qlist].
when playing back, the recorded numbers are sent to the correspondent receivers ([r param1], [r param2] etc) with the exact order in time you as you recorded them.
if that doesn't help you already, i can build you an examle patch.
I was about to start this using an individual table for each
parameter and tabwrite tab read but wondered if there might be a more
effecient method. I havent really looked at data structures but
wonder if perhaps these may hold the answer?
i never used ds myself, but how i understand them, their strength is mainly in representing data. so, when you just need to record data, but you don't need to visualize them, ds might be kind of an overkill. please correct me, if i am wrong.
cheers roman
___________________________________________________________ Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de