[PD] how to trigger bang's with a period less than 1 milisecond

Frank Barknecht fbar at footils.org
Mon Jun 19 00:21:32 CEST 2006


Hallo,
Tim Blechmann hat gesagt: // Tim Blechmann wrote:

> On Sun, 2006-06-18 at 21:50 +0200, Frank Barknecht wrote:
> > I'm not sure what exactly you mean with "granularity" here, but if you
> > could only generate messages in steps of ~1.5 msec or 64 samples at
> > 44.1kHz you could forget about using Pd to do techno music someone
> > would actually dance to. 
> 
> sorry, but how can you generate messages, that are _not_ aligned to a 64
> sample grid ...

Every "clock-delayed message" (metro, del, pipe, qlist, ...) is not
aligned to 64 samples, GUI generated messages like clicking on a [bng]
are aligned. However to actually make use of this in signal externals,
you need to do some extra work. vline~ does. See attached patch and
doc/3.audio.examples/C04.control.to.signal.pd

> well, a |metro 100.2| will create delays of 100.13ms and 101.59ms ...
> (logical time, 64 at 44100Hz)

Nope, it won't. ;) 

Ciao
-- 
 Frank Barknecht                 _ ______footils.org_ __goto10.org__
-------------- next part --------------
#N canvas 334 220 834 472 10;
#X obj 56 218 tabwrite~ y;
#N canvas 0 0 450 300 graph1 0;
#X array y 128 float 0;
#X coords 0 1 127 -1 200 100 1;
#X restore 49 265 graph;
#X obj 55 166 vline~;
#X obj 233 68 samplerate~;
#X msg 295 31 bang;
#X floatatom 119 116 5 0 0 0 - - -;
#X obj 233 31 loadbang;
#X floatatom 66 42 5 0 100 2 samples - -;
#X obj 55 119 del;
#X text 193 140 go to 0.4 for 0.5 msec.;
#X obj 398 273 loadbang;
#X text 103 375 128 samples;
#X obj 66 66 t b f;
#X msg 26 92 bang;
#X obj 119 93 expr $f1*1000/$f2;
#X msg 55 138 0.4 0 \, 0 0 0.5;
#X msg 398 293 \; y const 0 \; y xticks 0 4 16 \; pd dsp 1;
#X text 395 105 Thus \, time is not quantized for messages triggered
by clocks \, i.e. initiated by metro \, delay \, qlist \, etc. \, although
it is for ui-triggered messages. It is up to tilde objects to do some
extra work and respect the "now".;
#X text 398 41 Pd has a subsample-accurate notion of "now". When a
clock-delayed message is served \, the "now" is set to the exact time
stamp assigned to a clock-serving method in the clock queue.;
#X text 396 177 vline~ does this extra work.;
#X text 397 20 Krzysztof Czaja explained:;
#X connect 2 0 0 0;
#X connect 3 0 14 1;
#X connect 4 0 3 0;
#X connect 6 0 3 0;
#X connect 7 0 12 0;
#X connect 8 0 15 0;
#X connect 10 0 16 0;
#X connect 12 0 13 0;
#X connect 12 1 14 0;
#X connect 13 0 8 0;
#X connect 13 0 0 0;
#X connect 14 0 5 0;
#X connect 14 0 8 1;
#X connect 15 0 2 0;


More information about the Pd-list mailing list