7 #include "mainprogress.inc"
8 #include "pluginaclient.h"
9 #include "resample.inc"
10 #include "timestretchengine.inc"
17 class TimeStretchWindow
;
18 class TimeStretchConfig
;
22 class TimeStretchScale
: public BC_FPot
25 TimeStretchScale(TimeStretch
*plugin
, int x
, int y
);
30 class TimeStretchWindow
: public BC_Window
33 TimeStretchWindow(TimeStretch
*plugin
, int x
, int y
);
34 void create_objects();
37 TimeStretchScale
*scale
;
41 PLUGIN_THREAD_HEADER(TimeStretch
, TimeStretchThread
, TimeStretchWindow
)
44 class TimeStretchConfig
50 int equivalent(TimeStretchConfig
&that
);
51 void copy_from(TimeStretchConfig
&that
);
52 void interpolate(TimeStretchConfig
&prev
,
53 TimeStretchConfig
&next
,
56 int64_t current_frame
);
63 class PitchEngine
: public CrossfadeFFT
66 PitchEngine(TimeStretch
*plugin
);
70 int read_samples(int64_t output_sample
,
73 int signal_process_oversample(int reset
);
80 int64_t current_input_sample
;
81 int64_t current_output_sample
;
93 class TimeStretch
: public PluginAClient
96 TimeStretch(PluginServer
*server
);
101 char* plugin_title();
103 int get_parameters();
104 void read_data(KeyFrame
*keyframe
);
105 void save_data(KeyFrame
*keyframe
);
107 int process_buffer(int64_t size
,
109 int64_t start_position
,
118 int load_configuration();
133 TimeStretchEngine
*stretch
;
136 TimeStretchConfig config
;
137 TimeStretchThread
*thread
;