Merge branch 'ct' of git.pipapo.org:cinelerra-ct into ct
[cinelerra_cv/ct.git] / cinelerra / vtransition.h
bloba0921c1ff121eb10c85aa26bce6a19ccf2a97219
1 #ifndef VTRACK_H
2 #define VTRACK_H
4 #include "arraylist.h"
5 #include "autoconf.inc"
6 #include "bezierauto.inc"
7 #include "bezierautos.inc"
8 #include "filexml.inc"
9 #include "floatautos.inc"
10 #include "linklist.h"
11 #include "mwindow.inc"
12 #include "track.h"
13 #include "vframe.inc"
15 // CONVERTS FROM SAMPLES TO FRAMES
19 class VTrack : public Track
21 public:
22 VTrack() {};
23 VTrack(MWindow *mwindow, Tracks *tracks);
24 ~VTrack();
26 // ====================================== initialization
27 int create_derived_objs(int flash);
29 int save_derived(FileXML *xml);
30 int load_derived(FileXML *xml, int automation_only, int edits_only, int load_all, int &output_channel);
32 // ===================================== rendering
34 int render(VFrame **output, long input_len, long input_position, float step);
35 int get_projection(float &in_x1, float &in_y1, float &in_x2, float &in_y2,
36 float &out_x1, float &out_y1, float &out_x2, float &out_y2,
37 int frame_w, int frame_h, long real_position,
38 BezierAuto **before, BezierAuto **after);
40 // ===================================== editing
42 int copy_derived(long start, long end, FileXML *xml);
43 int paste_derived(long start, long end, long total_length, FileXML *xml, int &current_channel);
44 // use samples for paste_output
45 int paste_output(long startproject, long endproject, long startsource, long endsource, int layer, Asset_GC asset);
46 int clear_derived(long start, long end);
47 int copy_automation_derived(AutoConf *auto_conf, long start, long end, FileXML *xml);
48 int paste_automation_derived(long start, long end, long total_length, FileXML *xml, int shift_autos, int &current_pan);
49 int clear_automation_derived(AutoConf *auto_conf, long start, long end, int shift_autos = 1);
50 int paste_auto_silence_derived(long start, long end);
51 int modify_handles(long oldposition, long newposition, int currentend);
52 int draw_autos_derived(float view_start, float zoom_units, AutoConf *auto_conf);
53 int draw_floating_autos_derived(float view_start, float zoom_units, AutoConf *auto_conf, int flash);
54 int select_translation(int cursor_x, int cursor_y); // select coordinates of frame
55 int update_translation(int cursor_x, int cursor_y, int shift_down); // move coordinates of frame
56 int reset_translation(long start, long end);
57 int end_translation();
58 int select_auto_derived(float zoom_units, float view_start, AutoConf *auto_conf, int cursor_x, int cursor_y);
59 int move_auto_derived(float zoom_units, float view_start, AutoConf *auto_conf, int cursor_x, int cursor_y, int shift_down);
60 int release_auto_derived();
61 int scale_video(float camera_scale, float projector_scale, int *offsets);
62 int scale_time_derived(float rate_scale, int scale_edits, int scale_autos, long start, long end);
64 // ===================================== for handles, titles, etc
66 BezierAutos *camera_autos;
67 BezierAutos *projector_autos;
68 long length();
69 // rounds up to integer frames for editing
70 long samples_to_units(long &samples);
71 // no rounding for drawing
72 int get_dimensions(float &view_start, float &view_units, float &zoom_units);
74 private:
77 #endif
79 // Local Variables:
80 // mode: C++
81 // c-file-style: "linux"
82 // End: