r125: This commit was manufactured by cvs2svn to create tag 'r1_1_7-last'.
[cinelerra_cv/mob.git] / hvirtual / plugins / spectrogram / spectrogram.h
blobd0760dec1d05e8a6a7494a92b5e6aaee12aac323
1 #ifndef SPECTROGRAM_H
2 #define SPECTROGRAM_H
9 #include "defaults.inc"
10 #include "fourier.h"
11 #include "guicast.h"
12 #include "mutex.h"
13 #include "pluginaclient.h"
14 #include "vframe.inc"
17 #define WINDOW_SIZE 8192
20 class Spectrogram;
21 class SpectrogramFFT;
24 class SpectrogramLevel : public BC_FPot
26 public:
27 SpectrogramLevel(Spectrogram *plugin, int x, int y);
28 int handle_event();
29 Spectrogram *plugin;
33 class SpectrogramWindow : public BC_Window
35 public:
36 SpectrogramWindow(Spectrogram *plugin, int x, int y);
37 ~SpectrogramWindow();
39 void create_objects();
40 int close_event();
41 void update_gui();
43 SpectrogramLevel *level;
44 Spectrogram *plugin;
45 int done;
46 BC_SubWindow *canvas;
51 PLUGIN_THREAD_HEADER(Spectrogram, SpectrogramThread, SpectrogramWindow)
55 class SpectrogramFFT : public CrossfadeFFT
57 public:
58 SpectrogramFFT(Spectrogram *plugin);
59 ~SpectrogramFFT();
61 int signal_process();
63 Spectrogram *plugin;
67 class SpectrogramConfig
69 public:
70 SpectrogramConfig();
71 double level;
75 class Spectrogram : public PluginAClient
77 public:
78 Spectrogram(PluginServer *server);
79 ~Spectrogram();
81 VFrame* new_picon();
82 char* plugin_title();
83 int is_realtime();
84 int process_realtime(int64_t size, double *input_ptr, double *output_ptr);
85 int show_gui();
86 void raise_window();
87 int set_string();
88 void load_configuration();
89 int load_defaults();
90 int save_defaults();
91 void read_data(KeyFrame *keyframe);
92 void save_data(KeyFrame *keyframe);
93 void update_gui();
94 void render_gui(void *data, int size);
96 void reset();
98 int done;
100 int need_reconfigure;
101 Defaults *defaults;
102 SpectrogramConfig config;
103 SpectrogramThread *thread;
104 SpectrogramFFT *fft;
108 #endif