File: random.pd

package info (click to toggle)
pd 0.32p1-5
  • links: PTS
  • area: main
  • in suites: woody
  • size: 4,704 kB
  • ctags: 5,418
  • sloc: ansic: 38,382; tcl: 1,036; makefile: 612; sh: 265
file content (17 lines) | stat: -rw-r--r-- 803 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#N canvas 0 0 630 351 8;
#X msg 128 164 bang;
#X obj 128 248 random 5;
#X floatatom 179 223;
#X text 116 25 random -- pseudorandom integers;
#X floatatom 128 283;
#X msg 138 188 seed 123;
#X text 67 64 Random outputs pseudorandom integers from 0 to N-1 where N is the creation argument (5 in the example below.) You can specify a seed if you wish. Seeds are kept locally so that if two Randoms are seeded teh same they will have the same output (or indeed you can seed the same one twice to repeat the output.);
#X text 330 326 updated for Pd version 0.24;
#X text 247 159 bang for output;
#X text 245 185 message to set the seed;
#X text 243 223 inlet to reset the range;
#X text 242 251 argument to initialize the range;
#X connect 0 0 1 0;
#X connect 1 0 4 0;
#X connect 2 0 1 1;
#X connect 5 0 1 0;