aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--examples/sort.pd46
1 files changed, 26 insertions, 20 deletions
diff --git a/examples/sort.pd b/examples/sort.pd
index 2b3419a..b6d80a4 100644
--- a/examples/sort.pd
+++ b/examples/sort.pd
@@ -1,13 +1,13 @@
#N canvas 137 350 811 532 10;
-#X obj 86 231 print UNSORTED;
+#X obj 95 233 print UNSORTED;
#X msg 37 107 bang;
#X obj 198 23 sort;
#X text 314 87 any package-elements that are non-float will be interpreted
as "0.0".;
#X text 270 87 note :;
-#X obj 53 329 sort 1;
-#X obj 53 470 print ASCENDING;
-#X obj 37 347 sort -1;
+#X obj 56 335 sort 1;
+#X obj 56 467 print ASCENDING;
+#X obj 37 377 sort -1;
#X obj 37 487 print DESCENDING;
#X text 278 297 creation : "sort [<dir>]";
#X text 457 310 dir < 0 :: descending sort;
@@ -54,26 +54,32 @@ as "0.0".;
#X connect 13 9 2 0;
#X connect 13 10 1 0;
#X restore 37 195 pd randompackage;
-#X obj 72 177 print;
#X msg 72 160 -----;
#X obj 37 141 t b b;
-#X floatatom 88 293 0 0 0 0 - - -;
-#X text 122 295 direction;
+#X floatatom 94 268 0 0 0 0 - - -;
+#X text 128 270 direction;
#X obj 37 213 t l l l l;
-#X obj 69 312 sort;
-#X obj 69 453 print SORTED;
+#X obj 75 287 sort;
+#X obj 75 448 print SORTED;
#X text 237 23 shell-sort a package of floats;
#X text 553 16 part of zexy;
-#X connect 1 0 16 0;
+#X obj 81 402 print indicesD;
+#X obj 93 357 print indicesA;
+#X obj 72 177 print -----;
+#X text 269 162 the second outlet gives the indices of the input data.
+;
+#X connect 1 0 15 0;
#X connect 5 0 6 0;
+#X connect 5 1 24 0;
#X connect 7 0 8 0;
-#X connect 13 0 19 0;
-#X connect 15 0 14 0;
-#X connect 16 0 13 0;
-#X connect 16 1 15 0;
-#X connect 17 0 20 1;
-#X connect 19 0 7 0;
-#X connect 19 1 5 0;
-#X connect 19 2 20 0;
-#X connect 19 3 0 0;
-#X connect 20 0 21 0;
+#X connect 7 1 23 0;
+#X connect 13 0 18 0;
+#X connect 14 0 25 0;
+#X connect 15 0 13 0;
+#X connect 15 1 14 0;
+#X connect 16 0 19 1;
+#X connect 18 0 7 0;
+#X connect 18 1 5 0;
+#X connect 18 2 19 0;
+#X connect 18 3 0 0;
+#X connect 19 0 20 0;