Tap Tempo, with fail
Someone (can't find thread now) was talking about wanting a tap tempo that kept all the human failings. I thought it was a good idea so I sat down and had a go at knocking one out - here it is.
It takes 9 taps (yielding 8 durations, so superficially it's tied to 2 repeating bars of beats in 4/4 though of course given that you can tap out any rhythm in those 8 beasts, you can feed it any meter you like). Also it's scaleable. I nicked hardoff's toggle because I thought it was pretty.
You could probably "improve" it by resetting the metro counter on tap 8 (so that the metro immediately goes into your sequence as you finish. That's probably a matter of taste though.
#N canvas 302 0 701 714 10;
#X obj 91 370 counter;
#X floatatom 91 395 5 0 0 0 - - -;
#X obj 135 220 t b b;
#X obj 54 102 bng 15 250 50 0 empty empty empty 17 7 0 10 -258113 -262144
-262130;
#X floatatom 174 389 5 0 0 0 - - -;
#X obj 135 285 moses 1;
#X obj 135 264 realtime;
#X obj 71 242 delay 1500;
#X obj 174 304 moses 1500;
#X obj 174 325 t b f;
#X obj 129 418 pack f f;
#X obj 114 505 f;
#X obj 129 526 f;
#X obj 144 545 f;
#X obj 160 505 f;
#X obj 175 526 f;
#X obj 190 545 f;
#X obj 206 507 f;
#X obj 221 526 f;
#X obj -53 571 metro 400;
#X obj -53 596 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
-1 -1;
#X obj -53 620 s \$1-drunkmetro-step;
#X obj -15 290 r \$1-drunkmetro-step;
#X obj -15 351 counter;
#X obj 38 102 tgl 15 0 \$0-toggle \$0-toggle-r OFF -30 8 0 13 -262144
-262144 -1 0 1;
#X obj -73 317 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
-1 -1;
#X floatatom -15 374 5 0 0 0 - - -;
#X obj 129 469 route 0 1 2 3 4 5 6 7;
#X obj 62 441 select 0 1 2 3 4 5 6 7;
#X obj 45 338 select 7;
#X obj -41 320 select 7;
#X obj -76 659 outlet;
#X obj 189 143 s \$0-toggle-r;
#X obj 128 72 sel 0 1;
#X obj 126 50 r \$0-toggle;
#X msg 302 101 color \$1 \$1 -1;
#X msg 291 68 0;
#X msg 323 68 18;
#X msg 128 100 label OFF;
#X msg 210 101 label ON;
#X obj -1 535 *;
#X obj 4 119 hsl 52 10 4 0.25 1 0 blawhoof \$0-sliderinit empty -2
-8 0 10 -258113 -1 -1 0 1;
#X obj 14 511 r blawhoof;
#X floatatom 78 579 5 0 0 0 - - -;
#X obj 59 119 bng 10 250 50 0 ahr empty empty 17 7 0 10 -262144 -1
-1;
#X msg 55 166 1;
#X obj 53 199 s \$0-sliderinit;
#X obj 77 138 loadbang;
#X connect 0 0 1 0;
#X connect 0 0 29 0;
#X connect 1 0 10 0;
#X connect 2 0 6 0;
#X connect 2 0 7 0;
#X connect 2 1 6 1;
#X connect 3 0 2 0;
#X connect 4 0 10 1;
#X connect 5 1 8 0;
#X connect 6 0 5 0;
#X connect 7 0 6 0;
#X connect 7 0 0 2;
#X connect 8 0 9 0;
#X connect 9 0 0 0;
#X connect 9 1 4 0;
#X connect 10 0 27 0;
#X connect 11 0 40 0;
#X connect 12 0 40 0;
#X connect 13 0 40 0;
#X connect 14 0 40 0;
#X connect 15 0 40 0;
#X connect 16 0 40 0;
#X connect 17 0 40 0;
#X connect 18 0 40 0;
#X connect 19 0 20 0;
#X connect 20 0 21 0;
#X connect 20 0 31 0;
#X connect 22 0 23 0;
#X connect 23 0 26 0;
#X connect 23 0 30 0;
#X connect 24 0 19 0;
#X connect 24 0 25 0;
#X connect 25 0 23 3;
#X connect 26 0 28 0;
#X connect 27 0 11 1;
#X connect 27 1 12 1;
#X connect 27 2 13 1;
#X connect 27 3 14 1;
#X connect 27 4 15 1;
#X connect 27 5 16 1;
#X connect 27 6 17 1;
#X connect 27 7 18 1;
#X connect 28 0 11 0;
#X connect 28 1 12 0;
#X connect 28 2 13 0;
#X connect 28 3 14 0;
#X connect 28 4 15 0;
#X connect 28 5 16 0;
#X connect 28 6 17 0;
#X connect 28 7 18 0;
#X connect 29 0 0 2;
#X connect 30 0 23 2;
#X connect 33 0 38 0;
#X connect 33 0 36 0;
#X connect 33 1 39 0;
#X connect 33 1 37 0;
#X connect 34 0 33 0;
#X connect 35 0 32 0;
#X connect 36 0 35 0;
#X connect 37 0 35 0;
#X connect 38 0 32 0;
#X connect 39 0 32 0;
#X connect 40 0 19 1;
#X connect 42 0 40 1;
#X connect 42 0 43 0;
#X connect 44 0 45 0;
#X connect 45 0 46 0;
#X connect 47 0 45 0;
#X coords 0 -1 1 1 70 31 2 0 100;
My live patch
this is old... BUT
when I try to open this I get this error:
spigot~
... couldn't create
spigot~
... couldn't create
spigot~
... couldn't create
spigot~
... couldn't create
spigot~
... couldn't create
spigot~
... couldn't create
wahwah~: an audio wahwah, version 0.1 (ydegoyon@free.fr)
spigot~
... couldn't create
spigot~
... couldn't create
spigot~
... couldn't create
spigot~
... couldn't create
expr, expr~, fexpr~ version 0.4 under GNU General Public License
[makesymbol] part of zexy-2.2.1 (compiled: Jul 21 2008)
Copyright (l) 1999-2007 IOhannes m zmölnig, forum::für::umläute & IEM
[msgfile] part of zexy-2.2.1 (compiled: Jul 21 2008)
Copyright (l) 1999-2007 IOhannes m zmölnig, forum::für::umläute & IEM
[list2symbol] part of zexy-2.2.1 (compiled: Jul 21 2008)
Copyright (l) 1999-2007 IOhannes m zmölnig, forum::für::umläute & IEM
[folder_list] $Revision: 1.12 $
written by Hans-Christoph Steiner <hans@at.or.at>
compiled on Jul 21 2008 at 06:08:28
setting pattern to default: C:/Users/Cody/Desktop/ma4u/*
error: signal outlet connect to nonsignal inlet (ignored)
... you might be able to track this down from the Find menu.
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
error: signal outlet connect to nonsignal inlet (ignored)
expr divide by zero detected
whats up?
Converting a text file to .pd
hey, I got this off the pd-list...
a harmonizer by Thomas Musil
#N canvas 604 25 697 942 12;
#X obj 409 49 delwrite~ b1 5000;
#X obj 109 526 vd~ b1;
#X obj 107 314 phasor~;
#X obj 107 391 *~ -1;
#X obj 108 416 +~ 1;
#X obj 125 561 sig~ 1;
#X obj 190 560 cos~;
#X obj 126 585 -~;
#X obj 127 610 *~ 0.5;
#X obj 108 635 *~;
#X obj 206 836 dac~;
#X obj 142 473 samphold~;
#X obj 108 500 *~;
#X obj 143 445 sig~;
#X floatatom 103 262 10 0 0 0 - - -;
#X floatatom 266 218 5 0 0 0 - - -;
#X obj 249 253 t b f;
#X obj 229 371 / 44.1;
#X obj 344 527 vd~ b1;
#X obj 342 392 *~ -1;
#X obj 343 417 +~ 1;
#X obj 360 562 sig~ 1;
#X obj 424 562 cos~;
#X obj 361 586 -~;
#X obj 362 611 *~ 0.5;
#X obj 343 636 *~;
#X obj 377 474 samphold~;
#X obj 343 501 *~;
#X obj 378 446 sig~;
#X obj 339 344 +~ 0.5;
#X obj 339 366 wrap~;
#X obj 409 13 adc~;
#X obj 142 289 expr (pow(2 \, ($f2/12)) - 1) * 44100/$f1;
#X obj 102 97 vsl 15 128 100 30000 0 0 empty empty empty 0 -8 0 8 -262144
-1 -1 8300 1;
#X obj 102 235 t b f;
#X obj 266 138 vsl 15 73 -36 36 0 0 empty empty empty 0 -8 0 8 -262144
-1 -1 3662 1;
#X obj 484 348 *~ 0;
#X obj 517 107 vsl 15 128 0.01 1 1 0 empty empty empty 0 -8 0 8 -262144
-1 -1 12300 1;
#X obj 517 267 sel 0.01;
#X msg 515 294 0;
#X floatatom 515 323 5 0 0 0 - - -;
#X text 520 79 feedback;
#X text 269 114 transposition;
#X text 37 71 window-width (samples);
#X connect 1 0 9 0;
#X connect 2 0 3 0;
#X connect 2 0 6 0;
#X connect 2 0 11 1;
#X connect 2 0 29 0;
#X connect 3 0 4 0;
#X connect 4 0 12 0;
#X connect 5 0 7 0;
#X connect 6 0 7 1;
#X connect 7 0 8 0;
#X connect 8 0 9 1;
#X connect 9 0 10 0;
#X connect 9 0 10 1;
#X connect 9 0 36 0;
#X connect 11 0 12 1;
#X connect 12 0 1 0;
#X connect 13 0 11 0;
#X connect 15 0 16 0;
#X connect 16 0 14 0;
#X connect 16 1 32 1;
#X connect 17 0 13 0;
#X connect 17 0 28 0;
#X connect 18 0 25 0;
#X connect 19 0 20 0;
#X connect 20 0 27 0;
#X connect 21 0 23 0;
#X connect 22 0 23 1;
#X connect 23 0 24 0;
#X connect 24 0 25 1;
#X connect 25 0 10 1;
#X connect 25 0 10 0;
#X connect 25 0 36 0;
#X connect 26 0 27 1;
#X connect 27 0 18 0;
#X connect 28 0 26 0;
#X connect 29 0 30 0;
#X connect 30 0 19 0;
#X connect 30 0 26 1;
#X connect 30 0 22 0;
#X connect 31 0 0 0;
#X connect 31 1 0 0;
#X connect 32 0 2 0;
#X connect 33 0 34 0;
#X connect 34 0 15 0;
#X connect 34 1 32 0;
#X connect 34 1 17 0;
#X connect 34 1 14 0;
#X connect 35 0 15 0;
#X connect 36 0 0 0;
#X connect 37 0 38 0;
#X connect 38 0 39 0;
#X connect 38 1 40 0;
#X connect 39 0 40 0;
#X connect 40 0 36 1;
Newbie/help me to understand this patch!
I've found this patch on the web to study purpose.
I think it's simple and small but the problem is I have no idea at all what is 'rms'??
If I can understand what it is, then it'll be much more clear...
thanks!!
#N canvas 0 22 468 635 10;
#X obj 99 13 inlet;
#X msg 99 57 bang;
#X obj 99 158 pack 100 0;
#X obj 100 477 *~;
#X obj 100 450 *~;
#X obj 99 298 dbtorms;
#X obj 99 327 * 5623.41;
#X obj 100 380 line~;
#X obj 100 414 *~;
#X obj 99 354 pack 1 100;
#X obj 99 270 * 0.25;
#X obj 99 238 unpack 0 0;
#X obj 102 536 dac~;
#X obj 144 404 noise~;
#X obj 199 99 delay 50;
#X obj 167 471 +~;
#X obj 200 425 noise~;
#X obj 199 163 pack 0 150;
#X floatatom 271 134 0 0 0 0 - - -;
#X floatatom 272 61 0 0 0 0 - - -;
#X connect 0 0 1 0;
#X connect 1 0 2 0;
#X connect 1 0 14 0;
#X connect 2 0 11 0;
#X connect 3 0 12 0;
#X connect 3 0 12 1;
#X connect 4 0 3 0;
#X connect 5 0 6 0;
#X connect 6 0 9 0;
#X connect 7 0 8 0;
#X connect 7 0 8 1;
#X connect 8 0 4 0;
#X connect 8 0 4 1;
#X connect 9 0 7 0;
#X connect 10 0 5 0;
#X connect 11 0 10 0;
#X connect 11 1 9 1;
#X connect 13 0 15 0;
#X connect 14 0 17 0;
#X connect 15 0 3 1;
#X connect 16 0 15 1;
#X connect 17 0 11 0;
#X connect 18 0 17 1;
#X connect 19 0 14 1;
How to set a counter to 0??
Hi, advanced users!!
I'm trying to make a little sequencer using metro, counter, mod and [sel] object.
It's a copy of obiwannabe tutorial 001.
But since I sequence 3 instruments at the same time with a single toggle object to
on/off metros, I need to all 3 metros starts at the same value each time I stop and restart metros.
one metro is attached to counter and it starts everytime where it was stopped previously....
other two metros, no idea where it starts each time!!
It's very hard to sync them humanly.
Is there a way to start a counter and metro everytime from 0??
here's the part of my patch
#N canvas 73 76 927 339 10;
#X obj 296 104 + 1;
#X obj 253 105 f 0;
#X obj 256 83 t b b;
#X obj 251 134 mod 16;
#X obj 241 161 select 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15;
#X floatatom 289 217 5 0 0 0 - - -;
#X floatatom 452 241 5 0 0 0 - - -;
#X floatatom 241 223 5 0 0 0 - - -;
#X floatatom 373 221 5 0 0 0 - - -;
#X floatatom 422 195 5 0 0 0 - - -;
#X floatatom 535 220 5 0 0 0 - - -;
#X obj 538 37 tgl 15 0 empty empty empty 0 -6 0 10 -262144 -1 -1 0
1;
#X obj 574 153 bng 15 250 50 0 empty empty empty 0 -6 0 8 -241291 -1
-1;
#X obj 816 121 bng 15 250 50 0 empty empty empty 0 -6 0 8 -241291 -1
-1;
#X obj 760 88 del 960;
#X obj 750 39 metro 960;
#X obj 274 12 metro 120;
#X obj 591 115 del 120;
#X obj 550 83 metro 1920;
#X floatatom 345 127 5 0 0 0 - - -;
#X connect 0 0 1 1;
#X connect 1 0 0 0;
#X connect 1 0 3 0;
#X connect 2 0 1 0;
#X connect 3 0 4 0;
#X connect 3 0 19 0;
#X connect 4 0 7 0;
#X connect 4 1 5 0;
#X connect 4 3 8 0;
#X connect 4 6 5 0;
#X connect 4 9 8 0;
#X connect 4 11 9 0;
#X connect 4 15 6 0;
#X connect 4 16 10 0;
#X connect 11 0 15 0;
#X connect 11 0 16 0;
#X connect 11 0 18 0;
#X connect 14 0 13 0;
#X connect 15 0 14 0;
#X connect 16 0 2 0;
#X connect 18 0 12 0;
thanks in advance!!!
\[writesf~\] sample rate bug?
Hello all-
So...my soundcard is set to use a sampling rate of 96kHz, and my PD startup preferences are set to "-r 96000". When I send an "open" message to [writesf~], I include a "-rate 96000" flag, but the file always gets created at 44.1kHz for some reason. (The sound is annoyingly pitched down an octave or so.) Is this a bug, or am I just missing something? I have included a copy of the subpatch below, any help would be greatly appreciated!
-Tim
#N canvas 224 44 449 382 10;
#X msg 129 286 start;
#X msg 198 286 stop;
#X obj 43 336 writesf~ 2;
#X obj 153 71 time;
#X obj 16 173 pack s s s s s s;
#X obj 16 96 makefilename %u;
#X obj 26 147 makefilename %u;
#X obj 153 96 makefilename %u;
#X obj 161 122 makefilename %u;
#X obj 169 147 makefilename %u;
#X obj 16 71 date;
#X obj 21 122 makefilename %u;
#X obj 43 260 inlet~;
#X obj 100 260 inlet~;
#X obj 129 336 print record;
#X text 123 173 time & date stamp;
#X text 10 4 [diskRecorder~];
#X text 13 18 writes an audio file to disk.;
#X text 43 244 main-l;
#X text 101 244 main-r;
#X obj 16 50 bng 15 250 50 0 empty empty empty 0 -6 0 10 -262144 -1
-1;
#X text 231 223 open 24-bit/96kHz file;
#X msg 16 224 open -rate 96000 -bytes 3 -aiff \$1;
#X obj 16 198 makesymbol %s-%s-%s_%s-%s-%s;
#X text 36 48 push me;
#X connect 0 0 2 0;
#X connect 0 0 14 0;
#X connect 1 0 2 0;
#X connect 1 0 14 0;
#X connect 3 0 7 0;
#X connect 3 1 8 0;
#X connect 3 2 9 0;
#X connect 4 0 23 0;
#X connect 5 0 4 0;
#X connect 6 0 4 2;
#X connect 7 0 4 3;
#X connect 8 0 4 4;
#X connect 9 0 4 5;
#X connect 10 0 5 0;
#X connect 10 1 11 0;
#X connect 10 2 6 0;
#X connect 11 0 4 1;
#X connect 12 0 2 0;
#X connect 13 0 2 1;
#X connect 20 0 3 0;
#X connect 20 0 10 0;
#X connect 22 0 2 0;
#X connect 23 0 22 0;
#X connect 23 0 14 0;
Scanning through pixel values of an image
Hi.
I am having trouble with getting pix_data to scan though the image values of the picture.
I am open for suggestions if there is another way to do this.
Can anyone help me?
mvh.
evemgr
here`s my code
#N canvas 637 81 628 488 12;
#X obj 190 159 pix_resize 10 10;
#X obj 171 238 pix_data;
#X floatatom 200 337 5 0 0 0 - - -;
#X floatatom 245 337 5 0 0 0 - - -;
#X floatatom 291 337 5 0 0 0 - - -;
#X floatatom 289 258 5 0 0 0 - - -;
#X obj 200 290 unpack 0 0 0;
#X obj 171 418 pix_draw;
#N canvas 0 0 466 316 image 0;
#X obj 77 48 inlet;
#X obj 77 344 outlet;
#X obj 223 55 inlet;
#X msg 223 123 open \$1;
#X obj 223 100 openpanel;
#X obj 77 205 pix_image c:/lyder/lyd.jpg;
#X connect 0 0 5 0;
#X connect 2 0 4 0;
#X connect 3 0 5 0;
#X connect 4 0 3 0;
#X connect 5 0 1 0;
#X restore 190 115 pd image;
#X obj 190 67 gemhead;
#N canvas 0 0 454 304 gemwin 0;
#X obj 130 159 gemwin;
#X obj 67 125 outlet;
#X obj 67 10 inlet;
#X obj 67 41 route create;
#X msg 67 74 set destroy;
#X msg 204 65 set create;
#X msg 132 112 create \, 1;
#X msg 246 111 destroy;
#X connect 2 0 3 0;
#X connect 3 0 4 0;
#X connect 3 0 6 0;
#X connect 3 1 5 0;
#X connect 3 1 7 0;
#X connect 4 0 1 0;
#X connect 5 0 1 0;
#X connect 6 0 0 0;
#X connect 7 0 0 0;
#X restore 422 273 pd gemwin;
#X msg 422 232 destroy;
#X obj 460 53 bng 15 250 50 0 empty empty empty 0 -6 0 8 -262144 -1
-1;
#N canvas 0 0 474 324 counterx 1;
#X obj 194 13 loadbang;
#X obj 194 58 trigger bang bang;
#X msg 81 90 stop;
#X obj 194 146 float;
#X obj 194 181 + 1;
#X msg 325 126 0;
#X floatatom 194 230 5 0 0 0 - - -;
#X obj 194 272 outlet;
#X msg 143 20 bang;
#X obj 81 58 select 11;
#X obj 273 272 outlet;
#X obj 195 110 metro 11000;
#X connect 0 0 1 0;
#X connect 1 0 11 0;
#X connect 1 1 5 0;
#X connect 2 0 11 0;
#X connect 3 0 4 0;
#X connect 3 0 10 0;
#X connect 4 0 6 0;
#X connect 4 0 3 1;
#X connect 4 0 9 0;
#X connect 5 0 3 1;
#X connect 6 0 7 0;
#X connect 8 0 1 0;
#X connect 9 0 2 0;
#X connect 11 0 3 0;
#X restore 210 186 pd counterx;
#N canvas 542 0 478 328 countery 0;
#X obj 192 270 outlet;
#X obj 194 13 loadbang;
#X obj 194 58 trigger bang bang;
#X msg 81 90 stop;
#X obj 194 146 float;
#X obj 194 181 + 1;
#X msg 325 126 0;
#X floatatom 194 230 5 0 0 0 - - -;
#X obj 81 58 select 11;
#X obj 131 15 inlet;
#X obj 194 110 metro 1000;
#X connect 1 0 2 0;
#X connect 2 0 10 0;
#X connect 2 1 6 0;
#X connect 3 0 10 0;
#X connect 4 0 5 0;
#X connect 5 0 7 0;
#X connect 5 0 4 1;
#X connect 5 0 8 0;
#X connect 6 0 4 1;
#X connect 7 0 0 0;
#X connect 8 0 3 0;
#X connect 9 0 2 0;
#X connect 10 0 4 0;
#X restore 230 211 pd countery;
#X obj 422 191 loadbang;
#N canvas 661 149 482 332 maincounter 0;
#X obj 194 13 loadbang;
#X msg 148 12 bang;
#X obj 194 58 trigger bang bang;
#X obj 81 58 select 101;
#X msg 81 90 stop;
#X obj 194 146 float;
#X obj 194 181 + 1;
#X msg 325 126 0;
#X floatatom 194 230 5 0 0 0 - - -;
#X obj 265 224 outlet;
#X obj 194 110 metro 1001;
#X connect 0 0 2 0;
#X connect 1 0 2 0;
#X connect 2 0 10 0;
#X connect 2 1 7 0;
#X connect 3 0 4 0;
#X connect 4 0 10 0;
#X connect 5 0 6 0;
#X connect 6 0 8 0;
#X connect 6 0 5 1;
#X connect 6 0 3 0;
#X connect 7 0 5 1;
#X connect 10 0 5 0;
#X connect 10 0 9 0;
#X restore 171 19 pd maincounter;
#X msg 89 176 bang;
#X msg 369 192 bang;
#X obj 263 84 loadbang;
#X connect 0 0 1 1;
#X connect 1 0 7 0;
#X connect 1 1 6 0;
#X connect 1 2 5 0;
#X connect 6 0 2 0;
#X connect 6 1 3 0;
#X connect 6 2 4 0;
#X connect 8 0 0 0;
#X connect 9 0 8 0;
#X connect 10 0 11 0;
#X connect 11 0 10 0;
#X connect 13 0 1 2;
#X connect 13 1 14 0;
#X connect 14 0 1 3;
#X connect 15 0 11 0;
#X connect 16 0 1 0;
#X connect 17 0 1 0;
#X connect 18 0 11 0;
The History about a little video launcher patch...
hi, this is my beginning: i need a "thing" who launches two videos and two audios (pre-recorded, aleatory selected) of a list, in the moment that i make a noise (enoug noise) in a microphone, for that i make this simple patch:
----cut from here----
#N canvas 92 55 825 609 12;
#X obj 85 5 gemhead;
#X obj 345 161 pix_film;
#X msg 488 98 auto \$1;
#X obj 488 78 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 1
1;
#X obj 825 212 gemwin;
#X msg 805 105 create;
#X msg 892 182 destroy;
#X msg 848 149 1;
#X msg 853 178 0;
#X msg 753 81 border 0;
#X msg 710 155 dimen 2048 768;
#X obj 85 161 pix_film;
#X obj 85 218 pix_texture;
#X msg 192 92 auto \$1;
#X obj 192 71 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 1
1;
#X msg 192 126 colorspace RGBA;
#X msg 488 120 colorspace RGBA;
#X obj 345 435 rectangle 0 0;
#X floatatom 419 328 5 0 0 0 - - -;
#X obj 394 405 /;
#X floatatom 465 328 5 0 0 0 - - -;
#X obj 444 405 /;
#X obj 374 290 unpack 0 0 0;
#X obj 85 260 translateXYZ;
#X obj 85 431 rectangle 0 0;
#X floatatom 159 327 5 0 0 0 - - -;
#X obj 134 401 /;
#X floatatom 205 326 5 0 0 0 - - -;
#X obj 184 400 /;
#X obj 114 284 unpack 0 0 0;
#X msg 153 372 60;
#X msg 203 373 50;
#X obj 345 216 pix_texture;
#X obj 345 262 translateXYZ;
#X msg 413 376 60;
#X msg 463 377 50;
#X msg 192 223 -5.5;
#X msg 318 100 open lib/video\$1.mov;
#X msg 8 102 open lib/video\$1.mov;
#X msg 488 225 10.8;
#X obj 1146 4 loadbang;
#X msg 488 45 1;
#X msg 192 46 1;
#X msg 488 167 0;
#X msg 192 174 0;
#X msg 682 447 open lib/audio\$1n.wav;
#X obj 993 124 adc~ 2;
#X obj 995 279 s sincro;
#X obj 957 61 s aleatorio_1;
#X obj 1047 91 s aleatorio_2;
#X obj 144 195 s fin_video;
#X obj 404 190 s fin_video;
#X obj 682 331 r aleatorio_1;
#X obj 957 5 r sincro;
#X obj 1047 4 r sincro;
#X obj 1146 39 s inicio;
#X obj 1024 192 r inicio;
#X obj 753 7 r inicio;
#X obj 805 34 delay 5;
#X obj 848 74 delay 5;
#X msg 936 441 open lib/audio\$1n.wav;
#X obj 853 356 r sincro;
#X obj 681 527 dac~ 3;
#X obj 997 527 dac~ 4;
#X obj 936 335 r aleatorio_2;
#X obj 682 483 readsf~ 2 221000;
#X obj 936 476 readsf~ 2 221000;
#X obj 318 14 r aleatorio_2;
#X obj 192 12 r inicio;
#X obj 134 348 r inicio;
#X obj 488 10 r inicio;
#X obj 401 349 r inicio;
#X obj 717 390 delay 5;
#X obj 971 389 delay 5;
#X obj 599 345 r sincro;
#X msg 599 403 1;
#X obj 624 16 r inicio;
#X msg 624 46 \; pd dsp 1;
#X obj 501 142 r fin_video;
#X obj 221 148 r fin_video;
#X obj 927 266 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0
1;
#X msg 853 417 1;
#X obj 8 51 r aleatorio_1;
#X obj 994 156 hip~ 5;
#X obj 995 246 threshold~;
#X obj 957 32 random 4;
#X obj 1047 31 random 4;
#X msg 1024 220 set 0.6 1000 0 100;
#X obj 717 361 r fin_video;
#X obj 971 360 r fin_video;
#X obj 599 373 delay 6;
#X obj 853 390 delay 6;
#X obj 682 416 float;
#X obj 936 415 float;
#X msg 732 117 cursor 0;
#X connect 0 0 11 0;
#X connect 0 0 1 0;
#X connect 1 0 32 0;
#X connect 1 1 22 0;
#X connect 1 2 51 0;
#X connect 2 0 1 0;
#X connect 3 0 2 0;
#X connect 5 0 4 0;
#X connect 6 0 4 0;
#X connect 7 0 4 0;
#X connect 8 0 4 0;
#X connect 9 0 4 0;
#X connect 10 0 4 0;
#X connect 11 0 12 0;
#X connect 11 1 29 0;
#X connect 11 2 50 0;
#X connect 12 0 23 0;
#X connect 13 0 11 0;
#X connect 14 0 13 0;
#X connect 15 0 11 0;
#X connect 16 0 1 0;
#X connect 18 0 19 0;
#X connect 19 0 17 1;
#X connect 20 0 21 0;
#X connect 21 0 17 2;
#X connect 22 1 18 0;
#X connect 22 2 20 0;
#X connect 23 0 24 0;
#X connect 25 0 26 0;
#X connect 26 0 24 1;
#X connect 27 0 28 0;
#X connect 28 0 24 2;
#X connect 29 1 25 0;
#X connect 29 2 27 0;
#X connect 30 0 26 1;
#X connect 31 0 28 1;
#X connect 32 0 33 0;
#X connect 33 0 17 0;
#X connect 34 0 19 1;
#X connect 35 0 21 1;
#X connect 36 0 23 1;
#X connect 37 0 1 0;
#X connect 38 0 11 0;
#X connect 39 0 33 1;
#X connect 40 0 55 0;
#X connect 41 0 3 0;
#X connect 42 0 14 0;
#X connect 43 0 1 1;
#X connect 44 0 11 1;
#X connect 45 0 65 0;
#X connect 46 0 83 0;
#X connect 52 0 92 0;
#X connect 53 0 85 0;
#X connect 54 0 86 0;
#X connect 56 0 87 0;
#X connect 57 0 9 0;
#X connect 57 0 10 0;
#X connect 57 0 58 0;
#X connect 57 0 94 0;
#X connect 58 0 5 0;
#X connect 58 0 59 0;
#X connect 59 0 7 0;
#X connect 60 0 66 0;
#X connect 61 0 91 0;
#X connect 64 0 93 0;
#X connect 65 0 62 0;
#X connect 66 1 63 0;
#X connect 67 0 37 0;
#X connect 68 0 42 0;
#X connect 68 0 15 0;
#X connect 68 0 44 0;
#X connect 68 0 36 0;
#X connect 69 0 26 0;
#X connect 69 0 30 0;
#X connect 69 0 28 0;
#X connect 69 0 31 0;
#X connect 70 0 41 0;
#X connect 70 0 16 0;
#X connect 70 0 43 0;
#X connect 70 0 39 0;
#X connect 71 0 34 0;
#X connect 71 0 35 0;
#X connect 71 0 19 0;
#X connect 71 0 21 0;
#X connect 72 0 92 0;
#X connect 73 0 93 0;
#X connect 74 0 90 0;
#X connect 75 0 65 0;
#X connect 76 0 77 0;
#X connect 78 0 43 0;
#X connect 79 0 44 0;
#X connect 81 0 66 0;
#X connect 82 0 38 0;
#X connect 83 0 84 0;
#X connect 84 0 47 0;
#X connect 84 0 80 0;
#X connect 85 0 48 0;
#X connect 86 0 49 0;
#X connect 87 0 84 0;
#X connect 88 0 72 0;
#X connect 88 0 90 0;
#X connect 89 0 73 0;
#X connect 89 0 91 0;
#X connect 90 0 75 0;
#X connect 91 0 81 0;
#X connect 92 0 45 0;
#X connect 93 0 60 0;
#X connect 94 0 4 0;
----cut to here---
i'm sorry for space wasted, but is the 4:02 (...of course!),
the "thing" works, i have the video and audio libs in the apropiate site (they are 5 .mov files and 5 .wav, not very heavy content), but at the third clap in front of the mic it hangs, allways on the third, and a bit later a beatiful death blue screen (yes, i'm windozed, linux don't have drivers for my presonus firestation), i test it in two partitions (same machine), any ideas? Thanks for reading, interest, and.. for all, best regards.
jano
\[resolved\] Still Bang
I'm not sure I read you correctly
but I think this is what you want
It follows the middle inlet but if
that stops changing then it follows
the leftmost inlet after a delay set
at the rightmost inlet.
#N canvas 477 470 533 436 10;
#X floatatom 24 207 5 0 0 0 - - -;
#N canvas 0 0 482 472 autowobble 0;
#X obj 117 185 average;
#X obj 117 157 delta;
#X obj 117 89 f;
#X obj 110 344 line;
#X msg 110 320 \$1 100;
#X obj 156 237 == 0;
#X obj 165 45 inlet;
#X obj 37 45 inlet;
#X text 20 26 lfo krate;
#X obj 110 368 outlet;
#X obj 140 273 *;
#X obj 117 237 != 0;
#X obj 76 70 t b;
#X obj 80 268 *;
#X obj 110 296 +;
#X obj 117 132 line;
#X obj 117 110 pack 1 200;
#X obj 291 49 inlet;
#X text 144 23 manual fader;
#X text 285 27 idle time;
#X connect 0 0 5 0;
#X connect 0 0 11 0;
#X connect 1 0 0 0;
#X connect 2 0 16 0;
#X connect 3 0 9 0;
#X connect 4 0 3 0;
#X connect 5 0 10 1;
#X connect 6 0 2 1;
#X connect 6 0 13 1;
#X connect 7 0 10 0;
#X connect 7 0 12 0;
#X connect 10 0 14 1;
#X connect 11 0 13 0;
#X connect 12 0 2 0;
#X connect 13 0 14 0;
#X connect 14 0 4 0;
#X connect 15 0 1 0;
#X connect 16 0 15 0;
#X connect 17 0 16 1;
#X restore 24 179 pd autowobble;
#X obj 24 70 vsl 12 64 1 200 0 0 empty empty lfo-period(ms) 0 -8 0
8 -225280 -1 -1 5400 1;
#N canvas 0 0 450 300 ktrilfo 0;
#X obj 186 93 del 10;
#X obj 144 93 t b f;
#X obj 186 135 f 0;
#X obj 220 136 +;
#X msg 235 104 1;
#X msg 276 104 -1;
#X obj 187 175 >= 127;
#X obj 136 177 <= 0;
#X obj 136 202 sel 1;
#X obj 187 203 sel 1;
#X obj 223 71 max 1;
#X obj 223 47 inlet;
#X text 204 27 sweep rate(ms);
#X obj 225 235 outlet;
#X text 226 262 bang per cycle;
#X text 80 259 int val;
#X obj 104 235 outlet;
#X obj 307 70 loadbang;
#X obj 321 44 inlet;
#X text 324 26 phase reset/start;
#X connect 0 0 2 0;
#X connect 1 0 0 0;
#X connect 2 0 1 0;
#X connect 2 0 3 0;
#X connect 2 0 6 0;
#X connect 2 0 7 0;
#X connect 2 0 16 0;
#X connect 3 0 2 1;
#X connect 4 0 3 1;
#X connect 5 0 3 1;
#X connect 6 0 9 0;
#X connect 7 0 8 0;
#X connect 8 0 4 0;
#X connect 8 0 13 0;
#X connect 9 0 5 0;
#X connect 10 0 0 1;
#X connect 11 0 10 0;
#X connect 17 0 2 0;
#X connect 18 0 2 0;
#X restore 24 143 pd ktrilfo;
#X obj 110 101 vsl 12 64 1 127 0 0 empty empty manual 0 -8 0 8 -225271
-1 -1 1500 1;
#X obj 159 101 vsl 12 64 1 1000 0 0 empty empty hold 0 -8 0 8 -261681
-1 -1 3700 1;
#X text 177 138 hold is NOT milliseconds;
#X text 178 172 internal func but is roughly 1/2*square of hold;
#X text 179 155 It's actually complicated because of aymptotic;
#X text 31 254 The value may jump quickly when the lfo resumes \, need
to add a crossing detector for smooth transition;
#X text 21 10 Autowobble - output follows the k-rate LFO input UNLESS
the manual fader is moved \, but after a delay set by HOLD the output
will resume tracking the LFO;
#X text 358 273 ajf2005;
#X connect 1 0 0 0;
#X connect 2 0 3 0;
#X connect 3 0 1 0;
#X connect 4 0 1 1;
#X connect 5 0 1 2;
Loading a sample into a table
hi again i seem to have a problem with the -resize feature. i can only load the first kick of a drumloop.
here's the patch.. think you can look at it for me?
#N canvas 176 147 568 631 10;
#X msg 30 59 bang;
#X obj 29 167 soundfiler;
#N canvas 0 22 450 300 graph1 0;
#X array array1 302400 float 0;
#X coords 0 1 302399 -1 200 140 1;
#X restore 298 51 graph;
#X obj 30 104 openpanel;
#X msg 29 139 read -resize \$1 array1;
#X obj 67 454 tabwrite~ tabread4-out;
#X floatatom 65 532 0 0 0 0 - - -;
#N canvas 159 26 495 266 output 0;
#X obj 406 192 t b;
#X obj 406 132 f;
#X obj 406 72 inlet;
#X text 413 35 mute;
#X obj 406 222 f;
#X msg 510 214 0;
#X msg 406 102 bang;
#X obj 406 162 moses 1;
#X obj 510 184 t b f;
#X obj 476 140 moses 1;
#X obj 100 178 dbtorms;
#X obj 476 110 r master-lvl;
#X obj 100 50 r master-lvl;
#X obj 406 252 s master-lvl;
#X obj 26 217 inlet~;
#X obj 239 49 inlet;
#X text 239 22 level;
#X obj 239 120 s master-lvl;
#X msg 115 78 set \$1;
#X obj 115 107 outlet;
#X msg 257 77 \; pd dsp 1;
#X obj 100 233 line~;
#X obj 26 254 *~;
#X obj 26 289 dac~;
#X obj 100 205 pack 0 50;
#X text 24 190 audio;
#X text 112 132 show level;
#X connect 0 0 4 0;
#X connect 1 0 7 0;
#X connect 2 0 6 0;
#X connect 4 0 13 0;
#X connect 5 0 13 0;
#X connect 6 0 1 0;
#X connect 7 0 0 0;
#X connect 7 1 8 0;
#X connect 8 0 5 0;
#X connect 9 1 4 1;
#X connect 10 0 24 0;
#X connect 11 0 1 1;
#X connect 11 0 9 0;
#X connect 12 0 10 0;
#X connect 12 0 18 0;
#X connect 14 0 22 0;
#X connect 15 0 17 0;
#X connect 15 0 20 0;
#X connect 18 0 19 0;
#X connect 21 0 22 1;
#X connect 22 0 23 0;
#X connect 22 0 23 1;
#X connect 24 0 21 0;
#X restore 30 566 pd output;
#X msg 100 532 MUTE;
#X text 141 531 <-- output amplitude;
#X obj 30 497 hip~ 5;
#X floatatom 30 196 0 0 0 0 - - -;
#X text 229 387 read from the table;
#X text 79 196 <-- frequency (Hz.);
#X floatatom 58 257 0 0 0 0 - - -;
#X obj 58 290 * 441;
#X obj 30 317 *~ 0;
#X obj 30 347 +~ 1;
#X text 111 422 <-- click to display output;
#X obj 30 228 phasor~ 0;
#X msg 66 419 bang;
#X text 105 256 <-- chunk size (100ths of a second);
#X text 76 316 <-- readjust phase for range 0 - (chunk size);
#X text 75 347 <-- add one to avoid beginning of table;
#X obj 30 384 tabread4~ array1;
#X connect 0 0 3 0;
#X connect 3 0 4 0;
#X connect 4 0 1 0;
#X connect 6 0 7 1;
#X connect 7 0 6 0;
#X connect 8 0 7 2;
#X connect 10 0 7 0;
#X connect 11 0 19 0;
#X connect 14 0 15 0;
#X connect 15 0 16 1;
#X connect 16 0 17 0;
#X connect 17 0 24 0;
#X connect 19 0 16 0;
#X connect 20 0 5 0;
#X connect 24 0 10 0;
#X connect 24 0 5 0;