/*
* CINELERRA
* Copyright (C) 1997-2011 Adam Williams <broadcast at earthling dot net>
- *
+ *
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
- *
+ *
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
- *
+ *
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- *
+ *
*/
#include "bcdisplayinfo.h"
CLAMP(cutoff, MIN_CUTOFF, MAX_CUTOFF);
}
-void EchoCancelConfig::interpolate(EchoCancelConfig &prev,
- EchoCancelConfig &next,
- int64_t prev_frame,
- int64_t next_frame,
+void EchoCancelConfig::interpolate(EchoCancelConfig &prev,
+ EchoCancelConfig &next,
+ int64_t prev_frame,
+ int64_t next_frame,
int64_t current_frame)
{
copy_from(prev);
EchoCancelHistory::EchoCancelHistory(EchoCancel *plugin,
- int x,
+ int x,
int y)
: BC_IPot(x, y, plugin->config.history_size, MIN_HISTORY, MAX_HISTORY)
{
int y = get_cursor_y();
CLAMP(x, 0, get_w() - 1);
CLAMP(y, 0, get_h() - 1);
-
+
EchoCancelWindow *window = (EchoCancelWindow *)plugin->thread->window;
window->calculate_frequency(x, y, do_overlay);
}
void EchoCancelWindow::create_objects()
{
int pad = plugin->get_theme()->widget_border;
- add_subwindow(canvas = new EchoCancelCanvas(plugin, 0, 0,
+ add_subwindow(canvas = new EchoCancelCanvas(plugin, 0, 0,
get_w(), get_h() - 2*BC_Pot::calculate_h() - 3*pad));
canvas->set_cursor(CROSS_CURSOR, 0, 0);
x = x1;
add_subwindow(normalize = new EchoCancelNormalize(plugin, x, y));
x += normalize->get_w() + 3*pad;
- y += normalize->get_h() - BC_Title::calculate_h(this,"Gain: ");
+ y += normalize->get_h() - BC_Title::calculate_h(this,_("Gain: "));
add_subwindow(gain_title = new EchoCancelTitle(x, y, _("Gain: "), 0.));
x += gain_title->get_w() + 2*pad;
add_subwindow(offset_title = new EchoCancelTitle(x, y, _("Offset: "), 0));
add_subwindow(window_size = new EchoCancelWindowSize(plugin, x, y, wsp));
x += window_size->get_w();
add_subwindow(window_size_tumbler = new EchoCancelWindowSizeTumbler(plugin, x, y));
-
+
window_size->add_item(new BC_MenuItem(EchoCancelWindowSize::to_text(0)));
for( int i=MIN_WINDOW; i<=MAX_WINDOW; i*=2 ) {
window_size->add_item(new BC_MenuItem(EchoCancelWindowSize::to_text(i)));
y = y1;
add_subwindow(freq_title = new BC_Title(x, y, _("0 Hz")));
y += freq_title->get_h() + pad;
- add_subwindow(amplitude_title = new BC_Title(x, y, "Amplitude: 0 dB"));
+ add_subwindow(amplitude_title = new BC_Title(x, y, _("Amplitude: 0 dB")));
show_window();
}
int freq = plugin->header.sample_rate / offset;
int msecs = 1000. / freq;
char string[BCTEXTLEN];
- sprintf(string, "%d Hz, %d ms (%d))", freq, msecs, (int)offset);
+ sprintf(string, _("%d Hz, %d ms (%d))"), freq, msecs, (int)offset);
freq_title->update(string);
int frm_sz1 = frm->size()-1;
if( freq_pixel > frm_sz1 ) freq_pixel = frm_sz1;
float *frame_data = frm->samples();
double level = frame_data[freq_pixel];
double scale = frm->scale();
- sprintf(string, "Amplitude: %.3f (%.6g)", level, scale);
+ sprintf(string, _("Amplitude: %.3f (%.6g)"), level, scale);
amplitude_title->update(string);
}
if( y >= 0 ) {