current_value = 1.0;
}
-const char* CompressorEffect::plugin_title() { return _("Compressor"); }
+const char* CompressorEffect::plugin_title() { return N_("Compressor"); }
int CompressorEffect::is_realtime() { return 1; }
int CompressorEffect::is_multichannel() { return 1; }
void CompressorEffect::read_data(KeyFrame *keyframe)
{
FileXML input;
- input.set_shared_input(keyframe->get_data(), strlen(keyframe->get_data()));
+ input.set_shared_input(keyframe->xbuf);
int result = 0;
config.levels.remove_all();
void CompressorEffect::save_data(KeyFrame *keyframe)
{
FileXML output;
- output.set_shared_output(keyframe->get_data(), MESSAGESIZE);
+ output.set_shared_output(keyframe->xbuf);
output.tag.set_title("COMPRESSOR");
output.tag.set_property("TRIGGER", config.trigger);
void CompressorEffect::update_gui()
{
- if(thread)
- {
- if(load_configuration())
- {
- thread->window->lock_window("CompressorEffect::update_gui");
- ((CompressorWindow*)thread->window)->update();
- thread->window->unlock_window();
- }
- }
+ if( !thread ) return;
+ CompressorWindow *window = (CompressorWindow*)thread->window;
+// load_configuration,read_data deletes levels
+ window->lock_window("CompressorEffect::update_gui");
+ if( load_configuration() )
+ window->update();
+ window->unlock_window();
}
{
this->plugin = plugin;
current_operation = NONE;
+ current_point = 0;
}
int CompressorCanvas::button_press_event()