#N canvas 292 28 892 631 10; #X declare -path . -path .. -path data -path ../data -path ev-in -path ../ev-in -path ev-main -path ../ev-main -path ev-pano -path ../ev-pano -path ev-pro -path ../ev-pro -path libs/gil -path ../libs/gil -path libs/kollabs -path ../libs/kollabs -path media -path ../media -path ev-glsl -path ../ev-glsl -lib Gem; #X obj 14 14 cnv 15 860 30 empty empty Example:_Mapping_on_shipping_containers 20 12 0 14 -191407 -1 0; #X obj 14 47 cnv 15 80 40 empty empty empty 2 8 0 10 -261234 -262144 0; #N canvas 217 231 548 468 init 0; #X obj 56 92 loadbang; #X obj 83 138 del 1000; #X obj 56 114 t b b; #X obj 56 281 del 3000; #X obj 44 -23 cnv 15 400 100 empty empty IMPORTANT 20 12 0 14 -261234 -66577 0; #X text 49 -3 Such a declare object should always be in the main patch of your project \, to set the pathes to the abstractions.; #X obj 158 43 ev-main/ev_declare; #X text 165 266 (pathes relative to libs/kollabs); #X msg 83 170 \; /ds/one/loadfile ../../data/ev_example_shipping_containers_one.txt \; /ds/two/loadfile ../../data/ev_example_shipping_containers_two.txt ; #X msg 56 345 \; /ds/one/scene 0 \; /ds/two/scene 0; #X text 159 140 load the preset files on startup:; #X text 66 322 Recall scene '0' from the loaded preset files:; #X connect 0 0 2 0; #X connect 1 0 8 0; #X connect 2 0 3 0; #X connect 2 1 1 0; #X connect 3 0 9 0; #X restore 30 59 pd init; #X obj 101 49 ev_gemwin one; #X obj 484 426 cnv 15 390 300 empty empty Backround_Image 20 12 0 14 -262130 -66577 0; #X obj 579 581 gemhead 50; #X obj 579 603 ev_pic background one; #X obj 579 675 pix_texture; #X obj 579 697 rectangle 5.3333 4; #X text 496 452 As we can not assume that you have access to real shhipping containers and projectors right now \, we will just map onto a picture from Rotterdam.; #X text 496 492 As we can not assume that you have access to real shhipping containers and projectors right now \, we will just map onto a picture from Rotterdam container port.; #X text 496 532 Imagine \, the camera is looking from the same angle as the projector.; #X obj 14 428 cnv 15 460 300 empty empty Projection_Modules 20 12 0 14 -261682 -66577 0; #X obj 29 463 gemhead 51; #X obj 49 499 ev_pro_22 container1 one; #X obj 39 559 ev_pro_22 container2 one; #X obj 29 619 ev_pro_22 container3 one; #X obj 222 450 r /ev/buf/teapot-buffer/texture_id; #X obj 484 737 cnv 15 390 650 empty empty Framebuffer_Contents 20 12 0 14 -204800 -66577 0; #X obj 494 811 tgl 15 0 empty empty show_framebuffer_contents 17 7 0 10 -258113 -1 -1 0 1; #X obj 545 1132 pix_texture; #X obj 494 764 loadbang; #X msg 494 786 0; #X obj 494 1041 gemhead 100; #X obj 608 1109 r /ev/buf/teapot-buffer/texture_id; #X msg 534 889 \; /ev/pro/container1/state \$1 \; /ev/pro/container2/state \$1 \; /ev/pro/container3/state \$1 \;; #X obj 534 845 == 0; #X msg 514 977 \; /ev/texhelper/container1/state \$1 \; /ev/texhelper/container2/state \$1 \; /ev/texhelper/container3/state \$1 \;; #X obj 545 1109 separator; #X obj 494 1068 t a a a a; #X text 569 1087 texture framebuffer contents onto rectangle; #X text 538 1196 show texture positions of the projection modules \; and enable mouse cursor interaction.; #X text 531 959 1: turn on texhelper modules; #X text 543 869 0: turn off cursor interaction for projection modules ; #X text 567 845 invert value; #X obj 14 737 cnv 15 460 155 empty empty Framebuffer_for_projection 20 12 0 14 -203904 -66577 0; #X obj 14 896 cnv 15 460 450 empty empty 3d-scene:_the_rotating_teapot_again 20 12 0 14 -204786 -66577 0; #X obj 20 763 gemhead; #X obj 39 1081 rotateXYZ 0 0 0; #X obj 126 1006 loadbang; #X msg 126 1028 0 \, 360 10000; #X obj 126 1050 line; #X obj 67 1028 sel 360; #X obj 20 809 ev_buf teapot-buffer one; #X obj 20 1291 world_light; #X obj 39 956 separator; #X text 100 1294 light source; #X obj 20 785 alpha; #X obj 39 978 translateXYZ 0 0 0; #X obj 39 1264 teapot 2.5; #X obj 39 1240 color 1 1 1 1; #X text 46 677 The three projection modules all get the same texture. ; #X text 46 695 In the settings dialog \, "set_alpha_to_'1'" is turned off \, to allow a transparent background.; #X obj 114 1214 pack 0 0 0 1; #X obj 114 1116 r /teapot/color/r; #X obj 124 1136 r /teapot/color/g; #X obj 124 1158 t b f; #X obj 164 1180 t b f; #X obj 164 1158 r /teapot/color/b; #X obj 263 1247 ds_reg two /teapot/color/r; #X obj 263 1267 ds_reg two /teapot/color/g; #X obj 263 1287 ds_reg two /teapot/color/b; #X text 232 1225 register color to storage domain "two"; #X obj 20 929 t a a a; #X obj 262 984 ev_pic grid one; #X obj 262 1056 pix_texture; #X obj 545 1156 square 4; #X obj 262 1078 translateXYZ 0 0 -4; #X obj 262 1102 square 8; #X text 240 941 For adjustment of texture coordinates \; show grid behind teapot:; #X obj 755 119 vsl 15 128 0 1 0 0 /teapot/color/r /teapot/color/r R 0 -9 0 10 -258113 -1 -1 12700 1; #X obj 775 119 vsl 15 128 0 1 0 0 /teapot/color/g /teapot/color/g G 0 -9 0 10 -4034 -1 -1 8509 1; #X obj 795 119 vsl 15 128 0 1 0 0 /teapot/color/b /teapot/color/b B 0 -9 0 10 -4160 -1 -1 0 1; #X text 724 15 (C)2012 Narian Weger; #X obj 489 57 loadbang; #X obj 489 127 tgl 15 0 empty empty change_scenes_automatically 17 7 0 10 -260097 -1 -1 1 1; #X obj 489 149 metro 4000; #X obj 489 252 s /ds/one/scene; #X obj 489 211 random 7; #X floatatom 489 233 5 0 0 0 - - -; #X obj 592 189 del 2000; #X obj 592 211 random 4; #X floatatom 592 233 5 0 0 0 - - -; #X obj 592 252 s /ds/two/scene; #X obj 489 79 del 8000; #X msg 489 101 1; #X text 743 80 Teapot Color; #X obj 528 1240 ev_texhelper container1 one; #X obj 511 1290 ev_texhelper container2 one; #X obj 494 1340 ev_texhelper container3 one; #N canvas 198 60 450 300 storage 0; #X obj 125 38 ds_logic one; #X obj 125 58 ds_logic two; #X obj 131 107 ds_transition one; #X obj 135 142 ds_transition two; #X restore 24 101 pd storage; #X obj 15 167 cnv 15 460 250 empty empty Storage 20 12 0 14 -204800 -66577 0; #X obj 36 196 ds_gui one; #X obj 270 191 ds_gui two; #X obj 24 324 ds_transition_gui one; #X obj 247 326 ds_transition_gui two; #X connect 5 0 6 0; #X connect 6 0 7 0; #X connect 7 0 8 0; #X connect 13 0 14 0; #X connect 13 0 15 0; #X connect 13 0 16 0; #X connect 17 0 14 1; #X connect 17 0 15 1; #X connect 17 0 16 1; #X connect 19 0 23 0; #X connect 19 0 27 0; #X connect 19 0 26 0; #X connect 20 0 66 0; #X connect 21 0 22 0; #X connect 22 0 19 0; #X connect 23 0 29 0; #X connect 24 0 20 1; #X connect 26 0 25 0; #X connect 28 0 20 0; #X connect 29 0 89 0; #X connect 29 1 88 0; #X connect 29 2 87 0; #X connect 29 3 28 0; #X connect 37 0 47 0; #X connect 38 0 50 0; #X connect 39 0 40 0; #X connect 40 0 41 0; #X connect 41 0 42 0; #X connect 41 0 38 1; #X connect 41 0 38 2; #X connect 41 0 38 3; #X connect 42 0 40 0; #X connect 43 0 63 0; #X connect 45 0 48 0; #X connect 47 0 43 0; #X connect 48 0 38 0; #X connect 50 0 49 0; #X connect 53 0 50 1; #X connect 54 0 53 0; #X connect 55 0 56 0; #X connect 56 0 53 0; #X connect 56 1 53 1; #X connect 57 0 53 0; #X connect 57 1 53 2; #X connect 58 0 57 0; #X connect 63 0 44 0; #X connect 63 1 45 0; #X connect 63 2 64 0; #X connect 64 0 65 0; #X connect 65 0 67 0; #X connect 67 0 68 0; #X connect 74 0 84 0; #X connect 75 0 76 0; #X connect 76 0 78 0; #X connect 76 0 80 0; #X connect 78 0 79 0; #X connect 79 0 77 0; #X connect 80 0 81 0; #X connect 81 0 82 0; #X connect 82 0 83 0; #X connect 84 0 85 0; #X connect 85 0 75 0; #X coords 0 0 1 1 85 60 0;