r125: This commit was manufactured by cvs2svn to create tag 'r1_1_7-last'.
[cinelerra_cv/mob.git] / hvirtual / plugins / blurzoom / blurzoom.h
blobd9eef8e255e9e52adfa17de799894f551da02017
1 #ifndef BLURZOOM_H
2 #define BLURZOOM_H
4 class BlurZoomMain;
5 class BlurZoomEngine;
7 #include "defaults.h"
8 #include "loadbalance.h"
9 #include "mutex.h"
10 #include "pluginvclient.h"
11 #include "blurzoomwindow.h"
12 #include <sys/types.h>
14 #define SCRATCH_MAX 20
17 typedef struct _scratch
19 int life;
20 int x;
21 int dx;
22 int init;
23 } scratch_t;
25 class BlurZoomConfig
27 public:
28 BlurZoomConfig();
32 class BlurZoomPackage : public LoadPackage
34 public:
35 BlurZoomPackage();
37 int row1, row2;
40 class BlurZoomServer : public LoadServer
42 public:
43 BlurZoomServer(BlurZoomMain *plugin, int total_clients, int total_packages);
45 LoadClient* new_client();
46 LoadPackage* new_package();
47 void init_packages();
48 BlurZoomMain *plugin;
51 class BlurZoomClient : public LoadClient
53 public:
54 BlurZoomClient(BlurZoomServer *server);
56 void process_package(LoadPackage *package);
58 BlurZoomMain *plugin;
62 class BlurZoomMain : public PluginVClient
64 public:
65 BlurZoomMain(PluginServer *server);
66 ~BlurZoomMain();
68 // required for all realtime plugins
69 int process_realtime(VFrame *input_ptr, VFrame *output_ptr);
70 int is_realtime();
71 char* plugin_title();
72 int start_realtime();
73 int stop_realtime();
74 int show_gui();
75 void raise_window();
76 int set_string();
77 void load_configuration();
78 void save_data(KeyFrame *keyframe);
79 void read_data(KeyFrame *keyframe);
81 int load_defaults();
82 int save_defaults();
83 VFrame* new_picon();
85 // a thread for the GUI
86 BlurZoomThread *thread;
87 BlurZoomServer *blurzoom_server;
88 BlurZoomClient *blurzoom_client;
89 BlurZoomConfig config;
91 unsigned char *blurzoombuf;
92 int *blurzoomx;
93 int *blurzoomy;
94 int buf_width_blocks;
95 int buf_width;
96 int buf_height;
97 int buf_area;
98 int buf_margin_right;
99 int buf_margin_left;
101 #define COLORS 32
102 int palette_r[COLORS];
103 int palette_g[COLORS];
104 int palette_b[COLORS];
106 int y_threshold;
108 Defaults *defaults;
109 BlurZoomEngine **engine;
110 VFrame *input_ptr, *output_ptr;
122 #endif