[Pd] Stack Overflow

Frank Barknecht fbar at footils.org
Mon Mar 27 01:40:24 CEST 2006


Hallo,
Chuckk Hubbard hat gesagt: // Chuckk Hubbard wrote:

> Yes.  I was going nuts trying to figure this out, when I detached the
> inlet in my [until] version and it suddenly worked using your testing
> print objects.  Apparently it is the way I have it implemented in my
> patch: its own left outlet is still set up to retrigger the inlet.  I
> didn't have any stray [next( messages going in, that was what was
> confusing me; because if there were, my previous version should have
> given empty pointer errors, and it didn't.
> 
> I don't know how else to implement this, without its output
> retriggering it.  I did fix my transposing function, pretty much, so
> the old recursive JInext patch is doing all its jobs fine.  It's just
> not realistic to try to revamp my whole sequencing function this close
> to my finals (this program isn't for credit).

If you want to do this later, I have a small addition: The [spigot]
stuff turned out to be unnecessary. Triggering the until multiple
times in my patch doesn't change or break anything. I attached a
cleaned up version of the example I did, called "ds-traverse". It
should be possible to use as a drop-in replacement for JInext with the
supplied wrapper called "JInext-dropin.pd", which has exactly the same
interface as your JInext.pd.

> Now I'm wondering:
> a) is it possible to use integers as a type for a struct field?

No, I don't think so: only float, symbol, array and list are possible
types in struct-definitions.

> b) what are the limits on Pd's float accuracy?

There is a thread going on about this currently, you should have it in
your mailbox, it's subject is "32bit integer float".

Ciao
-- 
 Frank Barknecht                 _ ______footils.org_ __goto10.org__
-------------- next part --------------
#N canvas 485 163 441 524 10;
#X obj 111 34 inlet;
#X obj 111 418 outlet;
#X msg 285 217 next;
#X obj 176 418 outlet;
#X obj 285 195 until;
#X obj 176 347 t b b;
#X obj 285 145 r \$0-SKIP;
#X obj 143 290 s \$0-SKIP;
#X obj 206 387 s \$0-END_OR_HIT;
#X obj 315 173 r \$0-END_OR_HIT;
#X obj 285 171 b;
#X obj 111 259 pointer \$1;
#X obj 111 345 t a b;
#X obj 283 37 inlet;
#X obj 283 91 makefilename pd-%s;
#X obj 283 65 symbol;
#X msg 283 118 traverse \$1;
#X connect 0 0 11 0;
#X connect 2 0 11 0;
#X connect 4 0 2 0;
#X connect 5 0 3 0;
#X connect 5 1 8 0;
#X connect 6 0 10 0;
#X connect 9 0 4 1;
#X connect 10 0 4 0;
#X connect 11 0 12 0;
#X connect 11 1 7 0;
#X connect 11 2 5 0;
#X connect 12 0 1 0;
#X connect 12 1 8 0;
#X connect 13 0 15 0;
#X connect 14 0 16 0;
#X connect 15 0 14 0;
#X connect 16 0 11 0;
-------------- next part --------------
#N canvas 152 359 482 370 10;
#X msg 185 141 score;
#X obj 185 228 outlet;
#X obj 92 227 outlet;
#X obj 92 43 inlet;
#X text 245 141 your "pd-score" subpatch.;
#X obj 92 68 route next bang;
#X msg 92 137 next;
#X obj 142 93 t b b;
#X obj 92 197 ds-traverse \$1;
#X connect 0 0 8 1;
#X connect 3 0 5 0;
#X connect 5 0 6 0;
#X connect 5 1 7 0;
#X connect 6 0 8 0;
#X connect 7 0 6 0;
#X connect 7 1 0 0;
#X connect 8 0 2 0;
#X connect 8 1 1 0;
-------------- next part --------------
#N struct no-test float x float y;
#N struct test float x float y;
#N canvas 364 241 773 455 10;
#N canvas 0 0 450 300 score 0;
#X scalar no-test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar test 12 0 \;;
#X scalar test 12 0 \;;
#X scalar test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar test 12 0 \;;
#X scalar test 12 0 \;;
#X scalar test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar no-test 12 0 \;;
#X scalar test 70 0 \;;
#X scalar test 12 0 \;;
#X scalar test 12 0 \;;
#X restore 598 111 pd score;
#N canvas 0 0 450 300 test 0;
#X obj 154 89 struct test float x float y;
#X obj 132 139 drawnumber x;
#X obj 247 243 append test x;
#X obj 345 216 pointer;
#X obj 272 191 until;
#X msg 255 217 12;
#X msg 351 191 traverse pd-score \, bang;
#X obj 302 156 t f b;
#X msg 302 133 3;
#X connect 3 0 2 1;
#X connect 4 0 5 0;
#X connect 5 0 2 0;
#X connect 6 0 3 0;
#X connect 7 0 4 0;
#X connect 7 1 6 0;
#X connect 8 0 7 0;
#X restore 599 140 pd test;
#N canvas 0 0 450 300 no-test 0;
#X obj 132 139 drawnumber x;
#X obj 345 216 pointer;
#X obj 272 191 until;
#X msg 255 217 12;
#X msg 351 191 traverse pd-score \, bang;
#X obj 302 156 t f b;
#X msg 302 133 3;
#X obj 154 89 struct no-test float x float y;
#X obj 247 243 append no-test x;
#X connect 1 0 8 1;
#X connect 2 0 3 0;
#X connect 3 0 8 0;
#X connect 4 0 1 0;
#X connect 5 0 2 0;
#X connect 5 1 4 0;
#X connect 6 0 5 0;
#X restore 600 164 pd no-test;
#X msg 81 134 next;
#X obj 450 195 print NO-EOL;
#X obj 188 192 print EOL;
#X obj 322 229 print NO-TEST;
#X obj 81 216 print TEST;
#X msg 81 103 bang;
#X msg 322 141 next;
#X msg 322 110 bang;
#X msg 81 72 rewind;
#X text 65 47 pointer messages;
#X msg 188 101 score;
#X text 158 77 subpatch to traverse - without "pd-"!;
#X msg 450 108 score;
#X obj 81 161 ds-traverse test;
#X obj 83 365 JInext-dropin test;
#X obj 83 396 print DROP;
#X obj 204 397 print DROP-EOL;
#X msg 83 340 next;
#X msg 83 316 bang;
#X obj 322 168 ds-traverse no-test;
#X connect 3 0 16 0;
#X connect 8 0 16 0;
#X connect 9 0 22 0;
#X connect 10 0 22 0;
#X connect 11 0 16 0;
#X connect 13 0 16 1;
#X connect 15 0 22 1;
#X connect 16 0 7 0;
#X connect 16 1 5 0;
#X connect 17 0 18 0;
#X connect 17 1 19 0;
#X connect 20 0 17 0;
#X connect 21 0 17 0;
#X connect 22 0 6 0;
#X connect 22 1 4 0;


More information about the Pd-list mailing list