Update of /cvsroot/pure-data/doc/tutorials/visual In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32269
Added Files: 03.gemwin_control.pd 04.render_chains.pd 05.basic_2d_objects.pd 06.lighting.pd 07.basic_3d_objects.pd 08.manipulations.pd 09.gem_units.pd 10.exercise.pd Removed Files: 03.render_chains.pd 04.basic_2d_objects.pd 05.lighting.pd 06.basic_3d_objects.pd Log Message: got a basic intro order
--- NEW FILE: 05.basic_2d_objects.pd --- #N canvas 20 42 632 472 10; #X obj 8 10 cnv 15 400 40 empty empty basic_2d_objects 20 12 0 24 -228992 -66577 0; #X obj 168 196 gemhead; #X obj 167 168 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 168 224 square; #X obj 28 196 gemhead; #X obj 27 168 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 98 196 gemhead; #X obj 97 168 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 28 224 circle; #X obj 98 224 triangle; #X text 8 147 two-dimensional (2D); #X obj 230 196 gemhead; #X obj 229 168 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 230 224 rectangle; #X obj 465 16 gemwin_control; #X obj 466 60 import Gem; #X obj 306 196 gemhead; #X obj 305 168 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 306 224 colorSquare; #X obj 396 196 gemhead; #X obj 395 168 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 396 224 curve 5; #X obj 466 196 gemhead; #X obj 465 168 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 466 224 text2d; #X text 17 430 If you click and drag in the gemwin , you can change your view perspective , and see that these objects are only 2D.; #X connect 1 0 3 0; #X connect 2 0 1 0; #X connect 4 0 8 0; #X connect 5 0 4 0; #X connect 6 0 9 0; #X connect 7 0 6 0; #X connect 11 0 13 0; #X connect 12 0 11 0; #X connect 16 0 18 0; #X connect 17 0 16 0; #X connect 19 0 21 0; #X connect 20 0 19 0; #X connect 22 0 24 0; #X connect 23 0 22 0;
--- NEW FILE: 06.lighting.pd --- #N canvas 613 242 628 468 10; #X obj 8 10 cnv 15 400 40 empty empty lighting 20 12 0 24 -228992 -66577 0; #X obj 465 16 gemwin_control; #X obj 466 60 import Gem; #X obj 83 173 gemwin; #X msg 83 152 lighting $1; #X obj 83 134 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 1 1 ; #X obj 465 121 gemhead; #X obj 465 162 sphere 1 35; #X obj 22 233 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 22 253 world_light; #X text 465 103 example sphere; #X text 11 54 No world would be complete without lighting. Gem provides three different kinds of light sources. Like rendering , the calculation of lighting needs to be turned on by sending a message to [gemwin] , since lighting is a GPU-intensive operation.; #X obj 2 194 gemhead; #X obj 22 304 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 22 354 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 1 1 ; #X obj 22 424 spot_light; #X obj 22 324 light; #X msg 54 403 0 0 1; #X msg 52 301 0 1 0; #X msg 62 231 1 0 0; #X text 125 223 A [world_light] is a light that is infinitely far away , basically like sunlight. The rays coming from a [world_light] are always parallel.; #X text 124 306 [light] generates a point-light that is part of the scene. It is basically like a lamp. You can place the lamp directly in your scene.; #X msg 30 384 debug $1; #X obj 46 365 tgl 15 0 empty empty empty 0 -6 0 8 -262144 -1 -1 1 1 ; #X text 124 386 A [spot_light] generates a spot light which you can move around. It can be used for pinpoint light or widened to cover a larger area. If you turn on the debug feature , you will see a little cone where the light source is.; #X obj 465 142 translateXYZ 0 0 -2; #X connect 4 0 3 0; #X connect 5 0 4 0; #X connect 6 0 25 0; #X connect 8 0 9 0; #X connect 12 0 9 0; #X connect 12 0 16 0; #X connect 12 0 15 0; #X connect 13 0 16 0; #X connect 14 0 15 0; #X connect 17 0 15 1; #X connect 18 0 16 1; #X connect 19 0 9 1; #X connect 22 0 15 0; #X connect 23 0 22 0; #X connect 25 0 7 0;
--- NEW FILE: 08.manipulations.pd --- #N canvas 15 58 632 452 10; #X obj 8 10 cnv 15 400 40 empty empty manipulations 20 12 0 24 -228992 -66577 0; #X obj 465 16 gemwin_control; #X obj 466 60 import Gem;
--- NEW FILE: 03.gemwin_control.pd --- #N canvas 10 40 624 464 10; #X obj 8 10 cnv 15 400 40 empty empty gemwin_control 20 12 0 24 -228992 -66577 0; #X obj 465 16 gemwin_control; #X obj 466 60 import Gem; #X text 20 78 From now on in this tutorial , the [gemwin_control] object will be used to control the gemwin. It is just a handy shortcut with a GUI for controlling the window creation/destruction and the rendering.; #X obj 166 273 gemwin_control; #X text 22 161 - The "window" checkbox sends [create( and [destroy( to [gemwin]; #X text 24 197 - the "render" checkbox sends 1 or 0 to [gemwin] to control the rendering.; #X text 23 341 Each checkbox will turn green when enabled. When the whole object turns green , that means everything is ready to display data in the gemwin.;
--- 03.render_chains.pd DELETED ---
--- NEW FILE: 09.gem_units.pd --- #N canvas 574 327 632 452 10; #X obj 8 10 cnv 15 400 40 empty empty gem_units 20 12 0 24 -228992 -66577 0; #X obj 465 16 gemwin_control; #X obj 466 60 import Gem; #X obj 179 155 gemhead; #X obj 178 127 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 1 1 ; #X obj 84 329 gemhead; #X obj 83 301 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 1 1 ; #X obj 84 387 circle 1; #X obj 179 183 circle 1; #X text 12 69 Everything in Gem uses the same units for measurement of space. First we have here a circle with a radius of 1:; #X text 15 235 Here a circle with a radius of one is moved 1 unit on the X-axis. You can see that the center points of the circles below are at the edge of the above circle.; #X obj 263 329 gemhead; #X obj 262 301 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 263 387 circle 1; #X obj 263 359 translateXYZ 0 1 0; #X obj 84 359 translateXYZ 1 0 0; #X connect 3 0 8 0; #X connect 4 0 3 0; #X connect 5 0 15 0; #X connect 6 0 5 0; #X connect 11 0 14 0; #X connect 12 0 11 0; #X connect 14 0 13 0; #X connect 15 0 7 0;
--- 05.lighting.pd DELETED ---
--- NEW FILE: 04.render_chains.pd --- #N canvas 10 40 624 464 10; #X obj 8 10 cnv 15 400 40 empty empty render_chains 20 12 0 24 -228992 -66577 0; #X obj 208 217 gemhead; #X obj 209 172 tgl 15 1 empty empty empty 0 -6 0 8 -262144 -1 -1 1 1; #X obj 207 266 square; #X text 31 74 Gem operates on "render chains". Render chains define the flow and ordering of the rendering of graphics to the Gem world that you see in the [gemwin].; #X text 29 353 Every render chain must start with a [gemhead] , or it will not be generated. Render chains generally end with an shape object (sometimes called a "geo").; #X obj 465 16 gemwin_control; #X obj 466 60 import Gem; #X connect 1 0 3 0; #X connect 2 0 1 0;
--- NEW FILE: 10.exercise.pd --- #N canvas 10 40 620 460 10; #X obj 8 10 cnv 15 400 40 empty empty exercise 20 12 0 24 -228992 -66577 0; #X obj 465 16 gemwin_control; #X obj 466 60 import Gem; #X text 14 68 EXERCISE:; #X text 14 92 Build a patch that allows you to move an object around the Gem windows and change its color.;
--- 04.basic_2d_objects.pd DELETED ---
--- NEW FILE: 07.basic_3d_objects.pd --- #N canvas 283 71 624 464 10; #X obj 8 10 cnv 15 400 40 empty empty basic_3D_objects 20 12 0 24 -228992 -66577 0; #X obj 29 120 gemwin; #X msg 28 63 create , 1; #X msg 42 90 destroy; #X obj 39 190 gemhead; #X obj 38 162 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 39 218 cube; #X obj 99 190 gemhead; #X obj 98 162 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 99 218 sphere; #X obj 159 190 gemhead; #X obj 158 162 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 159 218 cone; #X obj 221 191 gemhead; #X obj 220 163 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 281 191 gemhead; #X obj 280 163 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 281 219 teapot; #X obj 221 219 tube; #X obj 341 191 gemhead; #X obj 340 163 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 341 219 torus; #X obj 465 16 gemwin_control; #X obj 466 60 import Gem; #X obj 401 191 gemhead; #X obj 400 163 tgl 15 1 empty empty empty 0 -6 0 8 -24198 -1 -1 0 1 ; #X obj 401 219 cuboid; #X connect 2 0 1 0; #X connect 3 0 1 0; #X connect 4 0 6 0; #X connect 5 0 4 0; #X connect 7 0 9 0; #X connect 8 0 7 0; #X connect 10 0 12 0; #X connect 11 0 10 0; #X connect 13 0 18 0; #X connect 14 0 13 0; #X connect 15 0 17 0; #X connect 16 0 15 0; #X connect 19 0 21 0; #X connect 20 0 19 0; #X connect 24 0 26 0; #X connect 25 0 24 0;
--- 06.basic_3d_objects.pd DELETED ---