4 * Copyright (C) 2008 Adam Williams <broadcast at earthling dot net>
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.
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.
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
26 #include "bcdisplayinfo.h"
33 #include "loadbalance.h"
34 #include "pluginvclient.h"
47 #define RESET_DEFAULT_SETTINGS 10
49 #define RESET_AMPLITUDE 1
51 #define RESET_WAVELENGTH 3
56 class WaveDefaultSettings;
64 void reset(int clear);
65 void copy_from(WaveConfig &src);
66 int equivalent(WaveConfig &src);
67 void interpolate(WaveConfig &prev,
79 class WaveSmear : public BC_Radial
82 WaveSmear(WaveEffect *plugin, WaveWindow *window, int x, int y);
88 class WaveBlacken : public BC_Radial
91 WaveBlacken(WaveEffect *plugin, WaveWindow *window, int x, int y);
98 class WaveReflective : public BC_CheckBox
101 WaveReflective(WaveEffect *plugin, int x, int y);
106 class WaveAmplitude : public BC_FSlider
109 WaveAmplitude(WaveEffect *plugin, int x, int y);
114 class WavePhase : public BC_FSlider
117 WavePhase(WaveEffect *plugin, int x, int y);
122 class WaveLength : public BC_FSlider
125 WaveLength(WaveEffect *plugin, int x, int y);
130 class WaveReset : public BC_GenericButton
133 WaveReset(WaveEffect *plugin, WaveWindow *gui, int x, int y);
140 class WaveDefaultSettings : public BC_GenericButton
143 WaveDefaultSettings(WaveEffect *plugin, WaveWindow *gui, int x, int y, int w);
144 ~WaveDefaultSettings();
150 class WaveSliderClr : public BC_GenericButton
153 WaveSliderClr(WaveEffect *plugin, WaveWindow *gui, int x, int y, int w, int clear);
165 class WaveWindow : public PluginClientWindow
168 WaveWindow(WaveEffect *plugin);
170 void create_objects();
172 void update_gui(int clear);
176 // WaveBlacken *blacken;
177 // WaveReflective *reflective;
178 WaveAmplitude *amplitude;
180 WaveLength *wavelength;
182 WaveDefaultSettings *default_settings;
183 WaveSliderClr *amplitudeClr;
184 WaveSliderClr *phaseClr;
185 WaveSliderClr *wavelengthClr;
194 class WaveServer : public LoadServer
197 WaveServer(WaveEffect *plugin, int cpus);
198 void init_packages();
199 LoadClient* new_client();
200 LoadPackage* new_package();
204 class WavePackage : public LoadPackage
211 class WaveUnit : public LoadClient
214 WaveUnit(WaveEffect *plugin, WaveServer *server);
215 void process_package(LoadPackage *package);
227 class WaveEffect : public PluginVClient
230 WaveEffect(PluginServer *server);
233 PLUGIN_CLASS_MEMBERS(WaveConfig)
234 int process_realtime(VFrame *input, VFrame *output);
236 void save_data(KeyFrame *keyframe);
237 void read_data(KeyFrame *keyframe);
241 VFrame *input, *output;