add auto zoombar/status color, fix 3 batchrender boobies, rotate plugin tweaks, add...
[goodguy/cinelerra.git] / cinelerra-5.1 / plugins / holo / holo.h
1
2 /*
3  * CINELERRA
4  * Copyright (C) 2008 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 #ifndef HOLO_H
23 #define HOLO_H
24
25 class HoloMain;
26 class HoloEngine;
27
28 #include "bchash.h"
29 #include "effecttv.h"
30 #include "holowindow.h"
31 #include "loadbalance.h"
32 #include "mutex.h"
33 #include "bccolors.inc"
34 #include "pluginvclient.h"
35
36 #include <stdint.h>
37
38
39 class HoloConfig
40 {
41 public:
42         HoloConfig();
43
44
45         int threshold;
46         double recycle;    // Number of seconds between recycles
47 };
48
49 class HoloPackage : public LoadPackage
50 {
51 public:
52         HoloPackage();
53
54         int row1, row2;
55 };
56
57 class HoloServer : public LoadServer
58 {
59 public:
60         HoloServer(HoloMain *plugin, int total_clients, int total_packages);
61
62         LoadClient* new_client();
63         LoadPackage* new_package();
64         void init_packages();
65         HoloMain *plugin;
66 };
67
68 class HoloClient : public LoadClient
69 {
70 public:
71         HoloClient(HoloServer *server);
72
73         void process_package(LoadPackage *package);
74
75         HoloMain *plugin;
76         int phase;
77 };
78
79
80 class HoloMain : public PluginVClient
81 {
82 public:
83         HoloMain(PluginServer *server);
84         ~HoloMain();
85
86 // required for all realtime plugins
87         PLUGIN_CLASS_MEMBERS(HoloConfig)
88         int process_realtime(VFrame *input_ptr, VFrame *output_ptr);
89         int is_realtime();
90         void save_data(KeyFrame *keyframe);
91         void read_data(KeyFrame *keyframe);
92
93         void reconfigure();
94
95
96         void add_frames(VFrame *output, VFrame *input);
97         void set_background();
98
99         HoloServer *holo_server;
100
101         VFrame *input_ptr, *output_ptr;
102         int do_reconfigure;
103         EffectTV *effecttv;
104
105         unsigned int noisepattern[256];
106         VFrame *bgimage, *tmp;
107         int total;
108 };
109
110
111
112
113
114
115
116
117
118
119 #endif