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 "arraylist.h"
30 #include "keyframe.inc"
32 #include "mwindow.inc"
33 #include "pluginserver.inc"
34 #include "recordableatracks.inc"
39 // The plugin array does the real work of a non realtime effect.
42 class PluginArray : public ArrayList<PluginServer*>
45 PluginArray(int data_type);
46 virtual ~PluginArray();
48 PluginServer* scan_plugindb(char *title);
49 int start_plugins(MWindow *mwindow,
51 PluginServer *plugin_server,
58 virtual void create_modules() {};
59 virtual void create_buffers() {};
60 virtual void get_buffers() {};
62 * virtual void load_module(int module,
63 * int64_t input_position,
66 virtual void process_realtime(int module,
67 int64_t input_position,
69 virtual int process_loop(int module, int64_t &write_length) { return 0; }
70 virtual int write_buffers(int64_t len) { return 0; }
71 virtual int64_t get_bufsize() { return 0; }
72 virtual int total_tracks() { return 0; }
73 virtual void get_recordable_tracks() {}
74 virtual Track* track_number(int number) { return 0; }
75 virtual int write_samples_derived(int64_t samples_written) { return 0; }
76 virtual int write_frames_derived(int64_t frames_written) { return 0; }
77 virtual int start_plugins_derived() { return 0; }
78 virtual int start_realtime_plugins_derived() { return 0; }
79 virtual int stop_plugins_derived() { return 0; }
80 virtual int render_track(int track, int64_t fragment_len, int64_t position) { return 0; }
86 PluginServer *plugin_server;
91 // Start and end of segment in units