blob: a2fd7df4a3ad3710244a9a7c4a9d43a57f986685 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
|
#N canvas 295 0 632 642 10;
#X obj 172 147 #in;
#X obj 135 181 #store;
#X obj 135 46 tgl 15 0 empty empty empty 0 -6 0 8 -233017 -1 -1 0 1
;
#X obj 135 74 metro 40;
#X obj 135 283 #out window \, title #draw_image-help;
#X obj 172 99 bng 15 250 50 0 empty empty empty 0 -6 0 8 -233017 -1
-1;
#X obj 188 209 #in;
#X obj 188 169 bng 15 250 50 0 empty empty empty 0 -6 0 8 -233017 -1
-1;
#X text 194 101 2 <-- open background image;
#X text 211 171 1 <-- open foreground image;
#X obj 387 238 #dim;
#X obj 387 257 #to_list;
#X obj 387 276 unpack f f;
#X obj 393 295 pack f f;
#X obj 393 314 # / 2;
#X obj 368 314 # -;
#X obj 135 307 #mouse;
#X text 159 48 3 <-- activate rendering;
#X msg 188 190 load g001.jpg;
#X msg 172 120 load r001.jpg;
#X msg 275 257 0 0;
#X obj 275 238 loadbang;
#X text 135 331 Move mouse cursor to change layer position;
#X obj 0 0 doc_h;
#X obj 3 455 doc_i 3;
#X obj 3 775 doc_o 1;
#X obj 14 805 doc_oo 0;
#X obj 14 485 doc_ii 0;
#X obj 14 708 doc_ii 1;
#X obj 14 730 doc_ii 2;
#X text 232 397 Normally \, you would use the "put" operator \; but
others (like + and ^) can be interesting for color effects.;
#X obj 135 258 #draw_image *>>8;
#X obj 3 367 doc_c 1;
#X obj 14 397 doc_cc 0;
#X text 232 485 Background image.;
#X msg 321 197 tile;
#X text 232 708 Foreground image.;
#X text 232 673 If 1 \, foreground image will be repeated to cover
the background image.;
#X text 232 529 If 1 \, foreground image (inlet 1) will be combined
with background image (inlet 0) \, and then blended with background
image according to transparency of foreground image \, and then inserted
in the result. If 0 \, the blending doesn't occur \, as the transparency
level is considered "opaque". Note that with alpha enabled \, the last
channel of foreground image is cnsidered to represent transparency.
;
#X text 232 730 Initial foreground image position (y x) \, corresponding
to top-left corner of foreground picture.;
#X text 232 805 Resulting image.;
#X obj 97 397 doc_m c0 numop;
#X obj 97 485 doc_m i0 grid;
#X obj 97 651 doc_m i0 tile;
#X obj 97 507 doc_m i0 alpha;
#X text 232 507 \$1=flag;
#X text 232 651 \$1=flag;
#X obj 97 708 doc_m i1 grid;
#X obj 97 730 doc_m i2 (y x);
#X obj 97 805 doc_m o0 grid;
#X obj 0 837 doc_f;
#X obj 97 629 doc_m i0 op;
#X text 232 629 same as arg 0;
#X connect 0 0 1 1;
#X connect 1 0 31 0;
#X connect 2 0 3 0;
#X connect 3 0 1 0;
#X connect 4 0 16 0;
#X connect 5 0 19 0;
#X connect 6 0 10 0;
#X connect 6 0 31 1;
#X connect 7 0 18 0;
#X connect 10 0 11 0;
#X connect 11 0 12 0;
#X connect 12 0 13 0;
#X connect 12 1 13 1;
#X connect 13 0 14 0;
#X connect 14 0 15 1;
#X connect 15 0 31 2;
#X connect 16 0 15 0;
#X connect 16 1 15 0;
#X connect 16 2 15 0;
#X connect 16 3 15 0;
#X connect 18 0 6 0;
#X connect 19 0 0 0;
#X connect 20 0 31 2;
#X connect 21 0 20 0;
#X connect 31 0 4 0;
#X connect 35 0 31 0;
#X connect 41 1 30 0;
#X connect 42 1 34 0;
#X connect 43 1 46 0;
#X connect 43 1 37 0;
#X connect 44 1 45 0;
#X connect 44 1 38 0;
#X connect 47 1 36 0;
#X connect 48 1 39 0;
#X connect 49 1 40 0;
#X connect 51 1 52 0;
|