r125: This commit was manufactured by cvs2svn to create tag 'r1_1_7-last'.
[cinelerra_cv/mob.git] / hvirtual / plugins / gain / gain.h
blob30618311f5220c0729cc208f6a2b7419d5e39c11
1 #ifndef GAIN_H
2 #define GAIN_H
4 class Gain;
5 class GainEngine;
7 #include "gainwindow.h"
8 #include "pluginaclient.h"
10 class GainConfig
12 public:
13 GainConfig();
14 int equivalent(GainConfig &that);
15 void copy_from(GainConfig &that);
16 void interpolate(GainConfig &prev,
17 GainConfig &next,
18 int64_t prev_frame,
19 int64_t next_frame,
20 int64_t current_frame);
22 double level;
25 class Gain : public PluginAClient
27 public:
28 Gain(PluginServer *server);
29 ~Gain();
31 int process_realtime(int64_t size, double *input_ptr, double *output_ptr);
33 PLUGIN_CLASS_MEMBERS(GainConfig, GainThread)
34 void save_data(KeyFrame *keyframe);
35 void read_data(KeyFrame *keyframe);
36 int load_defaults();
37 int save_defaults();
38 void update_gui();
39 int is_realtime();
42 DB db;
45 class GainEngine : public Thread
47 public:
48 GainEngine(Gain *plugin);
49 ~GainEngine();
51 int process_overlay(double *in, double *out, double &out1, double &out2, double level, int64_t lowpass, int64_t samplerate, int64_t size);
52 int process_overlays(int output_buffer, int64_t size);
53 int wait_process_overlays();
54 void run();
56 Mutex input_lock, output_lock;
57 int completed;
58 int output_buffer;
59 int64_t size;
60 Gain *plugin;
63 #endif