[PD] Data structure loop selection

raul diaz raul.lete at gmail.com
Sat Feb 3 02:27:49 CET 2007


Hi list!

I have made an abstraction for a table loop selection with data structure.
That's the first I made with data structure, so I suposse there are some
mistakes and some things I would like to improve:
- I would like to limit init and end point rango between 0 and 100, that way
I could't drag either the init point down to 0 or the end point up to 100.
- I don't know why I have two times the init and end markers (I only want
one init marker and another end marker)
- Is it possible to show  the $1 value in the canvas name: 1_sample instead
of $1_sample? (That's not necessarily but I'm cusious)
- How can I modify either the init or end markers from an external value
(via receive)
I will be very thankful if someone can give me some advice in order to
improve this abstraction.
Thanks and regards.

-- 
Raul Diaz Poblete
*************************
raul.lete at gmail.com
Ciudad Real [Spain]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20070203/0d6e2f40/attachment.htm>
-------------- next part --------------
#N struct end float x float v;
#N struct init float x float v;
#N struct mark float x float y;
#N canvas 52 491 308 173 10;
#N canvas 197 535 562 193 1_end 0;
#X obj 359 92 pointer;
#X obj 277 91 append end x;
#X obj 277 34 t b b;
#X msg 277 66 100;
#X obj 277 10 r loadbang;
#X obj 15 11 struct end float x;
#X obj 14 47 drawpolygon 900 3 7 30 7 230;
#X obj 14 74 drawpolygon 900 3 7.5 30 4.5 30;
#X obj 14 102 drawpolygon 900 3 7.5 230 4.5 230;
#X msg 359 67 traverse pd-1_table \, bang;
#X obj 13 134 drawnumber x 2 11 900 end:;
#X connect 0 0 1 1;
#X connect 2 0 3 0;
#X connect 2 1 9 0;
#X connect 3 0 1 0;
#X connect 4 0 2 0;
#X connect 9 0 0 0;
#X restore 36 72 pd \$1_end;
#N canvas 6 20 579 210 1_init 0;
#X obj 359 92 pointer;
#X obj 267 35 t b b;
#X obj 267 11 r loadbang;
#X msg 267 67 0;
#X obj 267 92 append init x;
#X obj 15 11 struct init float x;
#X obj 15 46 drawpolygon 900 3 7 30 7 230;
#X obj 14 74 drawpolygon 900 3 6.75 30 10 30;
#X obj 14 102 drawpolygon 900 3 6.75 230 10 230;
#X msg 359 67 traverse pd-1_table \, bang;
#X obj 13 134 drawnumber x 0 11 900 init:;
#X connect 0 0 4 1;
#X connect 1 0 3 0;
#X connect 1 1 9 0;
#X connect 2 0 1 0;
#X connect 3 0 4 0;
#X connect 9 0 0 0;
#X restore 36 41 pd \$1_init;
#N canvas 882 23 463 257 1_table 1;
#X scalar end 100 0 \;;
#X scalar init 0 0 \;;
#X scalar end 100 0 \;;
#X scalar init 0 0 \;;
#X scalar mark 57 225 \;;
#X scalar mark 57 225 \;;
#X scalar mark 57 225 \;;
#X scalar mark 57 225 \;;
#X scalar mark 57 225 \;;
#X obj 29 32 hsl 395 196 0 1 0 0 empty 1_readpoint empty -2 -6 0 8
-233017 -258699 -1 9869 1;
#N canvas 0 0 450 300 graph3 0;
#X array 1_sample 423191 float 2;
#X coords 0 1 423191 -1 396 196 1;
#X restore 30 32 graph;
#X obj 172 1 cnv 15 90 20 empty empty \$1_sample 20 6 1 11 -262144
-128992 0;
#X coords 0 0 0.25 1 0 0 0;
#X restore 139 72 pd \$1_table;
#N canvas 474 454 270 319 1_getvalue 0;
#X msg 51 82 next;
#X text 88 82 output next item;
#X msg 36 54 traverse pd-1_table;
#X obj 36 137 get init x;
#X obj 132 137 get end x;
#X obj 35 -25 metro 100;
#X obj 36 109 pointer init;
#X obj 35 25 del 10;
#X obj 35 -1 t b b b;
#X obj 36 160 change;
#X obj 132 160 change;
#X obj 36 187 s \$1_initpoint;
#X obj 132 187 s \$1_endpoint;
#X obj 35 -52 r loadbang;
#X connect 0 0 6 0;
#X connect 2 0 6 0;
#X connect 3 0 9 0;
#X connect 4 0 10 0;
#X connect 5 0 8 0;
#X connect 6 0 3 0;
#X connect 6 1 4 0;
#X connect 7 0 0 0;
#X connect 8 0 7 0;
#X connect 8 1 0 0;
#X connect 8 2 2 0;
#X connect 9 0 11 0;
#X connect 10 0 12 0;
#X connect 13 0 5 0;
#X restore 139 41 pd \$1_getvalue;


More information about the Pd-list mailing list