aboutsummaryrefslogtreecommitdiff
path: root/msd2D/editor
diff options
context:
space:
mode:
authorFrank Barknecht <fbar@users.sourceforge.net>2005-05-03 23:36:19 +0000
committerFrank Barknecht <fbar@users.sourceforge.net>2005-05-03 23:36:19 +0000
commit04f471f0190aaabdfd3830c47e18c7f2efdd1198 (patch)
tree7f0dda1f6eced918da7200dc25c37ab8a00d7173 /msd2D/editor
parent7c33ca28dbcba57438f3da391f9e88fa2c87ac18 (diff)
Even more simplifications while creating the network were possible, another
temporary table is gone. Not there's only one left... svn path=/trunk/externals/nusmuk/; revision=2893
Diffstat (limited to 'msd2D/editor')
-rw-r--r--msd2D/editor/msd2d-editor.pd288
1 files changed, 125 insertions, 163 deletions
diff --git a/msd2D/editor/msd2d-editor.pd b/msd2D/editor/msd2d-editor.pd
index 6b0a735..6e9de5a 100644
--- a/msd2D/editor/msd2d-editor.pd
+++ b/msd2D/editor/msd2d-editor.pd
@@ -37,17 +37,17 @@
#X restore 723 150 pd save;
#X text 728 46 Edit here:;
#N canvas 257 131 781 748 generator 0;
-#N canvas 311 93 931 555 getter 0;
+#N canvas 311 93 877 551 getter 0;
#X obj 244 89 inlet;
#X obj 330 145 outlet;
#X text 91 57 First build masses \, then links!!;
#X obj 234 285 outlet;
-#N canvas 571 1 685 826 fix-mass-ids 0;
-#X obj 139 158 t b b b b b b b;
-#X msg 175 254 traverse pd-data \, next;
-#X msg 116 316 next;
-#X obj 175 284 pointer mass;
-#X obj 239 189 s \$0-reset-counter;
+#N canvas 629 18 551 784 fix-mass-ids 0;
+#X obj 43 72 t b b b b b b b;
+#X msg 79 168 traverse pd-data \, next;
+#X msg 20 230 next;
+#X obj 79 198 pointer mass;
+#X obj 143 103 s \$0-reset-counter;
#N canvas 331 520 708 349 counter 0;
#X obj 156 125 f 0;
#X msg 172 102 0;
@@ -61,17 +61,17 @@
#X connect 2 0 1 0;
#X connect 3 0 0 1;
#X connect 5 0 0 0;
-#X restore 192 384 pd counter;
-#X obj 192 482 set mass mid;
-#X text 272 286 At end: fix links!;
-#X obj 282 386 get mass mid;
-#X obj 175 333 t b b b b p p;
-#X obj 307 461 pack 0 0;
-#X obj 307 490 tabwrite \$0-mid2msdid;
-#X text 269 520 Store a mapping mid => msdid for fixing links later
+#X restore 96 298 pd counter;
+#X obj 96 396 set mass mid;
+#X text 176 200 At end: fix links!;
+#X obj 186 300 get mass mid;
+#X obj 79 247 t b b b b p p;
+#X obj 211 375 pack 0 0;
+#X obj 211 404 tabwrite \$0-mid2msdid;
+#X text 125 434 Store a mapping mid => msdid for fixing links later
;
-#X obj 139 116 inlet;
-#X obj 254 307 outlet;
+#X obj 43 30 inlet;
+#X obj 158 221 outlet;
#X connect 0 5 1 0;
#X connect 0 6 4 0;
#X connect 1 0 3 0;
@@ -118,77 +118,48 @@
#X connect 10 5 7 2;
#X connect 11 0 0 0;
#X restore 244 196 pd fix-links;
-#N canvas 0 0 920 707 get-masses 0;
-#X obj 228 162 t b b b b b b b;
-#X msg 264 258 traverse pd-data \, next;
-#X msg 215 362 next;
-#X obj 264 288 pointer mass;
-#X obj 458 455 select 0;
-#X msg 498 480 0;
-#X msg 457 479 1;
-#X obj 328 193 s \$0-reset-counter;
-#N canvas 331 520 708 349 counter 0;
-#X obj 156 125 f 0;
-#X msg 172 102 0;
-#X obj 172 74 r \$0-reset-counter;
-#X obj 188 125 + 1;
-#X obj 156 179 outlet;
-#X obj 156 50 inlet;
-#X connect 0 0 3 0;
-#X connect 0 0 4 0;
-#X connect 1 0 0 1;
-#X connect 2 0 1 0;
-#X connect 3 0 0 1;
-#X connect 5 0 0 0;
-#X restore 364 362 pd counter;
-#X obj 264 337 t b b b b p p b;
-#X obj 364 385 s \$0-current-mass-idx;
-#X obj 437 537 s \$0-current-mid;
-#X msg 328 213 const 0;
-#X obj 328 234 s \$0-mid;
-#X obj 390 234 s \$0-msdid;
-#X text 124 479 At end: start 2nd pass;
-#X obj 228 113 inlet;
-#X obj 347 564 outlet;
-#X obj 656 566 r \$0-current-mass-idx;
-#X obj 605 539 r \$0-current-mid;
-#X obj 605 616 tabwrite \$0-mid;
-#X obj 605 592 pack 0 0;
-#X text 598 515 Write old mids to table;
-#X obj 605 640 print mass-as-in-struct;
-#X obj 161 517 outlet;
-#X obj 347 432 get mass x y mid mob M;
-#X obj 347 514 pack 0 0 0 0 0;
+#N canvas 236 8 602 856 get-masses 0;
+#X obj 148 80 t b b b b b b b;
+#X msg 184 176 traverse pd-data \, next;
+#X msg 135 280 next;
+#X obj 184 206 pointer mass;
+#X obj 325 385 select 0;
+#X msg 365 410 0;
+#X msg 324 409 1;
+#X obj 248 111 s \$0-reset-counter;
+#X msg 248 131 const 0;
+#X obj 248 152 s \$0-mid;
+#X obj 310 152 s \$0-msdid;
+#X text 44 397 At end: start 2nd pass;
+#X obj 148 31 inlet;
+#X obj 214 494 outlet;
+#X obj 81 435 outlet;
+#X obj 214 362 get mass x y mid mob M;
+#X obj 214 444 pack 0 0 0 0 0;
+#X obj 184 255 t b p;
#X connect 0 5 1 0;
#X connect 0 6 7 0;
-#X connect 0 6 12 0;
+#X connect 0 6 8 0;
#X connect 1 0 3 0;
#X connect 2 0 3 0;
-#X connect 3 0 9 0;
+#X connect 3 0 17 0;
#X connect 3 1 2 0;
-#X connect 3 2 24 0;
+#X connect 3 2 14 0;
#X connect 4 0 6 0;
#X connect 4 1 5 0;
-#X connect 5 0 26 3;
-#X connect 6 0 26 3;
+#X connect 5 0 16 3;
+#X connect 6 0 16 3;
+#X connect 8 0 9 0;
#X connect 8 0 10 0;
-#X connect 9 0 2 0;
-#X connect 9 5 25 0;
-#X connect 9 6 8 0;
-#X connect 12 0 13 0;
-#X connect 12 0 14 0;
-#X connect 16 0 0 0;
-#X connect 18 0 21 1;
-#X connect 19 0 21 0;
-#X connect 21 0 20 0;
-#X connect 21 0 23 0;
-#X connect 25 0 26 0;
-#X connect 25 1 26 1;
-#X connect 25 2 11 0;
-#X connect 25 2 26 2;
-#X connect 25 3 4 0;
-#X connect 25 4 26 4;
-#X connect 26 0 17 0;
+#X connect 12 0 0 0;
+#X connect 15 0 16 0;
+#X connect 15 1 16 1;
+#X connect 15 2 16 2;
+#X connect 15 3 4 0;
+#X connect 15 4 16 4;
+#X connect 16 0 13 0;
+#X connect 17 0 2 0;
+#X connect 17 1 15 0;
#X restore 244 115 pd get-masses;
#N canvas 0 0 768 708 make-links 0;
#X obj 316 252 pointer liaison;
@@ -216,11 +187,7 @@
#X connect 8 4 9 4;
#X connect 9 0 4 0;
#X restore 148 257 pd make-links;
-#X text 569 416 TABLES USED:;
-#X text 610 458 ordered mass ids;
-#X text 611 484 mass id as index \, msdid as value;
-#X text 354 111 First get masses positions \, send to msd2D \, store
-in table mid;
+#X text 284 418 TABLES USED:;
#X text 364 174 Change DS mass ids to match msdIds \, store mid2msdid
mapping;
#X text 366 196 Fix mid1 and mid2 in links to match what msd2D thinks
@@ -268,20 +235,21 @@ turn and crashed the car and left the toilet seat open.;
#X connect 15 0 16 0;
#X restore 148 322 pd set-lid;
#X text 238 322 Correct lids to match what msd2D tells us;
-#X obj 475 458 table \$0-mid 4000;
-#X obj 433 484 table \$0-mid2msdid 4000;
+#X obj 146 446 table \$0-mid2msdid 4000;
+#X text 354 111 First get masses positions \, send to msd2D;
+#X text 324 446 mass id as index \, msdid as value. Size 4000 taken
+from the #define in msd sources.;
#X connect 0 0 6 0;
#X connect 4 0 5 0;
#X connect 5 0 7 0;
#X connect 6 0 4 0;
#X connect 6 1 1 0;
-#X connect 7 0 15 0;
+#X connect 7 0 12 0;
#X connect 7 1 3 0;
#X restore 131 221 pd getter;
#X obj 131 369 s \$0-msd;
#X msg 175 154 reset;
#X obj 175 200 s \$0-msd;
-#X msg 368 473 mass fix 0 100 \$1 \$2;
#X obj 112 132 t b b b b;
#N canvas 376 279 682 601 make-setters 0;
#X obj 236 443 s pd-setter;
@@ -336,18 +304,18 @@ turn and crashed the car and left the toilet seat open.;
#X msg 131 324 link ml \$1 \$2 \$3 \$4 \$5;
#X msg 189 275 mass id \$4 \$5 \$1 \$2;
#X msg 175 177 Xmin 0 \, Xmax 1200 \, Ymin 0 \, Ymax 800;
-#X connect 0 0 9 0;
-#X connect 0 1 10 0;
+#X connect 0 0 8 0;
+#X connect 0 1 9 0;
#X connect 2 0 3 0;
-#X connect 5 0 6 0;
-#X connect 5 1 0 0;
-#X connect 5 2 11 0;
-#X connect 5 3 2 0;
-#X connect 7 0 1 0;
-#X connect 8 0 5 0;
+#X connect 4 0 5 0;
+#X connect 4 1 0 0;
+#X connect 4 2 10 0;
+#X connect 4 3 2 0;
+#X connect 6 0 1 0;
+#X connect 7 0 4 0;
+#X connect 8 0 1 0;
#X connect 9 0 1 0;
-#X connect 10 0 1 0;
-#X connect 11 0 3 0;
+#X connect 10 0 3 0;
#X restore 62 337 pd generator;
#N canvas 0 0 718 819 activate 0;
#X obj 233 284 msd2D;
@@ -454,77 +422,71 @@ create the physical model inside.;
#X obj 147 265 print FromMSD;
#X obj 147 210 r \$0-msd-out;
#N canvas 0 0 578 686 setter 0;
-#X obj 930 100 mass-set 31;
-#X obj 900 100 mass-set 30;
-#X obj 870 100 mass-set 29;
-#X obj 840 100 mass-set 28;
-#X obj 810 100 mass-set 27;
-#X obj 780 100 mass-set 26;
-#X obj 750 100 mass-set 25;
-#X obj 720 100 mass-set 24;
-#X obj 690 100 mass-set 23;
-#X obj 660 100 mass-set 22;
-#X obj 630 100 mass-set 21;
-#X obj 600 100 mass-set 20;
-#X obj 570 100 mass-set 19;
-#X obj 540 100 mass-set 18;
-#X obj 510 100 mass-set 17;
-#X obj 480 100 mass-set 16;
-#X obj 450 100 mass-set 15;
-#X obj 420 100 mass-set 14;
-#X obj 390 100 mass-set 13;
-#X obj 360 100 mass-set 12;
-#X obj 330 100 mass-set 11;
-#X obj 300 100 mass-set 10;
-#X obj 270 100 mass-set 9;
-#X obj 240 100 mass-set 8;
-#X obj 210 100 mass-set 7;
-#X obj 180 100 mass-set 6;
-#X obj 150 100 mass-set 5;
-#X obj 120 100 mass-set 4;
-#X obj 90 100 mass-set 3;
-#X obj 60 100 mass-set 2;
-#X obj 30 100 mass-set 1;
-#X obj 0 100 mass-set 0;
+#X obj 61 100 mass-set 10;
+#X obj 103 72 mass-set 9;
+#X obj 77 103 mass-set 8;
+#X obj 69 38 mass-set 7;
+#X obj 39 30 mass-set 6;
+#X obj 57 40 mass-set 5;
+#X obj 57 66 mass-set 4;
+#X obj 26 38 mass-set 3;
+#X obj 52 99 mass-set 2;
+#X obj 47 118 mass-set 1;
+#X obj 158 166 mass-set 0;
#X restore 305 122 pd setter;
#N canvas 0 0 822 675 lsetter 0;
-#X obj 0 100 link-set 15;
-#X obj 30 100 link-set 23;
-#X obj 60 100 link-set 7;
-#X obj 90 100 link-set 27;
-#X obj 120 100 link-set 11;
-#X obj 150 100 link-set 19;
-#X obj 180 100 link-set 3;
-#X obj 210 100 link-set 29;
-#X obj 240 100 link-set 13;
-#X obj 270 100 link-set 21;
-#X obj 300 100 link-set 5;
-#X obj 330 100 link-set 25;
-#X obj 360 100 link-set 9;
-#X obj 390 100 link-set 17;
-#X obj 420 100 link-set 1;
-#X obj 450 100 link-set 30;
-#X obj 480 100 link-set 14;
-#X obj 510 100 link-set 22;
-#X obj 540 100 link-set 6;
-#X obj 570 100 link-set 26;
-#X obj 600 100 link-set 10;
-#X obj 630 100 link-set 18;
-#X obj 660 100 link-set 2;
-#X obj 690 100 link-set 28;
-#X obj 720 100 link-set 12;
-#X obj 750 100 link-set 20;
-#X obj 780 100 link-set 4;
-#X obj 810 100 link-set 24;
-#X obj 840 100 link-set 8;
-#X obj 870 100 link-set 16;
-#X obj 900 100 link-set 0;
+#X obj 47 118 link-set 31;
+#X obj 47 118 link-set 15;
+#X obj 47 118 link-set 23;
+#X obj 47 118 link-set 39;
+#X obj 47 118 link-set 7;
+#X obj 47 118 link-set 27;
+#X obj 47 118 link-set 43;
+#X obj 47 118 link-set 11;
+#X obj 47 118 link-set 19;
+#X obj 52 99 link-set 35;
+#X obj 52 99 link-set 3;
+#X obj 52 99 link-set 29;
+#X obj 52 99 link-set 45;
+#X obj 52 99 link-set 13;
+#X obj 52 99 link-set 21;
+#X obj 52 99 link-set 37;
+#X obj 52 99 link-set 5;
+#X obj 26 38 link-set 25;
+#X obj 26 38 link-set 41;
+#X obj 26 38 link-set 9;
+#X obj 26 38 link-set 17;
+#X obj 26 38 link-set 33;
+#X obj 26 38 link-set 1;
+#X obj 26 38 link-set 30;
+#X obj 57 66 link-set 14;
+#X obj 57 66 link-set 22;
+#X obj 57 66 link-set 38;
+#X obj 57 66 link-set 6;
+#X obj 57 66 link-set 26;
+#X obj 57 66 link-set 42;
+#X obj 57 40 link-set 10;
+#X obj 57 40 link-set 18;
+#X obj 57 40 link-set 34;
+#X obj 57 40 link-set 2;
+#X obj 57 40 link-set 28;
+#X obj 39 30 link-set 44;
+#X obj 39 30 link-set 12;
+#X obj 39 30 link-set 20;
+#X obj 39 30 link-set 36;
+#X obj 69 38 link-set 4;
+#X obj 69 38 link-set 24;
+#X obj 69 38 link-set 40;
+#X obj 77 103 link-set 8;
+#X obj 77 103 link-set 16;
+#X obj 103 72 link-set 32;
+#X obj 158 166 link-set 0;
#X restore 304 145 pd lsetter;
#X text 288 98 Automatic scripting targets;
#X text 65 66 You can ignore this stuff here \, unless something goes
wrong.;
#X obj 269 233 spigot;
-#X obj 306 180 tgl 15 0 empty empty debug 0 -6 0 8 -262144 -1 -1 1
+#X obj 306 180 tgl 15 0 empty empty debug 0 -6 0 8 -262144 -1 -1 0
1;
#X obj 269 206 r \$0-msd-attr;
#X obj 269 264 print AttrMSD;