r1008: pt_BR translation update
[cinelerra_cv/mob.git] / plugins / dot / dot.h
blob17453c4fccd7af3ae8a18660174ec813b6f3f2fb
1 #ifndef DOT_H
2 #define DOT_H
4 class DotMain;
5 class DotEngine;
7 #include "bchash.h"
8 #include "effecttv.h"
9 #include "loadbalance.h"
10 #include "mutex.h"
11 #include "pluginvclient.h"
12 #include "dotwindow.h"
14 #include <stdint.h>
17 class DotConfig
19 public:
20 DotConfig();
23 int dot_depth;
24 int dot_size;
25 inline int dot_max()
27 return 1 << dot_depth;
31 class DotPackage : public LoadPackage
33 public:
34 DotPackage();
36 int row1, row2;
39 class DotServer : public LoadServer
41 public:
42 DotServer(DotMain *plugin, int total_clients, int total_packages);
44 LoadClient* new_client();
45 LoadPackage* new_package();
46 void init_packages();
47 DotMain *plugin;
50 class DotClient : public LoadClient
52 public:
53 DotClient(DotServer *server);
55 void process_package(LoadPackage *package);
56 void draw_dot(int xx,
57 int yy,
58 unsigned char c,
59 unsigned char **output_rows,
60 int color_model);
62 unsigned char RGBtoY(unsigned char *row, int color_model);
64 DotMain *plugin;
68 class DotMain : public PluginVClient
70 public:
71 DotMain(PluginServer *server);
72 ~DotMain();
74 // required for all realtime plugins
75 int process_realtime(VFrame *input_ptr, VFrame *output_ptr);
76 int is_realtime();
77 char* plugin_title();
78 int show_gui();
79 void raise_window();
80 int set_string();
81 void load_configuration();
82 void save_data(KeyFrame *keyframe);
83 void read_data(KeyFrame *keyframe);
85 int load_defaults();
86 int save_defaults();
87 VFrame* new_picon();
88 void make_pattern();
89 void init_sampxy_table();
90 void reconfigure();
92 // a thread for the GUI
93 DotThread *thread;
94 DotServer *dot_server;
95 DotClient *dot_client;
96 DotConfig config;
98 BC_Hash *defaults;
99 VFrame *input_ptr, *output_ptr;
100 int dots_width;
101 int dots_height;
102 int dot_size;
103 int dot_hsize;
104 uint32_t *pattern;
105 int *sampx, *sampy;
106 int need_reconfigure;
107 EffectTV *effecttv;
119 #endif