96513dddd8c2922efb26fe60eabe49aa2a4613ae
[goodguy/history.git] / cinelerra-5.1 / plugins / findobject / findobjectwindow.h
1
2 /*
3  * CINELERRA
4  * Copyright (C) 1997-2012 Adam Williams <broadcast at earthling dot net>
5  * 
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2 of the License, or
9  * (at your option) any later version.
10  * 
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14  * GNU General Public License for more details.
15  * 
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
19  * 
20  */
21  
22
23 #ifndef FINDOBJECTWINDOW_H
24 #define FINDOBJECTWINDOW_H
25
26 #include "guicast.h"
27 #include "findobject.inc"
28
29 class FindObjectLayer : public BC_TumbleTextBox
30 {
31 public:
32         FindObjectLayer(FindObjectMain *plugin, 
33                 FindObjectWindow *gui, 
34                 int x, 
35                 int y,
36                 int *value);
37         int handle_event();
38         static int calculate_w(FindObjectWindow *gui);
39         FindObjectMain *plugin;
40         FindObjectWindow *gui;
41         int *value;
42 };
43
44 class FindObjectGlobalRange : public BC_IPot
45 {
46 public:
47         FindObjectGlobalRange(FindObjectMain *plugin, 
48                 int x, 
49                 int y,
50                 int *value);
51         int handle_event();
52         FindObjectMain *plugin;
53         int *value;
54 };
55
56 class FindObjectBlockSize : public BC_FPot
57 {
58 public:
59         FindObjectBlockSize(FindObjectMain *plugin, 
60                 int x, 
61                 int y,
62                 float *value);
63         int handle_event();
64         FindObjectMain *plugin;
65         float *value;
66 };
67
68 class FindObjectBlockCenterText;
69
70 class FindObjectBlockCenter : public BC_FPot
71 {
72 public:
73         FindObjectBlockCenter(FindObjectMain *plugin, 
74                 FindObjectWindow *gui,
75                 int x, 
76                 int y,
77                 float *value);
78         int handle_event();
79         FindObjectWindow *gui;
80         FindObjectMain *plugin;
81         FindObjectBlockCenterText *center_text;
82         float *value;
83 };
84
85 class FindObjectBlockCenterText : public BC_TextBox
86 {
87 public:
88         FindObjectBlockCenterText(FindObjectMain *plugin, 
89                 FindObjectWindow *gui,
90                 int x, 
91                 int y,
92                 float *value);
93         int handle_event();
94         FindObjectWindow *gui;
95         FindObjectMain *plugin;
96         FindObjectBlockCenter *center;
97         float *value;
98 };
99
100
101
102 class FindObjectDrawBorder : public BC_CheckBox
103 {
104 public:
105         FindObjectDrawBorder(FindObjectMain *plugin, 
106                 FindObjectWindow *gui,
107                 int x, 
108                 int y);
109         int handle_event();
110         FindObjectMain *plugin;
111         FindObjectWindow *gui;
112 };
113
114 class FindObjectDrawKeypoints : public BC_CheckBox
115 {
116 public:
117         FindObjectDrawKeypoints(FindObjectMain *plugin, 
118                 FindObjectWindow *gui,
119                 int x, 
120                 int y);
121         int handle_event();
122         FindObjectMain *plugin;
123         FindObjectWindow *gui;
124 };
125
126 class FindObjectReplace : public BC_CheckBox
127 {
128 public:
129         FindObjectReplace(FindObjectMain *plugin, 
130                 FindObjectWindow *gui,
131                 int x, 
132                 int y);
133         int handle_event();
134         FindObjectMain *plugin;
135         FindObjectWindow *gui;
136 };
137
138
139 class FindObjectDrawObjectBorder : public BC_CheckBox
140 {
141 public:
142         FindObjectDrawObjectBorder(FindObjectMain *plugin, 
143                 FindObjectWindow *gui,
144                 int x, 
145                 int y);
146         int handle_event();
147         FindObjectMain *plugin;
148         FindObjectWindow *gui;
149 };
150
151
152
153
154 class FindObjectAlgorithm : public BC_PopupMenu
155 {
156 public:
157         FindObjectAlgorithm(FindObjectMain *plugin, 
158                 FindObjectWindow *gui, 
159                 int x, 
160                 int y);
161         int handle_event();
162         void create_objects();
163         static int calculate_w(FindObjectWindow *gui);
164         static int from_text(char *text);
165         static char* to_text(int mode);
166         FindObjectMain *plugin;
167         FindObjectWindow *gui;
168 };
169
170
171 class FindObjectCamParam : public BC_IPot
172 {
173 public:
174         FindObjectCamParam(FindObjectMain *plugin, 
175                 int x, 
176                 int y,
177                 int *value);
178         int handle_event();
179         FindObjectMain *plugin;
180         int *value;
181 };
182
183
184 class FindObjectBlend : public BC_IPot
185 {
186 public:
187         FindObjectBlend(FindObjectMain *plugin, 
188                 int x, 
189                 int y,
190                 int *value);
191         int handle_event();
192         FindObjectMain *plugin;
193         int *value;
194 };
195
196
197 class FindObjectWindow : public PluginClientWindow
198 {
199 public:
200         FindObjectWindow(FindObjectMain *plugin);
201         ~FindObjectWindow();
202
203         void create_objects();
204         char* get_radius_title();
205
206         FindObjectGlobalRange *global_range_w;
207         FindObjectGlobalRange *global_range_h;
208         FindObjectBlockSize *global_block_w;
209         FindObjectBlockSize *global_block_h;
210         FindObjectBlockCenter *block_x;
211         FindObjectBlockCenter *block_y;
212         FindObjectBlockCenterText *block_x_text;
213         FindObjectBlockCenterText *block_y_text;
214         FindObjectDrawKeypoints *draw_keypoints;
215         FindObjectDrawBorder *draw_border;
216         FindObjectReplace *replace_object;
217         FindObjectDrawObjectBorder *draw_object_border;
218         FindObjectLayer *object_layer;
219         FindObjectLayer *scene_layer;
220         FindObjectLayer *replace_layer;
221         FindObjectAlgorithm *algorithm;
222         FindObjectCamParam *vmin;
223         FindObjectCamParam *vmax;
224         FindObjectCamParam *smin;
225         FindObjectBlend *blend;
226         FindObjectMain *plugin;
227 };
228
229
230
231
232
233 #endif // FINDOBJECTWINDOW_H
234
235
236