#N canvas 519 142 743 597 8;
#X text 111 111 create and destroy the graphics window;
#X obj 14 362 gemwin;
#X msg 47 110 create;
#X obj 477 89 gemhead;
#X msg 54 138 destroy;
#X msg 68 190 1;
#X msg 67 228 0;
#X msg 122 336 lighting 1;
#X obj 477 200 rotate;
#X floatatom 522 162;
#X obj 313 354 gemhead 1;
#X msg 122 305 lighting 0;
#X obj 477 253 sphere;
#X text 150 38 create a sphere with and without lighting;
#X text 492 135 rotate the sphere;
#X text 313 314 gemhead has a value of 1 so that it is rendered before the sphere is;
#X text 61 284 you can turn lighting on and off while it is running;
#X text 110 210 turn rendering on and off;
#X msg 398 507 1 1 1;
#X msg 345 505 1 0 1;
#X text 449 501 change the lights color;
#X floatatom 389 355;
#X msg 185 424 debug 0;
#X msg 186 455 debug 1;
#X text 96 400 figure out where the light is;
#X obj 313 535 light;
#X text 240 558 creates a local light;
#X msg 434 436 2;
#X msg 477 436 3;
#X msg 390 438 1.1;
#X text 389 417 change the position of the light;
#X obj 313 395 rotateXYZ 0 -60 0;
#X obj 313 475 translateXYZ 2 0 0;
#X connect 2 0 1 0;
#X connect 3 0 8 0;
#X connect 4 0 1 0;
#X connect 5 0 1 0;
#X connect 6 0 1 0;
#X connect 7 0 1 0;
#X connect 8 0 12 0;
#X connect 9 0 8 1;
#X connect 10 0 31 0;
#X connect 11 0 1 0;
#X connect 18 0 25 1;
#X connect 19 0 25 1;
#X connect 21 0 31 2;
#X connect 22 0 25 0;
#X connect 23 0 25 0;
#X connect 27 0 32 1;
#X connect 28 0 32 1;
#X connect 29 0 32 1;
#X connect 31 0 32 0;
#X connect 32 0 25 0;
