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
33 #include "indexable.inc"
34 #include "mainsession.inc"
35 #include "maxchannels.h"
36 #include "mwindow.inc"
38 #include "pluginset.inc"
39 #include "pluginserver.inc"
41 #include "vwindowgui.inc"
43 // Options not in EDL but not changed in preferences
47 MainSession(MWindow *mwindow);
50 int load_defaults(BC_Hash *defaults);
51 int save_defaults(BC_Hash *defaults);
52 void save_x11_host(int play_config, const char *x11_host);
53 int set_default_x11_host(int win_config=-1);
54 void default_window_positions(int window_config=0);
56 Track *drag_handle_track();
57 void update_clip_number();
58 int load_file(const char *path);
59 int save_file(const char *path);
61 // For drag and drop events
62 // The entire track where the dropped asset is going to go
63 Track *track_highlighted;
64 // The edit after the point where the media is going to be dropped.
65 Edit *edit_highlighted;
66 // The plugin set where the plugin is going to be dropped.
67 PluginSet *pluginset_highlighted;
68 // The plugin after the point where the plugin is going to be dropped.
69 Plugin *plugin_highlighted;
70 // Current drag operation
71 int current_operation;
74 ArrayList <PluginServer*> *drag_pluginservers;
76 // When trim should only affect the selected edits or plugins
78 ArrayList<Indexable*> *drag_assets;
79 ArrayList<EDL*> *drag_clips;
81 ArrayList<Auto*> *drag_auto_gang;
83 // Edit whose handle is being dragged
85 // Edits who are being dragged
86 ArrayList<Edit*> *drag_edits;
87 // Button pressed during drag
89 // Handle being dragged
91 // Current position of drag cursor
93 // Starting position of drag cursor
95 // Cursor position when button was pressed
96 int drag_origin_x, drag_origin_y;
97 // Value of keyframe when button was pressed
98 float drag_start_percentage;
99 long drag_start_position;
100 // Amount of data rendered, for drawing status in timebar
102 // Position of cursor in CWindow output. Used by ruler.
103 int cwindow_output_x, cwindow_output_y;
105 // Show controls in CWindow
106 int cwindow_controls;
108 // Clip number for automatic title generation
114 // filename of the current project for window titling and saving
115 char filename[BCTEXTLEN];
117 int batchrender_x, batchrender_y, batchrender_w, batchrender_h;
121 char a_x11_host[BCSTRLEN], b_x11_host[BCSTRLEN];
123 int lwindow_x, lwindow_y, lwindow_w, lwindow_h;
125 int mwindow_x, mwindow_y, mwindow_w, mwindow_h;
127 int vwindow_x, vwindow_y, vwindow_w, vwindow_h;
129 int cwindow_x, cwindow_y, cwindow_w, cwindow_h;
130 int ctool_x, ctool_y;
132 int awindow_x, awindow_y, awindow_w, awindow_h;
133 int gwindow_x, gwindow_y;
135 int rmonitor_x, rmonitor_y, rmonitor_w, rmonitor_h;
137 int rwindow_x, rwindow_y, rwindow_w, rwindow_h;
139 int cswindow_x, cswindow_y, cswindow_w, cswindow_h;
141 int swindow_x, swindow_y, swindow_w, swindow_h;
142 // binfolder filter window
143 int bwindow_w, bwindow_h;
145 int ewindow_w, ewindow_h;
146 // Channel edit window
147 int channels_x, channels_y;
148 // Picture edit window
149 int picture_x, picture_y;
150 // Recording scope window
151 int scope_x, scope_y, scope_w, scope_h;
152 // Recording histogram window
153 int histogram_x, histogram_y, histogram_w, histogram_h;
154 // Recording scopes enabled
156 // Recording scope parameters
164 int show_vwindow, show_awindow, show_cwindow, show_gwindow, show_lwindow;
165 int plugindialog_w, plugindialog_h;
166 // int presetdialog_w, presetdialog_h;
167 int keyframedialog_w, keyframedialog_h;
168 int keyframedialog_column1;
169 int keyframedialog_column2;
170 int keyframedialog_all;
171 int menueffect_w, menueffect_h;
172 int transitiondialog_w, transitiondialog_h;
174 int cwindow_fullscreen;
175 int rwindow_fullscreen;
176 int vwindow_fullscreen;
177 int zwindow_fullscreen;
178 int selected_zwindow;
180 double actual_frame_rate;