[PD] Bug in spot_light?

Frank Barknecht fbar at footils.org
Fri Dec 9 17:19:59 CET 2005


Hallo,
james tittle hat gesagt: // james tittle wrote:
> ...I have a copy of the example & source file as it was originally  
> posted to the list, but I've never been able to get it work...haven't  
> had time to find out why, either :-(  Anyway, here's what the inlets  
> are suppost to be:
> 
> right inlet:  Color (ie. [1 1 1< )
> middle inlet:  linear attenuation; cone cutoff angle; decay at edges  
> (ie. [0.1 20 0< )
> left inlet:  gemstate
> 
> ...kinda weird/messy to have those parameters lumped together, but  
> then I didn't write it ;-)

Actually I have the same file as well, but it doesn't show any
spot-light, even if you exchange the inlet order. 

*However*: I now have a working patch, it's attached and was extended
to also incorporate the attenuation/cutoff/decay messages. It works
with current Gem-CVS, only the debug-cone is slightly wrong of course.
It would be nice, if that cone would also display the cutoff-angle
btw.

[spot_light] allows for some really nice effects btw, for example if
you crank up the colors to "out of range" values like [2 3 0(, then it
gives a surreal feel.

Ciao
-- 
 Frank Barknecht                 _ ______footils.org_ __goto10.org__
-------------- next part --------------
#N canvas 532 264 748 596 10;
#X obj 57 139 gemwin;
#X msg 57 87 0 \, destroy;
#X msg 57 112 lighting 1 \, create \, 1;
#N canvas 611 263 566 360 spheres 0;
#X obj 66 12 gemhead;
#X floatatom 84 243 5 0 0 0 - - -;
#X obj 49 14 tgl 15 0 empty empty empty 0 -6 0 8 -262144 -1 -1 0 1
;
#X floatatom 99 43 5 0 0 0 - - -;
#X floatatom 132 60 5 0 0 0 - - -;
#X floatatom 166 77 5 0 0 0 - - -;
#X floatatom 103 261 5 0 0 0 - - -;
#X obj 66 96 rotateXYZ 0 0 0;
#X floatatom 106 130 5 0 0 0 - - -;
#X floatatom 146 147 5 0 0 0 - - -;
#X floatatom 187 163 5 0 0 0 - - -;
#X obj 66 183 translateXYZ 0 0 0;
#X obj 306 74 gemhead;
#X floatatom 410 143 5 0 0 0 - - -;
#X floatatom 450 160 5 0 0 0 - - -;
#X floatatom 491 176 5 0 0 0 - - -;
#X floatatom 409 54 5 0 0 0 - - -;
#X floatatom 442 71 5 0 0 0 - - -;
#X floatatom 476 88 5 0 0 0 - - -;
#X obj 373 284 sphere 0.2;
#X msg 304 214 20;
#X obj 302 181 loadbang;
#X obj 376 106 rotateXYZ 0 -70 0;
#X obj 373 232 translateXYZ 1.4 0 0;
#X obj 66 280 sphere 0.9;
#X connect 0 0 7 0;
#X connect 1 0 24 1;
#X connect 2 0 0 0;
#X connect 2 0 12 0;
#X connect 3 0 7 1;
#X connect 4 0 7 2;
#X connect 5 0 7 3;
#X connect 6 0 24 2;
#X connect 7 0 11 0;
#X connect 8 0 11 1;
#X connect 9 0 11 2;
#X connect 10 0 11 3;
#X connect 11 0 24 0;
#X connect 12 0 22 0;
#X connect 13 0 23 1;
#X connect 14 0 23 2;
#X connect 15 0 23 3;
#X connect 16 0 22 1;
#X connect 17 0 22 2;
#X connect 18 0 22 3;
#X connect 20 0 19 2;
#X connect 20 0 24 2;
#X connect 21 0 20 0;
#X connect 22 0 23 0;
#X connect 23 0 19 0;
#X restore 55 193 pd spheres;
#X obj 245 30 gemhead;
#X floatatom 283 62 5 0 0 0 - - -;
#X floatatom 321 78 5 0 0 0 - - -;
#X floatatom 359 95 5 0 0 0 - - -;
#X floatatom 285 148 5 0 0 0 - - -;
#X floatatom 325 165 5 0 0 0 - - -;
#X floatatom 366 181 5 0 0 0 - - -;
#X floatatom 360 349 5 0 0 0 - - -;
#X floatatom 401 349 5 0 0 0 - - -;
#X floatatom 438 350 5 0 0 0 - - -;
#X obj 245 471 spot_light;
#X obj 293 391 tgl 15 0 empty empty empty 0 -6 0 8 -262144 -1 -1 1
1;
#X msg 292 411 debug \$1;
#X obj 438 369 t b f;
#X obj 362 385 t b f;
#X obj 360 300 loadbang;
#X obj 360 405 pack 0 0 0;
#X msg 359 319 1;
#X obj 245 201 translateXYZ 2 0 0;
#X obj 245 114 rotateXYZ 0 -70 0;
#X floatatom 501 290 5 0 0 1 linear_attenuation - -;
#X floatatom 542 320 5 0 0 1 cone_cutoff_angle - -;
#X floatatom 579 351 5 0 0 1 decay_at_edges - -;
#X obj 579 370 t b f;
#X obj 503 386 t b f;
#X obj 501 406 pack 0 0 0;
#X obj 219 407 tgl 15 0 empty empty empty 0 -6 0 8 -262144 -1 -1 0
1;
#X text 393 326 color;
#X floatatom 278 227 5 0 0 0 - - -;
#X floatatom 311 240 5 0 0 0 - - -;
#X floatatom 345 257 5 0 0 0 - - -;
#X obj 245 276 rotateXYZ 0 0 0;
#X connect 1 0 0 0;
#X connect 2 0 0 0;
#X connect 4 0 23 0;
#X connect 5 0 23 1;
#X connect 6 0 23 2;
#X connect 7 0 23 3;
#X connect 8 0 22 1;
#X connect 9 0 22 2;
#X connect 10 0 22 3;
#X connect 11 0 20 0;
#X connect 12 0 18 0;
#X connect 13 0 17 0;
#X connect 15 0 16 0;
#X connect 16 0 14 0;
#X connect 17 0 20 0;
#X connect 17 1 20 2;
#X connect 18 0 20 0;
#X connect 18 1 20 1;
#X connect 19 0 21 0;
#X connect 20 0 14 1;
#X connect 21 0 11 0;
#X connect 21 0 12 0;
#X connect 21 0 15 0;
#X connect 22 0 35 0;
#X connect 23 0 22 0;
#X connect 24 0 29 0;
#X connect 25 0 28 0;
#X connect 26 0 27 0;
#X connect 27 0 29 0;
#X connect 27 1 29 2;
#X connect 28 0 29 0;
#X connect 28 1 29 1;
#X connect 29 0 14 2;
#X connect 30 0 14 0;
#X connect 32 0 35 1;
#X connect 33 0 35 2;
#X connect 34 0 35 3;
#X connect 35 0 14 0;


More information about the Pd-list mailing list