pattern generation

Jun 27, 2006 at 12:27pm

pattern generation

I would like to generate notes from an algorithmic function, recordthe numbers for some time, and while playing the recorded pattern as a loop, recording a second number-pattern from the same function. I mange it with mtr, but mtr doesn’t play loops. Can anyone point me in a right direction.
Thanks
Pieter

#26582
Jun 27, 2006 at 1:44pm

seq~ i guess

#79715
Jun 27, 2006 at 2:29pm

Hi Pieter, have you though of storing your generated notes in a coll or a pattrstorage , use a counter to playback the stored items while you keep recording new lists of numbers in your coll or pattrstorage ?

here is a little, very simple example of how to do it in a coll , tweak it as you need , as i dont know how you plan to playback your notes , how many notes at a time etc…
though it is probably not what you are exactly looking for.

#P window setfont “Sans Serif” 9.;
#P window linecount 1;
#P hidden newex 376 50 48 196617 loadbang;
#P hidden message 377 71 43 196617 size 16;
#P hidden newex 565 64 20 196617 t b;
#P hidden newex 588 40 72 196617 receive range;
#P hidden newex 18 481 58 196617 send range;
#P hidden newex 18 453 29 196617 gate;
#P hidden newex 18 426 30 196617 > 16;
#P hidden message 588 64 43 196617 size $1;
#P number 273 638 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 239 638 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 205 638 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 171 638 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 171 610 76 196617 unpack 0 0 0 0;
#P comment 357 556 100 196617 plaid back lists;
#P hidden number 36 395 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 80 98 40 196617 t b b b;
#P newex 169 470 38 196617 zl join;
#P user multiSlider 171 526 178 73 0. 127. 4 2665 47 0 0 2 0 0 0;
#M frgb 255 252 59;
#M brgb 25 25 25;
#M rgb2 127 127 127;
#M rgb3 0 0 0;
#M rgb4 37 52 91;
#M rgb5 74 105 182;
#M rgb6 112 158 18;
#M rgb7 149 211 110;
#M rgb8 187 9 201;
#M rgb9 224 62 37;
#M rgb10 7 114 128;
#P objectname multiSlider[1];
#N coll ;
#P newobj 171 499 100 196617 coll;
#P number 765 182 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P toggle 735 93 36 0;
#P newex 735 213 58 196617 metro 500;
#P newex 152 335 36 196617 zl reg;
#N counter 16;
#X flags 0 0;
#P newobj 80 335 66 196617 counter 16;
#P newex 80 397 72 196617 prepend store;
#P newex 489 229 20 196617 t b;
#P window linecount 2;
#P message 512 229 50 196617 min 10 , max 14;
#P window linecount 1;
#P newex 512 208 62 196617 prepend set;
#P newex 434 135 27 196617 + 4;
#P newex 512 186 132 196617 sprintf min %ld\, max %ld;
#P number 631 331 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P button 631 265 15 0;
#N counter;
#X flags 0 0;
#P newobj 631 309 66 196617 counter;
#P user multiSlider 176 224 178 73 0. 127. 4 2665 47 0 0 2 0 0 0;
#M frgb 0 0 0;
#M brgb 219 255 9;
#M rgb2 127 127 127;
#M rgb3 0 0 0;
#M rgb4 37 52 91;
#M rgb5 74 105 182;
#M rgb6 112 158 18;
#M rgb7 149 211 110;
#M rgb8 187 9 201;
#M rgb9 224 62 37;
#M rgb10 7 114 128;
#P objectname multiSlider;
#P button 60 58 34 0;
#P newex 325 166 64 196617 random 127;
#P newex 260 166 64 196617 random 127;
#P newex 194 166 64 196617 random 127;
#P newex 128 166 64 196617 random 127;
#P newex 175 198 61 196617 pak 0 0 0 0;
#P user rslider 434 99 212 31 16 1 0 0 0;
#P window linecount 5;
#P comment 127 53 100 196617 1 – generate list of numbers ( in your case the ones coming from your algorythms );
#P window linecount 1;
#P comment 189 398 100 196617 store list in a coll;
#P window linecount 12;
#P comment 439 -56 100 196617 use this Rslider to read 4 items from the Coll consecutevelly. in other terms the counter is set so that you can choose for consecutive items in your coll ( o to 4 , 1 to 5 , 10 to 14 …or whatever suits you );
#P window linecount 2;
#P comment 775 94 100 196617 2- start playback of your lists here;
#P comment 819 180 100 196617 you can keep storing lists as you playback;
#P window linecount 5;
#P hidden comment 19 502 100 196617 this is just to keep the “size” of the Rslider growing once you stored more then 16 lists;
#P connect 27 0 25 1;
#P connect 26 0 25 0;
#P fasten 18 0 6 1 439 159 665 159 665 90 641 90;
#P fasten 18 0 17 1 439 166 639 166;
#P connect 14 0 16 0;
#P connect 15 0 14 0;
#P fasten 20 0 14 0 517 292 636 292;
#P fasten 25 0 15 0 740 247 636 247;
#P hidden connect 44 0 39 0;
#P hidden connect 43 0 39 0;
#P hidden connect 43 0 44 0;
#P connect 21 0 20 0;
#P connect 19 0 21 0;
#P connect 19 0 20 0;
#P connect 17 0 19 0;
#P connect 6 0 18 0;
#P fasten 6 0 17 0 439 174 517 174;
#P hidden fasten 39 0 6 0 593 93 439 93;
#P hidden connect 45 0 6 0;
#P hidden connect 46 0 45 0;
#P fasten 31 2 8 0 115 144 133 144;
#P fasten 31 2 9 0 115 144 199 144;
#P fasten 31 2 10 0 115 144 265 144;
#P fasten 31 2 11 0 115 144 330 144;
#P connect 34 3 38 0;
#P connect 34 2 37 0;
#P connect 11 0 7 3;
#P connect 10 0 7 2;
#P connect 34 1 36 0;
#P connect 24 0 30 1;
#P connect 9 0 7 1;
#P connect 13 0 24 1;
#P connect 7 0 13 0;
#P connect 8 0 7 0;
#P connect 34 0 35 0;
#P connect 29 0 34 0;
#P connect 28 0 29 0;
#P connect 30 0 28 0;
#P fasten 16 0 28 0 636 489 176 489;
#P connect 22 0 30 0;
#P connect 31 1 24 0;
#P hidden connect 23 0 32 0;
#P connect 23 0 22 0;
#P connect 31 0 23 0;
#P connect 12 0 31 0;
#P hidden connect 32 0 40 0;
#P hidden connect 32 0 41 1;
#P hidden connect 41 0 42 0;
#P hidden connect 40 0 41 0;
#P window clipboard copycount 47;

#79716
Jun 27, 2006 at 5:24pm

Great! Thanks for your answers.
Your patch, Karl-Otto, gives me a good basis for going on… although pattrstorage is still a bit above my skills.
Pieter

#79717

You must be logged in to reply to this topic.