aboutsummaryrefslogtreecommitdiff
path: root/pix_opencv_of_hs-help.pd
blob: c0baf2c24afadef69f2702e3d8131b82f22bda9a (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
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
#N canvas 1644 152 1339 660 10;
#X obj 977 55 cnv 15 220 70 empty empty empty 20 12 0 14 -195568 -66577
0;
#N canvas 189 149 454 304 gemwin 0;
#X obj 130 218 gemwin;
#X obj 67 89 outlet;
#X obj 67 10 inlet;
#X obj 67 41 route create;
#X msg 67 70 set destroy;
#X msg 182 68 set create;
#X msg 129 165 create \, 1;
#X msg 205 166 destroy;
#N canvas 87 154 363 340 Gem.init 0;
#X obj 112 15 loadbang;
#X msg 62 93 reset;
#X obj 49 135 outlet;
#X msg 107 89 dimen 320 240;
#X obj 107 51 t b b b;
#X connect 0 0 4 0;
#X connect 1 0 2 0;
#X connect 3 0 2 0;
#X connect 4 0 3 0;
#X connect 4 2 1 0;
#X restore 289 80 pd Gem.init;
#X obj 128 109 t b b b;
#X msg 247 137 frame 25;
#X msg 156 138 dimen 640 480;
#X connect 2 0 3 0;
#X connect 3 0 4 0;
#X connect 3 0 9 0;
#X connect 3 1 5 0;
#X connect 3 1 7 0;
#X connect 4 0 1 0;
#X connect 5 0 1 0;
#X connect 6 0 0 0;
#X connect 7 0 0 0;
#X connect 9 0 6 0;
#X connect 9 1 11 0;
#X connect 9 2 10 0;
#X connect 10 0 0 0;
#X connect 11 0 0 0;
#X restore 983 98 pd gemwin;
#X msg 983 77 create;
#X text 986 59 Create window and render;
#X obj 427 308 cnv 15 600 300 empty empty empty 20 12 0 14 -24198 -66577
0;
#X obj 559 504 unpack f f;
#X floatatom 645 504 5 0 0 0 - - -;
#X floatatom 647 524 5 0 0 0 - - -;
#X text 687 503 largest amplitude of movement;
#X text 687 524 angle of the block with the maximum movement;
#X text 685 536 ( in degrees [-180 \, 180]);
#X floatatom 506 553 5 0 0 0 - - -;
#X text 548 574 marked with a white arrow on the stream;
#X text 548 550 average angle of the blocks movement;
#X text 547 562 ( in degrees [-180 \, 180]);
#X obj 507 -62 gemhead;
#X obj 454 228 separator;
#X obj 561 -62 bng 25 250 50 0 load empty empty 0 -6 0 8 -262144 -1
-1;
#X obj 618 113 bng 15 250 50 0 empty empty end_reached 20 7 0 10 -262144
-1 -1;
#X floatatom 600 78 5 0 10000 1 frame# - -;
#X obj 561 -33 openpanel;
#X msg 561 -13 open \$1;
#X obj 549 96 pix_film;
#X msg 567 30 auto \$1;
#X obj 567 12 tgl 15 0 empty empty empty 0 -6 0 8 -262144 -1 -1 1 1
;
#X msg 662 13 colorspace RGBA;
#X msg 767 13 colorspace RGB;
#X msg 871 13 colorspace Grey;
#X obj 662 -15 loadbang;
#X obj 296 224 separator;
#X obj 296 250 translateXYZ -2 0 0;
#X obj 454 253 translateXYZ 2 0 0;
#N canvas 0 22 450 300 vswitch 0;
#X obj 144 263 outlet;
#X obj 36 26 inlet;
#X obj 260 29 inlet;
#X obj 36 133 spigot;
#X obj 260 141 spigot;
#X obj 119 64 loadbang;
#X msg 83 93 0;
#X msg 113 93 1;
#X msg 296 104 0;
#X msg 326 104 1;
#X obj 399 34 inlet;
#X obj 399 67 select 0;
#X connect 1 0 3 0;
#X connect 2 0 4 0;
#X connect 3 0 0 0;
#X connect 4 0 0 0;
#X connect 5 0 7 0;
#X connect 5 0 8 0;
#X connect 6 0 3 1;
#X connect 7 0 3 1;
#X connect 8 0 4 1;
#X connect 9 0 4 1;
#X connect 10 0 11 0;
#X connect 11 0 7 0;
#X connect 11 0 8 0;
#X connect 11 1 9 0;
#X connect 11 1 6 0;
#X restore 385 125 pd vswitch;
#X obj 453 125 tgl 15 0 empty load empty 17 7 0 10 -262144 -1 -1 0
1;
#X obj 312 94 pix_video;
#X obj 315 -64 gemhead;
#X msg 351 19 device 0;
#X msg 360 50 driver 1;
#X msg 337 -35 dialog;
#X msg 342 -5 device /dev/dv1394-0;
#X obj 293 613 pix_texture;
#X obj 293 641 square 2;
#X obj 454 618 pix_texture;
#X text 504 146 this object can work on small frames unless you have
a very powerful machine;
#X obj 455 642 square 2;
#X obj 295 201 pix_separator;
#X obj 454 205 pix_separator;
#X obj 454 472 pix_opencv_of_hs;
#X obj 596 402 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0
1;
#X msg 511 400 nightmode \$1;
#X floatatom 557 323 5 0 0 0 - - -;
#X floatatom 585 347 5 0 0 0 - - -;
#X msg 498 345 threshold \$1;
#X obj 620 433 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0
1;
#X msg 520 432 useprevious \$1;
#X text 642 431 use previous results ( default : 0 \, surprising results
when on );
#X msg 501 374 minblocks \$1;
#X floatatom 588 375 5 0 0 0 - - -;
#X text 615 403 set nightmode;
#X text 632 369 minimum nuber of blocks to detect the movement;
#X msg 487 320 lambda \$1;
#X text 600 320 set Lagragian multiplier ( default 1 );
#X text 629 382 ( default 10 );
#X text 627 344 threshold value for the detection of movement ( default
100 );
#X text 971 253 with a great help from Mateu Batle & Alberto de Rodrigo
from the iBit foundation.;
#X text 970 217 the main purpose of this object is to calculate the
average direction and the intensity of the movement in a video stream.
;
#X text 971 277 comments to ydegoyon@gmail.com;
#X text 972 132 pix_opencv_of_hs : Haron and Schunck optical flow algorithm.
;
#X obj 385 160 pix_resize 320 240;
#X obj 385 182 pix_rgba;
#X text 971 153 IMPORTANT: this object is quite experimental. For OpticalFlow
analisys we recommend [pix_opencv_of_bm];
#X obj 975 184 pix_opencv_of_bm;
#X connect 1 0 2 0;
#X connect 2 0 1 0;
#X connect 5 0 6 0;
#X connect 5 1 7 0;
#X connect 15 0 22 0;
#X connect 16 0 31 0;
#X connect 17 0 20 0;
#X connect 18 0 19 0;
#X connect 19 0 22 1;
#X connect 20 0 21 0;
#X connect 21 0 22 0;
#X connect 22 0 32 1;
#X connect 22 2 18 0;
#X connect 23 0 22 0;
#X connect 24 0 23 0;
#X connect 25 0 22 0;
#X connect 25 0 34 0;
#X connect 26 0 22 0;
#X connect 27 0 22 0;
#X connect 28 0 25 0;
#X connect 28 0 24 0;
#X connect 29 0 30 0;
#X connect 30 0 40 0;
#X connect 31 0 47 0;
#X connect 32 0 68 0;
#X connect 33 0 32 2;
#X connect 34 0 32 0;
#X connect 35 0 34 0;
#X connect 36 0 34 0;
#X connect 37 0 34 0;
#X connect 38 0 34 0;
#X connect 39 0 34 0;
#X connect 40 0 41 0;
#X connect 42 0 44 0;
#X connect 45 0 29 0;
#X connect 46 0 16 0;
#X connect 47 0 42 0;
#X connect 47 1 11 0;
#X connect 47 2 5 0;
#X connect 48 0 49 0;
#X connect 49 0 47 0;
#X connect 50 0 60 0;
#X connect 51 0 52 0;
#X connect 52 0 47 0;
#X connect 53 0 54 0;
#X connect 54 0 47 0;
#X connect 56 0 47 0;
#X connect 57 0 56 0;
#X connect 60 0 47 0;
#X connect 68 0 69 0;
#X connect 69 0 45 0;
#X connect 69 0 46 0;