Remove all use of nframes_t.
git-svn-id: svn://localhost/ardour2/branches/3.0@8166 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
74b4a3c77b
commit
73192bc1a7
|
@ -278,9 +278,9 @@ AnalysisWindow::analyze_data (Gtk::Button */*button*/)
|
|||
|
||||
int n;
|
||||
for (int channel = 0; channel < n_inputs; channel++) {
|
||||
nframes_t x = 0;
|
||||
framecnt_t x = 0;
|
||||
|
||||
while ( x < (*j).length() ) {
|
||||
while (x < j->length()) {
|
||||
// TODO: What about stereo+ channels? composite all to one, I guess
|
||||
|
||||
n = fft_graph.windowSize();
|
||||
|
@ -322,11 +322,11 @@ AnalysisWindow::analyze_data (Gtk::Button */*button*/)
|
|||
int n;
|
||||
for (int channel = 0; channel < n_inputs; channel++) {
|
||||
|
||||
nframes_t x = 0;
|
||||
framecnt_t x = 0;
|
||||
|
||||
nframes_t length = arv->region()->length();
|
||||
framecnt_t length = arv->region()->length();
|
||||
|
||||
while ( x < length ) {
|
||||
while (x < length) {
|
||||
// TODO: What about stereo+ channels? composite all to one, I guess
|
||||
|
||||
n = fft_graph.windowSize();
|
||||
|
|
|
@ -121,7 +121,7 @@ UIConfiguration *ARDOUR_UI::ui_config = 0;
|
|||
sigc::signal<void,bool> ARDOUR_UI::Blink;
|
||||
sigc::signal<void> ARDOUR_UI::RapidScreenUpdate;
|
||||
sigc::signal<void> ARDOUR_UI::SuperRapidScreenUpdate;
|
||||
sigc::signal<void,nframes_t, bool, nframes_t> ARDOUR_UI::Clock;
|
||||
sigc::signal<void, framepos_t, bool, framepos_t> ARDOUR_UI::Clock;
|
||||
|
||||
bool could_be_a_valid_path (const string& path);
|
||||
|
||||
|
@ -952,7 +952,7 @@ ARDOUR_UI::every_point_zero_one_seconds ()
|
|||
}
|
||||
|
||||
void
|
||||
ARDOUR_UI::update_sample_rate (nframes_t)
|
||||
ARDOUR_UI::update_sample_rate (framecnt_t)
|
||||
{
|
||||
char buf[32];
|
||||
|
||||
|
@ -964,7 +964,7 @@ ARDOUR_UI::update_sample_rate (nframes_t)
|
|||
|
||||
} else {
|
||||
|
||||
nframes_t rate = engine->frame_rate();
|
||||
framecnt_t rate = engine->frame_rate();
|
||||
|
||||
if (fmod (rate, 1000.0) != 0.0) {
|
||||
snprintf (buf, sizeof (buf), _("%.1f kHz / %4.1f ms"),
|
||||
|
@ -1024,7 +1024,7 @@ ARDOUR_UI::update_disk_space()
|
|||
|
||||
framecnt_t frames = _session->available_capture_duration();
|
||||
char buf[64];
|
||||
nframes_t fr = _session->frame_rate();
|
||||
framecnt_t fr = _session->frame_rate();
|
||||
|
||||
if (frames == max_framecnt) {
|
||||
strcpy (buf, _("Disk: 24hrs+"));
|
||||
|
@ -1415,9 +1415,9 @@ restart JACK with more ports."), PROGRAM_NAME));
|
|||
}
|
||||
|
||||
void
|
||||
ARDOUR_UI::do_transport_locate (nframes_t new_position, bool with_roll)
|
||||
ARDOUR_UI::do_transport_locate (framepos_t new_position, bool with_roll)
|
||||
{
|
||||
nframes_t _preroll = 0;
|
||||
framecnt_t _preroll = 0;
|
||||
|
||||
if (_session) {
|
||||
// XXX CONFIG_CHANGE FIX - requires AnyTime handling
|
||||
|
@ -1497,7 +1497,7 @@ void
|
|||
ARDOUR_UI::transport_goto_end ()
|
||||
{
|
||||
if (_session) {
|
||||
nframes_t const frame = _session->current_end_frame();
|
||||
framepos_t const frame = _session->current_end_frame();
|
||||
_session->request_locate (frame);
|
||||
|
||||
/* force displayed area in editor to start no matter
|
||||
|
@ -3257,7 +3257,7 @@ ARDOUR_UI::keyboard_settings () const
|
|||
}
|
||||
|
||||
void
|
||||
ARDOUR_UI::create_xrun_marker(nframes_t where)
|
||||
ARDOUR_UI::create_xrun_marker (framepos_t where)
|
||||
{
|
||||
editor->mouse_add_new_marker (where, false, true);
|
||||
}
|
||||
|
@ -3271,7 +3271,7 @@ ARDOUR_UI::halt_on_xrun_message ()
|
|||
}
|
||||
|
||||
void
|
||||
ARDOUR_UI::xrun_handler(nframes_t where)
|
||||
ARDOUR_UI::xrun_handler (framepos_t where)
|
||||
{
|
||||
if (!_session) {
|
||||
return;
|
||||
|
@ -3384,7 +3384,7 @@ what you would like to do.\n"));
|
|||
}
|
||||
|
||||
int
|
||||
ARDOUR_UI::sr_mismatch_dialog (nframes_t desired, nframes_t actual)
|
||||
ARDOUR_UI::sr_mismatch_dialog (framecnt_t desired, framecnt_t actual)
|
||||
{
|
||||
HBox* hbox = new HBox();
|
||||
Image* image = new Image (Stock::DIALOG_QUESTION, ICON_SIZE_DIALOG);
|
||||
|
@ -3451,7 +3451,7 @@ ARDOUR_UI::use_config ()
|
|||
}
|
||||
|
||||
void
|
||||
ARDOUR_UI::update_transport_clocks (nframes_t pos)
|
||||
ARDOUR_UI::update_transport_clocks (framepos_t pos)
|
||||
{
|
||||
if (Config->get_primary_clock_delta_edit_cursor()) {
|
||||
primary_clock.set (pos, false, editor->get_preferred_edit_position(), 1);
|
||||
|
|
|
@ -174,7 +174,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI, public ARDOUR::SessionHandlePtr
|
|||
static sigc::signal<void,bool> Blink;
|
||||
static sigc::signal<void> RapidScreenUpdate;
|
||||
static sigc::signal<void> SuperRapidScreenUpdate;
|
||||
static sigc::signal<void,nframes_t, bool, nframes_t> Clock;
|
||||
static sigc::signal<void, framepos_t, bool, framepos_t> Clock;
|
||||
|
||||
XMLNode* editor_settings() const;
|
||||
XMLNode* mixer_settings () const;
|
||||
|
@ -184,10 +184,10 @@ class ARDOUR_UI : public Gtkmm2ext::UI, public ARDOUR::SessionHandlePtr
|
|||
void save_ardour_state ();
|
||||
gboolean configure_handler (GdkEventConfigure* conf);
|
||||
|
||||
void do_transport_locate (nframes_t, bool);
|
||||
void do_transport_locate (framepos_t, bool);
|
||||
void halt_on_xrun_message ();
|
||||
void xrun_handler (nframes_t);
|
||||
void create_xrun_marker (nframes_t);
|
||||
void xrun_handler (framepos_t);
|
||||
void create_xrun_marker (framepos_t);
|
||||
|
||||
AudioClock primary_clock;
|
||||
AudioClock secondary_clock;
|
||||
|
@ -328,7 +328,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI, public ARDOUR::SessionHandlePtr
|
|||
void float_big_clock (Gtk::Window* parent);
|
||||
bool main_window_state_event_handler (GdkEventWindowState*, bool window_was_editor);
|
||||
|
||||
void update_transport_clocks (nframes_t pos);
|
||||
void update_transport_clocks (framepos_t pos);
|
||||
void record_state_changed ();
|
||||
|
||||
std::list<MidiTracer*> _midi_tracer_windows;
|
||||
|
@ -523,7 +523,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI, public ARDOUR::SessionHandlePtr
|
|||
|
||||
Gtk::Label sample_rate_label;
|
||||
Gtk::EventBox sample_rate_box;
|
||||
void update_sample_rate (nframes_t);
|
||||
void update_sample_rate (ARDOUR::framecnt_t);
|
||||
|
||||
gint every_second ();
|
||||
gint every_point_one_seconds ();
|
||||
|
@ -659,11 +659,11 @@ class ARDOUR_UI : public Gtkmm2ext::UI, public ARDOUR::SessionHandlePtr
|
|||
|
||||
void session_dialog (std::string);
|
||||
int pending_state_dialog ();
|
||||
int sr_mismatch_dialog (nframes_t, nframes_t);
|
||||
int sr_mismatch_dialog (ARDOUR::framecnt_t, ARDOUR::framecnt_t);
|
||||
|
||||
void disconnect_from_jack ();
|
||||
void reconnect_to_jack ();
|
||||
void set_jack_buffer_size (nframes_t);
|
||||
void set_jack_buffer_size (ARDOUR::pframes_t);
|
||||
|
||||
Gtk::MenuItem* jack_disconnect_item;
|
||||
Gtk::MenuItem* jack_reconnect_item;
|
||||
|
|
|
@ -187,23 +187,23 @@ ARDOUR_UI::install_actions ()
|
|||
|
||||
RadioAction::Group jack_latency_group;
|
||||
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency32"), X_("32"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 32));
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency32"), X_("32"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (pframes_t) 32));
|
||||
ActionManager::jack_sensitive_actions.push_back (act);
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency64"), X_("64"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 64));
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency64"), X_("64"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (pframes_t) 64));
|
||||
ActionManager::jack_sensitive_actions.push_back (act);
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency128"), X_("128"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 128));
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency128"), X_("128"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (pframes_t) 128));
|
||||
ActionManager::jack_sensitive_actions.push_back (act);
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency256"), X_("256"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 256));
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency256"), X_("256"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (pframes_t) 256));
|
||||
ActionManager::jack_sensitive_actions.push_back (act);
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency512"), X_("512"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 512));
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency512"), X_("512"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (pframes_t) 512));
|
||||
ActionManager::jack_sensitive_actions.push_back (act);
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency1024"), X_("1024"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 1024));
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency1024"), X_("1024"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (pframes_t) 1024));
|
||||
ActionManager::jack_sensitive_actions.push_back (act);
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency2048"), X_("2048"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 2048));
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency2048"), X_("2048"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (pframes_t) 2048));
|
||||
ActionManager::jack_sensitive_actions.push_back (act);
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency4096"), X_("4096"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 4096));
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency4096"), X_("4096"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (pframes_t) 4096));
|
||||
ActionManager::jack_sensitive_actions.push_back (act);
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency8192"), X_("8192"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 8192));
|
||||
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency8192"), X_("8192"), sigc::bind (sigc::mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (pframes_t) 8192));
|
||||
ActionManager::jack_sensitive_actions.push_back (act);
|
||||
|
||||
/* these actions are intended to be shared across all windows */
|
||||
|
@ -441,7 +441,7 @@ ARDOUR_UI::install_actions ()
|
|||
}
|
||||
|
||||
void
|
||||
ARDOUR_UI::set_jack_buffer_size (nframes_t nframes)
|
||||
ARDOUR_UI::set_jack_buffer_size (pframes_t nframes)
|
||||
{
|
||||
Glib::RefPtr<Action> action;
|
||||
const char* action_name = 0;
|
||||
|
|
|
@ -414,7 +414,7 @@ AudioClock::on_realize ()
|
|||
}
|
||||
|
||||
void
|
||||
AudioClock::set (nframes_t when, bool force, nframes_t offset, char which)
|
||||
AudioClock::set (framepos_t when, bool force, framecnt_t offset, char which)
|
||||
{
|
||||
|
||||
if ((!force && !is_visible()) || _session == 0) {
|
||||
|
@ -479,12 +479,12 @@ AudioClock::session_configuration_changed (std::string p)
|
|||
return;
|
||||
}
|
||||
|
||||
nframes_t current;
|
||||
framecnt_t current;
|
||||
|
||||
switch (_mode) {
|
||||
case Timecode:
|
||||
if (is_duration) {
|
||||
current = current_duration();
|
||||
current = current_duration ();
|
||||
} else {
|
||||
current = current_time ();
|
||||
}
|
||||
|
@ -496,17 +496,17 @@ AudioClock::session_configuration_changed (std::string p)
|
|||
}
|
||||
|
||||
void
|
||||
AudioClock::set_frames (nframes_t when, bool /*force*/)
|
||||
AudioClock::set_frames (framepos_t when, bool /*force*/)
|
||||
{
|
||||
char buf[32];
|
||||
snprintf (buf, sizeof (buf), "%u", when);
|
||||
snprintf (buf, sizeof (buf), "%" PRId64, when);
|
||||
audio_frames_label.set_text (buf);
|
||||
|
||||
if (frames_upper_info_label) {
|
||||
nframes_t rate = _session->frame_rate();
|
||||
framecnt_t rate = _session->frame_rate();
|
||||
|
||||
if (fmod (rate, 1000.0) == 0.000) {
|
||||
sprintf (buf, "%uK", rate/1000);
|
||||
sprintf (buf, "%" PRId64 "K", rate/1000);
|
||||
} else {
|
||||
sprintf (buf, "%.3fK", rate/1000.0f);
|
||||
}
|
||||
|
@ -531,19 +531,19 @@ AudioClock::set_frames (nframes_t when, bool /*force*/)
|
|||
}
|
||||
|
||||
void
|
||||
AudioClock::set_minsec (nframes_t when, bool force)
|
||||
AudioClock::set_minsec (framepos_t when, bool force)
|
||||
{
|
||||
char buf[32];
|
||||
nframes_t left;
|
||||
framecnt_t left;
|
||||
int hrs;
|
||||
int mins;
|
||||
float secs;
|
||||
|
||||
left = when;
|
||||
hrs = (int) floor (left / (_session->frame_rate() * 60.0f * 60.0f));
|
||||
left -= (nframes_t) floor (hrs * _session->frame_rate() * 60.0f * 60.0f);
|
||||
left -= (framecnt_t) floor (hrs * _session->frame_rate() * 60.0f * 60.0f);
|
||||
mins = (int) floor (left / (_session->frame_rate() * 60.0f));
|
||||
left -= (nframes_t) floor (mins * _session->frame_rate() * 60.0f);
|
||||
left -= (framecnt_t) floor (mins * _session->frame_rate() * 60.0f);
|
||||
secs = left / (float) _session->frame_rate();
|
||||
|
||||
if (force || hrs != ms_last_hrs) {
|
||||
|
@ -566,7 +566,7 @@ AudioClock::set_minsec (nframes_t when, bool force)
|
|||
}
|
||||
|
||||
void
|
||||
AudioClock::set_timecode (nframes_t when, bool force)
|
||||
AudioClock::set_timecode (framepos_t when, bool force)
|
||||
{
|
||||
char buf[32];
|
||||
Timecode::Time timecode;
|
||||
|
@ -637,7 +637,7 @@ AudioClock::set_timecode (nframes_t when, bool force)
|
|||
}
|
||||
|
||||
void
|
||||
AudioClock::set_bbt (nframes_t when, bool force)
|
||||
AudioClock::set_bbt (framepos_t when, bool force)
|
||||
{
|
||||
char buf[16];
|
||||
BBT_Time bbt;
|
||||
|
@ -1198,7 +1198,7 @@ AudioClock::field_button_press_event (GdkEventButton *ev, Field /*field*/)
|
|||
return false;
|
||||
}
|
||||
|
||||
nframes_t frames = 0;
|
||||
framepos_t frames = 0;
|
||||
|
||||
switch (ev->button) {
|
||||
case 1:
|
||||
|
@ -1244,7 +1244,7 @@ AudioClock::field_button_scroll_event (GdkEventScroll *ev, Field field)
|
|||
return false;
|
||||
}
|
||||
|
||||
nframes_t frames = 0;
|
||||
framepos_t frames = 0;
|
||||
|
||||
switch (ev->direction) {
|
||||
|
||||
|
@ -1313,8 +1313,8 @@ AudioClock::field_motion_notify_event (GdkEventMotion *ev, Field field)
|
|||
|
||||
if (trunc(drag_accum) != 0) {
|
||||
|
||||
nframes_t frames;
|
||||
nframes_t pos ;
|
||||
framepos_t frames;
|
||||
framepos_t pos;
|
||||
int dir;
|
||||
dir = (drag_accum < 0 ? 1:-1);
|
||||
pos = current_time();
|
||||
|
@ -1322,7 +1322,7 @@ AudioClock::field_motion_notify_event (GdkEventMotion *ev, Field field)
|
|||
|
||||
if (frames != 0 && frames * drag_accum < current_time()) {
|
||||
|
||||
set ((nframes_t) floor (pos - drag_accum * frames), false); // minus because up is negative in computer-land
|
||||
set ((framepos_t) floor (pos - drag_accum * frames), false); // minus because up is negative in computer-land
|
||||
|
||||
} else {
|
||||
set (0 , false);
|
||||
|
@ -1338,24 +1338,23 @@ AudioClock::field_motion_notify_event (GdkEventMotion *ev, Field field)
|
|||
return true;
|
||||
}
|
||||
|
||||
nframes_t
|
||||
AudioClock::get_frames (Field field,nframes_t pos,int dir)
|
||||
framepos_t
|
||||
AudioClock::get_frames (Field field, framepos_t pos, int dir)
|
||||
{
|
||||
|
||||
nframes_t frames = 0;
|
||||
framecnt_t frames = 0;
|
||||
BBT_Time bbt;
|
||||
switch (field) {
|
||||
case Timecode_Hours:
|
||||
frames = (nframes_t) floor (3600.0 * _session->frame_rate());
|
||||
frames = (framecnt_t) floor (3600.0 * _session->frame_rate());
|
||||
break;
|
||||
case Timecode_Minutes:
|
||||
frames = (nframes_t) floor (60.0 * _session->frame_rate());
|
||||
frames = (framecnt_t) floor (60.0 * _session->frame_rate());
|
||||
break;
|
||||
case Timecode_Seconds:
|
||||
frames = _session->frame_rate();
|
||||
break;
|
||||
case Timecode_Frames:
|
||||
frames = (nframes_t) floor (_session->frame_rate() / _session->timecode_frames_per_second());
|
||||
frames = (framecnt_t) floor (_session->frame_rate() / _session->timecode_frames_per_second());
|
||||
break;
|
||||
|
||||
case AudioFrames:
|
||||
|
@ -1363,10 +1362,10 @@ AudioClock::get_frames (Field field,nframes_t pos,int dir)
|
|||
break;
|
||||
|
||||
case MS_Hours:
|
||||
frames = (nframes_t) floor (3600.0 * _session->frame_rate());
|
||||
frames = (framecnt_t) floor (3600.0 * _session->frame_rate());
|
||||
break;
|
||||
case MS_Minutes:
|
||||
frames = (nframes_t) floor (60.0 * _session->frame_rate());
|
||||
frames = (framecnt_t) floor (60.0 * _session->frame_rate());
|
||||
break;
|
||||
case MS_Seconds:
|
||||
frames = _session->frame_rate();
|
||||
|
@ -1395,10 +1394,10 @@ AudioClock::get_frames (Field field,nframes_t pos,int dir)
|
|||
return frames;
|
||||
}
|
||||
|
||||
nframes_t
|
||||
AudioClock::current_time (nframes_t pos) const
|
||||
framepos_t
|
||||
AudioClock::current_time (framepos_t pos) const
|
||||
{
|
||||
nframes_t ret = 0;
|
||||
framepos_t ret = 0;
|
||||
|
||||
switch (_mode) {
|
||||
case Timecode:
|
||||
|
@ -1423,10 +1422,10 @@ AudioClock::current_time (nframes_t pos) const
|
|||
return ret;
|
||||
}
|
||||
|
||||
nframes_t
|
||||
AudioClock::current_duration (nframes_t pos) const
|
||||
framepos_t
|
||||
AudioClock::current_duration (framepos_t pos) const
|
||||
{
|
||||
nframes_t ret = 0;
|
||||
framepos_t ret = 0;
|
||||
|
||||
switch (_mode) {
|
||||
case Timecode:
|
||||
|
@ -1490,7 +1489,7 @@ AudioClock::timecode_sanitize_display()
|
|||
}
|
||||
}
|
||||
|
||||
nframes_t
|
||||
framepos_t
|
||||
AudioClock::timecode_frame_from_display () const
|
||||
{
|
||||
if (_session == 0) {
|
||||
|
@ -1883,7 +1882,7 @@ AudioClock::timecode_frame_from_display () const
|
|||
return sample;
|
||||
}
|
||||
|
||||
nframes_t
|
||||
framepos_t
|
||||
AudioClock::minsec_frame_from_display () const
|
||||
{
|
||||
if (_session == 0) {
|
||||
|
@ -1894,13 +1893,13 @@ AudioClock::minsec_frame_from_display () const
|
|||
int mins = atoi (ms_minutes_label.get_text());
|
||||
float secs = atof (ms_seconds_label.get_text());
|
||||
|
||||
nframes_t sr = _session->frame_rate();
|
||||
framecnt_t sr = _session->frame_rate();
|
||||
|
||||
return (nframes_t) floor ((hrs * 60.0f * 60.0f * sr) + (mins * 60.0f * sr) + (secs * sr));
|
||||
return (framepos_t) floor ((hrs * 60.0f * 60.0f * sr) + (mins * 60.0f * sr) + (secs * sr));
|
||||
}
|
||||
|
||||
nframes_t
|
||||
AudioClock::bbt_frame_from_display (nframes_t pos) const
|
||||
framepos_t
|
||||
AudioClock::bbt_frame_from_display (framepos_t pos) const
|
||||
{
|
||||
if (_session == 0) {
|
||||
error << "AudioClock::current_time() called with BBT mode but without session!" << endmsg;
|
||||
|
@ -1919,14 +1918,12 @@ AudioClock::bbt_frame_from_display (nframes_t pos) const
|
|||
any.bbt.beats++;
|
||||
}
|
||||
|
||||
nframes_t ret = _session->convert_to_frames_at (pos, any);
|
||||
|
||||
return ret;
|
||||
return _session->convert_to_frames_at (pos, any);
|
||||
}
|
||||
|
||||
|
||||
nframes_t
|
||||
AudioClock::bbt_frame_duration_from_display (nframes_t pos) const
|
||||
framepos_t
|
||||
AudioClock::bbt_frame_duration_from_display (framepos_t pos) const
|
||||
{
|
||||
if (_session == 0) {
|
||||
error << "AudioClock::current_time() called with BBT mode but without session!" << endmsg;
|
||||
|
@ -1943,10 +1940,10 @@ AudioClock::bbt_frame_duration_from_display (nframes_t pos) const
|
|||
return _session->tempo_map().bbt_duration_at(pos,bbt,1);
|
||||
}
|
||||
|
||||
nframes_t
|
||||
framepos_t
|
||||
AudioClock::audio_frame_from_display () const
|
||||
{
|
||||
return (nframes_t) atoi (audio_frames_label.get_text());
|
||||
return (framepos_t) atoi (audio_frames_label.get_text());
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
@ -50,7 +50,7 @@ class AudioClock : public Gtk::HBox, public ARDOUR::SessionHandlePtr
|
|||
|
||||
void focus ();
|
||||
|
||||
void set (nframes_t, bool force = false, nframes_t offset = 0, char which = 0);
|
||||
void set (framepos_t, bool force = false, ARDOUR::framecnt_t offset = 0, char which = 0);
|
||||
void set_from_playhead ();
|
||||
void locate ();
|
||||
void set_mode (Mode);
|
||||
|
@ -61,8 +61,8 @@ class AudioClock : public Gtk::HBox, public ARDOUR::SessionHandlePtr
|
|||
|
||||
std::string name() const { return _name; }
|
||||
|
||||
nframes_t current_time (nframes_t position = 0) const;
|
||||
nframes_t current_duration (nframes_t position = 0) const;
|
||||
framepos_t current_time (framepos_t position = 0) const;
|
||||
framepos_t current_duration (framepos_t position = 0) const;
|
||||
void set_session (ARDOUR::Session *s);
|
||||
|
||||
sigc::signal<void> ValueChanged;
|
||||
|
@ -164,7 +164,7 @@ class AudioClock : public Gtk::HBox, public ARDOUR::SessionHandlePtr
|
|||
Gtk::Frame clock_frame;
|
||||
|
||||
framepos_t bbt_reference_time;
|
||||
nframes_t last_when;
|
||||
framepos_t last_when;
|
||||
bool last_pdelta;
|
||||
bool last_sdelta;
|
||||
|
||||
|
@ -195,19 +195,19 @@ class AudioClock : public Gtk::HBox, public ARDOUR::SessionHandlePtr
|
|||
bool field_focus_out_event (GdkEventFocus *, Field);
|
||||
bool drop_focus_handler (GdkEventFocus*);
|
||||
|
||||
void set_timecode (nframes_t, bool);
|
||||
void set_bbt (nframes_t, bool);
|
||||
void set_minsec (nframes_t, bool);
|
||||
void set_frames (nframes_t, bool);
|
||||
void set_timecode (framepos_t, bool);
|
||||
void set_bbt (framepos_t, bool);
|
||||
void set_minsec (framepos_t, bool);
|
||||
void set_frames (framepos_t, bool);
|
||||
|
||||
nframes_t get_frames (Field,nframes_t pos = 0,int dir=1);
|
||||
framepos_t get_frames (Field, framepos_t pos = 0, int dir = 1);
|
||||
|
||||
void timecode_sanitize_display();
|
||||
nframes_t timecode_frame_from_display () const;
|
||||
nframes_t bbt_frame_from_display (nframes_t) const;
|
||||
nframes_t bbt_frame_duration_from_display (nframes_t) const;
|
||||
nframes_t minsec_frame_from_display () const;
|
||||
nframes_t audio_frame_from_display () const;
|
||||
framepos_t timecode_frame_from_display () const;
|
||||
framepos_t bbt_frame_from_display (framepos_t) const;
|
||||
framepos_t bbt_frame_duration_from_display (framepos_t) const;
|
||||
framepos_t minsec_frame_from_display () const;
|
||||
framepos_t audio_frame_from_display () const;
|
||||
|
||||
void build_ops_menu ();
|
||||
void setup_events ();
|
||||
|
|
|
@ -573,11 +573,11 @@ AudioRegionView::reset_fade_shapes ()
|
|||
void
|
||||
AudioRegionView::reset_fade_in_shape ()
|
||||
{
|
||||
reset_fade_in_shape_width ((nframes_t) audio_region()->fade_in()->back()->when);
|
||||
reset_fade_in_shape_width ((framecnt_t) audio_region()->fade_in()->back()->when);
|
||||
}
|
||||
|
||||
void
|
||||
AudioRegionView::reset_fade_in_shape_width (nframes_t width)
|
||||
AudioRegionView::reset_fade_in_shape_width (framecnt_t width)
|
||||
{
|
||||
if (fade_in_handle == 0) {
|
||||
return;
|
||||
|
@ -585,7 +585,7 @@ AudioRegionView::reset_fade_in_shape_width (nframes_t width)
|
|||
|
||||
/* smallest size for a fade is 64 frames */
|
||||
|
||||
width = std::max ((nframes_t) 64, width);
|
||||
width = std::max ((framecnt_t) 64, width);
|
||||
|
||||
Points* points;
|
||||
|
||||
|
@ -665,11 +665,11 @@ AudioRegionView::reset_fade_in_shape_width (nframes_t width)
|
|||
void
|
||||
AudioRegionView::reset_fade_out_shape ()
|
||||
{
|
||||
reset_fade_out_shape_width ((nframes_t) audio_region()->fade_out()->back()->when);
|
||||
reset_fade_out_shape_width ((framecnt_t) audio_region()->fade_out()->back()->when);
|
||||
}
|
||||
|
||||
void
|
||||
AudioRegionView::reset_fade_out_shape_width (nframes_t width)
|
||||
AudioRegionView::reset_fade_out_shape_width (framecnt_t width)
|
||||
{
|
||||
if (fade_out_handle == 0) {
|
||||
return;
|
||||
|
@ -677,7 +677,7 @@ AudioRegionView::reset_fade_out_shape_width (nframes_t width)
|
|||
|
||||
/* smallest size for a fade is 64 frames */
|
||||
|
||||
width = std::max ((nframes_t) 64, width);
|
||||
width = std::max ((framecnt_t) 64, width);
|
||||
|
||||
Points* points;
|
||||
double pwidth = width / samples_per_unit;
|
||||
|
@ -1043,7 +1043,7 @@ AudioRegionView::add_gain_point_event (ArdourCanvas::Item *item, GdkEvent *ev)
|
|||
|
||||
item->w2i (x, y);
|
||||
|
||||
nframes_t fx = trackview.editor().pixel_to_frame (x);
|
||||
framepos_t fx = trackview.editor().pixel_to_frame (x);
|
||||
|
||||
if (fx > _region->length()) {
|
||||
return;
|
||||
|
|
|
@ -100,8 +100,8 @@ class AudioRegionView : public RegionView
|
|||
|
||||
GhostRegion* add_ghost (TimeAxisView&);
|
||||
|
||||
void reset_fade_in_shape_width (nframes_t);
|
||||
void reset_fade_out_shape_width (nframes_t);
|
||||
void reset_fade_in_shape_width (framecnt_t);
|
||||
void reset_fade_out_shape_width (framecnt_t);
|
||||
|
||||
void show_fade_line(framepos_t pos);
|
||||
void hide_fade_line();
|
||||
|
|
|
@ -471,7 +471,7 @@ AudioStreamView::setup_rec_box ()
|
|||
|
||||
// handle multi
|
||||
|
||||
nframes_t start = 0;
|
||||
framepos_t start = 0;
|
||||
if (rec_regions.size() > 0) {
|
||||
start = rec_regions.back().first->start()
|
||||
+ _trackview.track()->get_captured_frames(rec_regions.size()-1);
|
||||
|
@ -600,7 +600,7 @@ AudioStreamView::foreach_crossfadeview (void (CrossfadeView::*pmf)(void))
|
|||
}
|
||||
|
||||
void
|
||||
AudioStreamView::rec_peak_range_ready (nframes_t start, nframes_t cnt, boost::weak_ptr<Source> weak_src)
|
||||
AudioStreamView::rec_peak_range_ready (framepos_t start, framecnt_t cnt, boost::weak_ptr<Source> weak_src)
|
||||
{
|
||||
ENSURE_GUI_THREAD (*this, &AudioStreamView::rec_peak_range_ready, start, cnt, weak_src)
|
||||
|
||||
|
@ -653,13 +653,13 @@ AudioStreamView::update_rec_regions (framepos_t start, framecnt_t cnt)
|
|||
continue;
|
||||
}
|
||||
|
||||
nframes_t origlen = region->length();
|
||||
framecnt_t origlen = region->length();
|
||||
|
||||
if (region == rec_regions.back().first && rec_active) {
|
||||
|
||||
if (last_rec_data_frame > region->start()) {
|
||||
|
||||
nframes_t nlen = last_rec_data_frame - region->start();
|
||||
framecnt_t nlen = last_rec_data_frame - region->start();
|
||||
|
||||
if (nlen != region->length()) {
|
||||
|
||||
|
@ -684,7 +684,7 @@ AudioStreamView::update_rec_regions (framepos_t start, framecnt_t cnt)
|
|||
|
||||
} else {
|
||||
|
||||
nframes_t nlen = _trackview.track()->get_captured_frames(n);
|
||||
framecnt_t nlen = _trackview.track()->get_captured_frames(n);
|
||||
|
||||
if (nlen != region->length()) {
|
||||
|
||||
|
|
|
@ -78,7 +78,7 @@ class AudioStreamView : public StreamView
|
|||
|
||||
private:
|
||||
void setup_rec_box ();
|
||||
void rec_peak_range_ready (nframes_t start, nframes_t cnt, boost::weak_ptr<ARDOUR::Source> src);
|
||||
void rec_peak_range_ready (framepos_t start, ARDOUR::framecnt_t cnt, boost::weak_ptr<ARDOUR::Source> src);
|
||||
void update_rec_regions (ARDOUR::framepos_t, ARDOUR::framecnt_t);
|
||||
|
||||
RegionView* add_region_view_internal (boost::shared_ptr<ARDOUR::Region>, bool wait_for_waves, bool recording = false);
|
||||
|
|
|
@ -126,7 +126,7 @@ AutomationRegionView::canvas_event(GdkEvent* ev)
|
|||
* @param y y position, relative to our TimeAxisView.
|
||||
*/
|
||||
void
|
||||
AutomationRegionView::add_automation_event (GdkEvent *, nframes_t when, double y)
|
||||
AutomationRegionView::add_automation_event (GdkEvent *, framepos_t when, double y)
|
||||
{
|
||||
if (!_line) {
|
||||
boost::shared_ptr<Evoral::Control> c = _region->control(_parameter, true);
|
||||
|
|
|
@ -67,7 +67,7 @@ protected:
|
|||
bool set_position(framepos_t pos, void* src, double* ignored);
|
||||
void region_resized (const PBD::PropertyChange&);
|
||||
bool canvas_event(GdkEvent* ev);
|
||||
void add_automation_event (GdkEvent* event, nframes_t when, double y);
|
||||
void add_automation_event (GdkEvent* event, framepos_t when, double y);
|
||||
void entered (bool);
|
||||
void exited();
|
||||
|
||||
|
|
|
@ -587,7 +587,7 @@ AutomationTimeAxisView::build_display_menu ()
|
|||
}
|
||||
|
||||
void
|
||||
AutomationTimeAxisView::add_automation_event (ArdourCanvas::Item* /*item*/, GdkEvent* /*event*/, nframes_t when, double y)
|
||||
AutomationTimeAxisView::add_automation_event (ArdourCanvas::Item* /*item*/, GdkEvent* /*event*/, framepos_t when, double y)
|
||||
{
|
||||
if (!_line)
|
||||
return;
|
||||
|
|
|
@ -72,7 +72,7 @@ class AutomationTimeAxisView : public TimeAxisView {
|
|||
bool set_visibility (bool yn);
|
||||
std::string name() const { return _name; }
|
||||
|
||||
void add_automation_event (ArdourCanvas::Item *item, GdkEvent *event, nframes_t, double);
|
||||
void add_automation_event (ArdourCanvas::Item *item, GdkEvent *event, framepos_t, double);
|
||||
|
||||
void clear_lines ();
|
||||
|
||||
|
@ -86,7 +86,7 @@ class AutomationTimeAxisView : public TimeAxisView {
|
|||
void get_selectables (ARDOUR::framepos_t start, ARDOUR::framepos_t end, double top, double bot, std::list<Selectable *>&);
|
||||
void get_inverted_selectables (Selection&, std::list<Selectable*>& results);
|
||||
|
||||
void show_timestretch (nframes_t /*start*/, nframes_t /*end*/) {}
|
||||
void show_timestretch (framepos_t /*start*/, framepos_t /*end*/) {}
|
||||
void hide_timestretch () {}
|
||||
|
||||
/* editing operations */
|
||||
|
|
|
@ -656,7 +656,7 @@ CrossfadeEditor::redraw ()
|
|||
return;
|
||||
}
|
||||
|
||||
nframes_t len = xfade->length ();
|
||||
framecnt_t len = xfade->length ();
|
||||
|
||||
fade[current].normative_curve.clear ();
|
||||
fade[current].gain_curve.clear ();
|
||||
|
@ -1215,11 +1215,11 @@ void
|
|||
CrossfadeEditor::audition (Audition which)
|
||||
{
|
||||
AudioPlaylist& pl (_session->the_auditioner()->prepare_playlist());
|
||||
nframes_t preroll;
|
||||
nframes_t postroll;
|
||||
nframes_t left_start_offset;
|
||||
nframes_t right_length;
|
||||
nframes_t left_length;
|
||||
framecnt_t preroll;
|
||||
framecnt_t postroll;
|
||||
framecnt_t left_start_offset;
|
||||
framecnt_t right_length;
|
||||
framecnt_t left_length;
|
||||
|
||||
if (which != Right && preroll_button.get_active()) {
|
||||
preroll = _session->frame_rate() * 2; //2 second hardcoded preroll for now
|
||||
|
|
|
@ -1105,7 +1105,7 @@ Editor::set_session (Session *t)
|
|||
bbt.bars = 0;
|
||||
bbt.beats = 0;
|
||||
bbt.ticks = 120;
|
||||
nframes_t pos = _session->tempo_map().bbt_duration_at (0, bbt, 1);
|
||||
framepos_t pos = _session->tempo_map().bbt_duration_at (0, bbt, 1);
|
||||
nudge_clock.set_mode(AudioClock::BBT);
|
||||
nudge_clock.set (pos, true, 0, AudioClock::BBT);
|
||||
|
||||
|
|
|
@ -799,7 +799,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
|
|||
|
||||
MinsecRulerScale minsec_ruler_scale;
|
||||
|
||||
nframes_t minsec_mark_interval;
|
||||
framecnt_t minsec_mark_interval;
|
||||
gint minsec_mark_modulo;
|
||||
gint minsec_nmarks;
|
||||
void set_minsec_ruler_scale (gdouble lower, gdouble upper);
|
||||
|
@ -814,7 +814,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
|
|||
|
||||
TimecodeRulerScale timecode_ruler_scale;
|
||||
|
||||
nframes_t timecode_mark_interval;
|
||||
framecnt_t timecode_mark_interval;
|
||||
gint timecode_mark_modulo;
|
||||
gint timecode_nmarks;
|
||||
void set_timecode_ruler_scale (gdouble lower, gdouble upper);
|
||||
|
@ -1492,7 +1492,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
|
|||
void remove_metric_marks ();
|
||||
void draw_metric_marks (const ARDOUR::Metrics& metrics);
|
||||
|
||||
void compute_current_bbt_points (nframes_t left, nframes_t right);
|
||||
void compute_current_bbt_points (framepos_t left, framepos_t right);
|
||||
void tempo_map_changed (const PBD::PropertyChange&);
|
||||
void redisplay_tempo (bool immediate_redraw);
|
||||
|
||||
|
|
|
@ -1752,13 +1752,13 @@ Editor::temporal_zoom_session ()
|
|||
ENSURE_GUI_THREAD (*this, &Editor::temporal_zoom_session)
|
||||
|
||||
if (_session) {
|
||||
nframes_t const l = _session->current_end_frame() - _session->current_start_frame();
|
||||
framecnt_t const l = _session->current_end_frame() - _session->current_start_frame();
|
||||
double s = _session->current_start_frame() - l * 0.01;
|
||||
if (s < 0) {
|
||||
s = 0;
|
||||
}
|
||||
nframes_t const e = _session->current_end_frame() + l * 0.01;
|
||||
temporal_zoom_by_frame (nframes_t (s), e, "zoom to _session");
|
||||
framecnt_t const e = _session->current_end_frame() + l * 0.01;
|
||||
temporal_zoom_by_frame (framecnt_t (s), e, "zoom to _session");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2207,7 +2207,7 @@ Editor::insert_route_list_drag (boost::shared_ptr<Route> route, int x, int y)
|
|||
{
|
||||
double wx, wy;
|
||||
double cx, cy;
|
||||
nframes_t where;
|
||||
framepos_t where;
|
||||
RouteTimeAxisView *dest_rtv = 0;
|
||||
RouteTimeAxisView *source_rtv = 0;
|
||||
|
||||
|
@ -4188,8 +4188,8 @@ Editor::duplicate_some_regions (RegionSelection& regions, float times)
|
|||
RegionSelection sel = regions; // clear (below) may clear the argument list if its the current region selection
|
||||
RegionSelection foo;
|
||||
|
||||
nframes_t const start_frame = regions.start ();
|
||||
nframes_t const end_frame = regions.end_frame ();
|
||||
framepos_t const start_frame = regions.start ();
|
||||
framepos_t const end_frame = regions.end_frame ();
|
||||
|
||||
begin_reversible_command (_("duplicate region"));
|
||||
|
||||
|
|
|
@ -800,9 +800,9 @@ EditorRegions::format_position (framepos_t pos, char* buf, size_t bufsize)
|
|||
|
||||
left = pos;
|
||||
hrs = (int) floor (left / (_session->frame_rate() * 60.0f * 60.0f));
|
||||
left -= (nframes_t) floor (hrs * _session->frame_rate() * 60.0f * 60.0f);
|
||||
left -= (framecnt_t) floor (hrs * _session->frame_rate() * 60.0f * 60.0f);
|
||||
mins = (int) floor (left / (_session->frame_rate() * 60.0f));
|
||||
left -= (nframes_t) floor (mins * _session->frame_rate() * 60.0f);
|
||||
left -= (framecnt_t) floor (mins * _session->frame_rate() * 60.0f);
|
||||
secs = left / (float) _session->frame_rate();
|
||||
snprintf (buf, bufsize, "%02d:%02d:%06.3f", hrs, mins, secs);
|
||||
break;
|
||||
|
@ -844,13 +844,13 @@ EditorRegions::populate_row (boost::shared_ptr<Region> region, TreeModel::Row co
|
|||
#if 0
|
||||
if (audioRegion && fades_in_seconds) {
|
||||
|
||||
nframes_t left;
|
||||
framepos_t left;
|
||||
int mins;
|
||||
int millisecs;
|
||||
|
||||
left = audioRegion->fade_in()->back()->when;
|
||||
mins = (int) floor (left / (_session->frame_rate() * 60.0f));
|
||||
left -= (nframes_t) floor (mins * _session->frame_rate() * 60.0f);
|
||||
left -= (framepos_t) floor (mins * _session->frame_rate() * 60.0f);
|
||||
millisecs = (int) floor ((left * 1000.0f) / _session->frame_rate());
|
||||
|
||||
if (audioRegion->fade_in()->back()->when >= _session->frame_rate()) {
|
||||
|
@ -861,7 +861,7 @@ EditorRegions::populate_row (boost::shared_ptr<Region> region, TreeModel::Row co
|
|||
|
||||
left = audioRegion->fade_out()->back()->when;
|
||||
mins = (int) floor (left / (_session->frame_rate() * 60.0f));
|
||||
left -= (nframes_t) floor (mins * _session->frame_rate() * 60.0f);
|
||||
left -= (framepos_t) floor (mins * _session->frame_rate() * 60.0f);
|
||||
millisecs = (int) floor ((left * 1000.0f) / _session->frame_rate());
|
||||
|
||||
if (audioRegion->fade_out()->back()->when >= _session->frame_rate()) {
|
||||
|
|
|
@ -1002,7 +1002,7 @@ Editor::metric_get_timecode (GtkCustomRulerMark **marks, gdouble lower, gdouble
|
|||
lower = 0;
|
||||
}
|
||||
|
||||
pos = (nframes_t) floor (lower);
|
||||
pos = (framecnt_t) floor (lower);
|
||||
|
||||
*marks = (GtkCustomRulerMark *) g_malloc (sizeof(GtkCustomRulerMark) * timecode_nmarks);
|
||||
switch (timecode_ruler_scale) {
|
||||
|
@ -1150,8 +1150,8 @@ Editor::compute_bbt_ruler_scale (framepos_t lower, framepos_t upper)
|
|||
TempoMap::BBTPointList::iterator i;
|
||||
BBT_Time lower_beat, upper_beat; // the beats at each end of the ruler
|
||||
|
||||
_session->bbt_time((jack_nframes_t) lower, lower_beat);
|
||||
_session->bbt_time((jack_nframes_t) upper, upper_beat);
|
||||
_session->bbt_time (lower, lower_beat);
|
||||
_session->bbt_time (upper, upper_beat);
|
||||
uint32_t beats = 0;
|
||||
|
||||
bbt_accent_modulo = 1;
|
||||
|
|
|
@ -147,7 +147,7 @@ EditorSummary::render (cairo_t* cr)
|
|||
|
||||
/* compute start and end points for the summary */
|
||||
|
||||
nframes_t const session_length = _session->current_end_frame() - _session->current_start_frame ();
|
||||
framecnt_t const session_length = _session->current_end_frame() - _session->current_start_frame ();
|
||||
double const theoretical_start = _session->current_start_frame() - session_length * _overhang_fraction;
|
||||
_start = theoretical_start > 0 ? theoretical_start : 0;
|
||||
_end = _session->current_end_frame() + session_length * _overhang_fraction;
|
||||
|
|
|
@ -80,8 +80,8 @@ private:
|
|||
Position get_position (double, double) const;
|
||||
void set_cursor (Position);
|
||||
|
||||
nframes_t _start; ///< start frame of the overview
|
||||
nframes_t _end; ///< end frame of the overview
|
||||
framepos_t _start; ///< start frame of the overview
|
||||
framepos_t _end; ///< end frame of the overview
|
||||
|
||||
/** fraction of the session length by which the overview size should extend past the start and end markers */
|
||||
double _overhang_fraction;
|
||||
|
|
|
@ -138,7 +138,7 @@ Editor::redisplay_tempo (bool immediate_redraw)
|
|||
}
|
||||
|
||||
void
|
||||
Editor::compute_current_bbt_points (nframes_t leftmost, nframes_t rightmost)
|
||||
Editor::compute_current_bbt_points (framepos_t leftmost, framepos_t rightmost)
|
||||
{
|
||||
if (!_session) {
|
||||
return;
|
||||
|
|
|
@ -210,7 +210,7 @@ ExportFormatDialog::set_session (ARDOUR::Session* s)
|
|||
if (sample_rate_view.get_selection()->count_selected_rows() == 0) {
|
||||
Gtk::ListStore::Children::iterator it;
|
||||
for (it = sample_rate_list->children().begin(); it != sample_rate_list->children().end(); ++it) {
|
||||
if ((nframes_t) (*it)->get_value (sample_rate_cols.ptr)->rate == _session->nominal_frame_rate()) {
|
||||
if ((framecnt_t) (*it)->get_value (sample_rate_cols.ptr)->rate == _session->nominal_frame_rate()) {
|
||||
sample_rate_view.get_selection()->select (it);
|
||||
break;
|
||||
}
|
||||
|
@ -761,7 +761,7 @@ ExportFormatDialog::update_time (AnyTime & time, AudioClock const & clock)
|
|||
return;
|
||||
}
|
||||
|
||||
nframes_t frames = clock.current_duration();
|
||||
framecnt_t frames = clock.current_duration();
|
||||
|
||||
switch (clock.mode()) {
|
||||
case AudioClock::Timecode:
|
||||
|
|
|
@ -171,7 +171,7 @@ ExportRangeMarkersDialog::init_progress_computing(Locations::LocationList& locat
|
|||
// flush vector
|
||||
range_markers_durations_aggregated.resize(0);
|
||||
|
||||
nframes_t duration_before_current_location = 0;
|
||||
framecnt_t duration_before_current_location = 0;
|
||||
Locations::LocationList::iterator locationIter;
|
||||
|
||||
for (locationIter = locations.begin(); locationIter != locations.end(); ++locationIter) {
|
||||
|
@ -180,7 +180,7 @@ ExportRangeMarkersDialog::init_progress_computing(Locations::LocationList& locat
|
|||
if(currentLocation->is_range_marker()){
|
||||
range_markers_durations_aggregated.push_back (duration_before_current_location);
|
||||
|
||||
nframes_t duration = currentLocation->end() - currentLocation->start();
|
||||
framecnt_t duration = currentLocation->end() - currentLocation->start();
|
||||
|
||||
range_markers_durations.push_back (duration);
|
||||
duration_before_current_location += duration;
|
||||
|
|
|
@ -537,7 +537,7 @@ ImageFrameSocketHandler::send_imageframe_time_axis_group_renamed(const string &
|
|||
* @param item the time axis item whos position has changed
|
||||
*/
|
||||
void
|
||||
ImageFrameSocketHandler::send_imageframe_view_position_change(nframes_t pos, void* src, ImageFrameView* item)
|
||||
ImageFrameSocketHandler::send_imageframe_view_position_change (framepos_t pos, void* src, ImageFrameView* item)
|
||||
{
|
||||
// ENSURE_GUI_THREAD (*this, &ImageFrameSocketHandler::send_imageframe_view_position_change, pos, src, item)
|
||||
|
||||
|
@ -573,7 +573,7 @@ ImageFrameSocketHandler::send_imageframe_view_position_change(nframes_t pos, voi
|
|||
* @param item the item which has had a duration change
|
||||
*/
|
||||
void
|
||||
ImageFrameSocketHandler::send_imageframe_view_duration_change(nframes_t dur, void* src, ImageFrameView* item)
|
||||
ImageFrameSocketHandler::send_imageframe_view_duration_change (framecnt_t dur, void* src, ImageFrameView* item)
|
||||
{
|
||||
// ENSURE_GUI_THREAD (*this, &ImageFrameSocketHandler::send_imageframe_view_duration_change, dur, src, item)
|
||||
|
||||
|
@ -687,7 +687,7 @@ ImageFrameSocketHandler::send_imageframe_view_removed(const string & item_id, vo
|
|||
* @param item the time axis item whos position has changed
|
||||
*/
|
||||
void
|
||||
ImageFrameSocketHandler::send_marker_view_position_change(nframes_t pos, void* src, MarkerView* item)
|
||||
ImageFrameSocketHandler::send_marker_view_position_change (framepos_t pos, void* src, MarkerView* item)
|
||||
{
|
||||
if(this == src || src == 0)
|
||||
{
|
||||
|
@ -721,7 +721,7 @@ ImageFrameSocketHandler::send_marker_view_position_change(nframes_t pos, void* s
|
|||
* @param item the time axis item whos position has changed
|
||||
*/
|
||||
void
|
||||
ImageFrameSocketHandler::send_marker_view_duration_change(nframes_t dur, void* src, MarkerView* item)
|
||||
ImageFrameSocketHandler::send_marker_view_duration_change (framecnt_t dur, void* src, MarkerView* item)
|
||||
{
|
||||
if(this == src || src == 0)
|
||||
{
|
||||
|
@ -1336,11 +1336,11 @@ ImageFrameSocketHandler::handle_insert_imageframe_view(const char* msg)
|
|||
position += image_id_size ;
|
||||
|
||||
// get the start frame value
|
||||
nframes_t start = strtoul((get_message_part(position,10,msg).c_str()),0,10) ;
|
||||
framepos_t start = strtoul((get_message_part(position,10,msg).c_str()),0,10) ;
|
||||
position += 10 ;
|
||||
|
||||
// get the duration value
|
||||
nframes_t duration = strtoul((get_message_part(position,10,msg).c_str()),0,10) ;
|
||||
framecnt_t duration = strtoul((get_message_part(position,10,msg).c_str()),0,10) ;
|
||||
position += 10 ;
|
||||
|
||||
//get the named time axis view we about to add an image to
|
||||
|
@ -1672,7 +1672,7 @@ ImageFrameSocketHandler::handle_imageframe_view_position_update(const char* msg)
|
|||
|
||||
this->decompose_imageframe_item_desc(msg, position, track_id, track_id_size, scene_id, scene_id_size, item_id, item_id_size) ;
|
||||
|
||||
nframes_t start_frame = strtoul(get_message_part(position, ardourvis::TIME_VALUE_CHARS, msg).c_str(), 0, 10) ;
|
||||
framepos_t start_frame = strtoul(get_message_part(position, ardourvis::TIME_VALUE_CHARS, msg).c_str(), 0, 10) ;
|
||||
position += ardourvis::TIME_VALUE_CHARS ;
|
||||
|
||||
// get the named time axis
|
||||
|
@ -1724,7 +1724,7 @@ ImageFrameSocketHandler::handle_imageframe_view_duration_update(const char* msg)
|
|||
|
||||
this->decompose_imageframe_item_desc(msg, position, track_id, track_id_size, scene_id, scene_id_size, item_id, item_id_size) ;
|
||||
|
||||
nframes_t duration = strtoul(get_message_part(position,ardourvis::TIME_VALUE_CHARS,msg).c_str(),0,10) ;
|
||||
framecnt_t duration = strtoul(get_message_part(position,ardourvis::TIME_VALUE_CHARS,msg).c_str(),0,10) ;
|
||||
position += ardourvis::TIME_VALUE_CHARS ;
|
||||
|
||||
// get the named time axis
|
||||
|
@ -1827,7 +1827,7 @@ ImageFrameSocketHandler::handle_imageframe_view_max_duration_update(const char*
|
|||
|
||||
this->decompose_imageframe_item_desc(msg, position, track_id, track_id_size, group_id, group_id_size, item_id, item_id_size) ;
|
||||
|
||||
nframes_t max_duration = strtoul(get_message_part(position,ardourvis::TIME_VALUE_CHARS,msg).c_str(),0,10) ;
|
||||
framecnt_t max_duration = strtoul(get_message_part(position,ardourvis::TIME_VALUE_CHARS,msg).c_str(),0,10) ;
|
||||
position += ardourvis::TIME_VALUE_CHARS ;
|
||||
|
||||
int errcode ;
|
||||
|
@ -1915,7 +1915,7 @@ ImageFrameSocketHandler::handle_imageframe_view_min_duration_update(const char*
|
|||
|
||||
this->decompose_imageframe_item_desc(msg, position, track_id, track_id_size, group_id, group_id_size, item_id, item_id_size) ;
|
||||
|
||||
nframes_t min_duration = strtoul(get_message_part(position,ardourvis::TIME_VALUE_CHARS,msg).c_str(),0,10) ;
|
||||
framecnt_t min_duration = strtoul(get_message_part(position,ardourvis::TIME_VALUE_CHARS,msg).c_str(),0,10) ;
|
||||
position += ardourvis::TIME_VALUE_CHARS ;
|
||||
|
||||
int errcode ;
|
||||
|
|
|
@ -198,7 +198,7 @@ ImageFrameTimeAxisGroup::apply_item_color(Gdk::Color& color)
|
|||
* @param src the identity of the object that initiated the change
|
||||
*/
|
||||
ImageFrameView*
|
||||
ImageFrameTimeAxisGroup::add_imageframe_item(const string & frame_id, nframes_t start, nframes_t duration, unsigned char* rgb_data, uint32_t width, uint32_t height, uint32_t num_channels, void* src)
|
||||
ImageFrameTimeAxisGroup::add_imageframe_item(const string & frame_id, framepos_t start, framecnt_t duration, unsigned char* rgb_data, uint32_t width, uint32_t height, uint32_t num_channels, void* src)
|
||||
{
|
||||
ImageFrameView* ifv = 0;
|
||||
|
||||
|
|
|
@ -406,9 +406,8 @@ ImageFrameTimeAxisView::get_selected_imageframe_view() const
|
|||
void
|
||||
ImageFrameTimeAxisView::set_imageframe_duration_sec(double sec)
|
||||
{
|
||||
if(selected_imageframe_group && selected_imageframe_view)
|
||||
{
|
||||
selected_imageframe_view->set_duration((nframes_t) (sec * _trackview.editor.session()->frame_rate()), this) ;
|
||||
if (selected_imageframe_group && selected_imageframe_view) {
|
||||
selected_imageframe_view->set_duration ((sec * _trackview.editor.session()->frame_rate()), this);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -60,8 +60,8 @@ ImageFrameView::ImageFrameView(const string & item_id,
|
|||
ImageFrameTimeAxisGroup* item_group,
|
||||
double spu,
|
||||
Gdk::Color& basic_color,
|
||||
nframes_t start,
|
||||
nframes_t duration,
|
||||
framepos_t start,
|
||||
framecnt_t duration,
|
||||
unsigned char* rgb_data,
|
||||
uint32_t width,
|
||||
uint32_t height,
|
||||
|
|
|
@ -65,8 +65,8 @@ class ImageFrameView : public TimeAxisViewItem
|
|||
ImageFrameTimeAxisGroup* group,
|
||||
double spu,
|
||||
Gdk::Color& base_color,
|
||||
nframes_t start,
|
||||
nframes_t duration,
|
||||
framepos_t start,
|
||||
framecnt_t duration,
|
||||
unsigned char* rgb_data,
|
||||
uint32_t width,
|
||||
uint32_t height,
|
||||
|
|
|
@ -934,7 +934,7 @@ LocationUI::add_new_location()
|
|||
string markername;
|
||||
|
||||
if (_session) {
|
||||
nframes_t where = _session->audible_frame();
|
||||
framepos_t where = _session->audible_frame();
|
||||
_session->locations()->next_available_name(markername,"mark");
|
||||
Location *location = new Location (*_session, where, where, markername, Location::IsMark);
|
||||
if (Config->get_name_new_markers()) {
|
||||
|
@ -956,7 +956,7 @@ LocationUI::add_new_range()
|
|||
string rangename;
|
||||
|
||||
if (_session) {
|
||||
nframes_t where = _session->audible_frame();
|
||||
framepos_t where = _session->audible_frame();
|
||||
_session->locations()->next_available_name(rangename,"unnamed");
|
||||
Location *location = new Location (*_session, where, where, rangename, Location::IsRangeMarker);
|
||||
_session->begin_reversible_command (_("add range marker"));
|
||||
|
|
|
@ -46,7 +46,7 @@ using namespace Gtkmm2ext;
|
|||
PBD::Signal1<void,Marker*> Marker::CatchDeletion;
|
||||
|
||||
Marker::Marker (PublicEditor& ed, ArdourCanvas::Group& parent, ArdourCanvas::Group& line_parent, guint32 rgba, const string& annotation,
|
||||
Type type, nframes_t frame, bool handle_events)
|
||||
Type type, framepos_t frame, bool handle_events)
|
||||
|
||||
: editor (ed)
|
||||
, _parent (&parent)
|
||||
|
|
|
@ -57,7 +57,7 @@ class Marker : public sigc::trackable
|
|||
|
||||
|
||||
Marker (PublicEditor& editor, ArdourCanvas::Group &, ArdourCanvas::Group &, guint32 rgba, const std::string& text, Type,
|
||||
nframes_t frame = 0, bool handle_events = true);
|
||||
framepos_t frame = 0, bool handle_events = true);
|
||||
|
||||
virtual ~Marker ();
|
||||
|
||||
|
|
|
@ -192,7 +192,7 @@ MarkerTimeAxisView::apply_color(Gdk::Color& color)
|
|||
* @param src the identity of the object that initiated the change
|
||||
*/
|
||||
MarkerView*
|
||||
MarkerTimeAxisView::add_marker_view(ImageFrameView* ifv, std::string mark_type, std::string mark_id, nframes_t start, nframes_t dur, void* src)
|
||||
MarkerTimeAxisView::add_marker_view(ImageFrameView* ifv, std::string mark_type, std::string mark_id, framepos_t start, framecnt_t dur, void* src)
|
||||
{
|
||||
if(ifv->has_marker_view_item(mark_id))
|
||||
{
|
||||
|
@ -335,7 +335,7 @@ MarkerTimeAxisView::set_marker_duration_sec(double sec)
|
|||
{
|
||||
if(get_selected_time_axis_item() != 0)
|
||||
{
|
||||
get_selected_time_axis_item()->set_duration((nframes_t) (sec * _trackview.editor.session()->frame_rate()), this) ;
|
||||
get_selected_time_axis_item()->set_duration((sec * _trackview.editor.session()->frame_rate()), this);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -52,8 +52,8 @@ MarkerView::MarkerView(ArdourCanvas::Group *parent,
|
|||
Gdk::Color& basic_color,
|
||||
std::string mark_type,
|
||||
std::string mark_id,
|
||||
nframes_t start,
|
||||
nframes_t duration)
|
||||
framepos_t start,
|
||||
framecnt_t duration)
|
||||
: TimeAxisViewItem(mark_id, *parent,*tv,spu,basic_color,start,duration)
|
||||
{
|
||||
mark_type_text = mark_type ;
|
||||
|
|
|
@ -437,7 +437,7 @@ MidiStreamView::setup_rec_box ()
|
|||
|
||||
// handle multi
|
||||
|
||||
nframes_t start = 0;
|
||||
framepos_t start = 0;
|
||||
if (rec_regions.size() > 0) {
|
||||
start = rec_regions.back().first->start()
|
||||
+ _trackview.track()->get_captured_frames(rec_regions.size()-1);
|
||||
|
|
|
@ -35,6 +35,8 @@
|
|||
#include <iostream>
|
||||
#include <cmath>
|
||||
|
||||
using namespace ARDOUR;
|
||||
|
||||
PluginEqGui::PluginEqGui(boost::shared_ptr<ARDOUR::PluginInsert> pluginInsert)
|
||||
: _min_dB(-12.0),
|
||||
_max_dB(+12.0),
|
||||
|
@ -315,8 +317,8 @@ PluginEqGui::run_impulse_analysis()
|
|||
ARDOUR::ChanMapping in_map(_plugin->get_info()->n_inputs);
|
||||
ARDOUR::ChanMapping out_map(_plugin->get_info()->n_outputs);
|
||||
|
||||
_plugin->connect_and_run(_bufferset, in_map, out_map, _buffer_size, (nframes_t)0);
|
||||
nframes_t f = _plugin->signal_latency();
|
||||
_plugin->connect_and_run(_bufferset, in_map, out_map, _buffer_size, 0);
|
||||
framecnt_t f = _plugin->signal_latency ();
|
||||
// Adding user_latency() could be interesting
|
||||
|
||||
// Gather all output, taking latency into account.
|
||||
|
@ -338,8 +340,8 @@ PluginEqGui::run_impulse_analysis()
|
|||
} else {
|
||||
//int C = 0;
|
||||
//std::cerr << (++C) << ": latency is " << f << " frames, doing split processing.." << std::endl;
|
||||
nframes_t target_offset = 0;
|
||||
nframes_t frames_left = _buffer_size; // refaktoroi
|
||||
framecnt_t target_offset = 0;
|
||||
framecnt_t frames_left = _buffer_size; // refaktoroi
|
||||
do {
|
||||
if (f >= _buffer_size) {
|
||||
//std::cerr << (++C) << ": f (=" << f << ") is larger than buffer_size, still trying to reach the actual output" << std::endl;
|
||||
|
@ -351,7 +353,7 @@ PluginEqGui::run_impulse_analysis()
|
|||
// we start at output offset "f"
|
||||
// .. and copy "buffer size" - "f" - "offset" frames
|
||||
|
||||
nframes_t length = _buffer_size - f - target_offset;
|
||||
framecnt_t length = _buffer_size - f - target_offset;
|
||||
|
||||
//std::cerr << (++C) << ": copying " << length << " frames to _collect_bufferset.get_audio(i)+" << target_offset << " from bufferset at offset " << f << std::endl;
|
||||
for (uint32_t i = 0; i < outputs; ++i) {
|
||||
|
@ -374,7 +376,7 @@ PluginEqGui::run_impulse_analysis()
|
|||
|
||||
in_map = ARDOUR::ChanMapping(_plugin->get_info()->n_inputs);
|
||||
out_map = ARDOUR::ChanMapping(_plugin->get_info()->n_outputs);
|
||||
_plugin->connect_and_run(_bufferset, in_map, out_map, _buffer_size, (nframes_t)0);
|
||||
_plugin->connect_and_run(_bufferset, in_map, out_map, _buffer_size, 0);
|
||||
}
|
||||
} while ( frames_left > 0);
|
||||
|
||||
|
|
|
@ -89,8 +89,8 @@ class PluginEqGui : public Gtk::Table
|
|||
float _log_coeff;
|
||||
float _log_max;
|
||||
|
||||
nframes_t _buffer_size;
|
||||
nframes_t _signal_buffer_size;
|
||||
ARDOUR::framecnt_t _buffer_size;
|
||||
ARDOUR::framecnt_t _signal_buffer_size;
|
||||
|
||||
// buffers
|
||||
ARDOUR::BufferSet _bufferset;
|
||||
|
|
|
@ -471,8 +471,8 @@ void
|
|||
PlugUIBase::set_latency_label ()
|
||||
{
|
||||
char buf[64];
|
||||
nframes_t l = insert->effective_latency ();
|
||||
nframes_t sr = insert->session().frame_rate();
|
||||
framecnt_t const l = insert->effective_latency ();
|
||||
framecnt_t const sr = insert->session().frame_rate ();
|
||||
|
||||
if (l < sr / 1000) {
|
||||
snprintf (buf, sizeof (buf), "latency (%d samples)", l);
|
||||
|
|
|
@ -71,7 +71,7 @@ PortInsertUI::PortInsertUI (Gtk::Window* parent, ARDOUR::Session* sess, boost::s
|
|||
void
|
||||
PortInsertUI::update_latency_display ()
|
||||
{
|
||||
nframes_t sample_rate = input_selector.session()->engine().frame_rate();
|
||||
framecnt_t const sample_rate = input_selector.session()->engine().frame_rate();
|
||||
if (sample_rate == 0) {
|
||||
latency_display.set_text (_("Disconnected from audio engine"));
|
||||
} else {
|
||||
|
@ -98,7 +98,7 @@ PortInsertUI::check_latency_measurement ()
|
|||
}
|
||||
|
||||
char buf[128];
|
||||
nframes_t sample_rate = AudioEngine::instance()->frame_rate();
|
||||
framecnt_t const sample_rate = AudioEngine::instance()->frame_rate();
|
||||
|
||||
if (sample_rate == 0) {
|
||||
latency_display.set_text (_("Disconnected from audio engine"));
|
||||
|
@ -121,7 +121,7 @@ PortInsertUI::check_latency_measurement ()
|
|||
}
|
||||
|
||||
if (solid) {
|
||||
_pi->set_measured_latency ((nframes_t) rint (mtdm->del()));
|
||||
_pi->set_measured_latency (rint (mtdm->del()));
|
||||
latency_button.set_active (false);
|
||||
strcat (buf, " (set)");
|
||||
}
|
||||
|
|
|
@ -196,10 +196,6 @@ class PublicEditor : public Gtk::Window, public PBD::StatefulDestructible {
|
|||
|
||||
virtual void transition_to_rolling (bool fwd) = 0;
|
||||
virtual framepos_t unit_to_frame (double unit) const = 0;
|
||||
// XXX remove me when libardour goes framepos_t
|
||||
double frame_to_unit (nframes_t frame) const {
|
||||
return frame_to_unit ((framepos_t) frame);
|
||||
}
|
||||
virtual double frame_to_unit (framepos_t frame) const = 0;
|
||||
virtual double frame_to_unit (double frame) const = 0;
|
||||
virtual framepos_t pixel_to_frame (double pixel) const = 0;
|
||||
|
|
|
@ -291,7 +291,7 @@ RegionEditor::end_clock_changed ()
|
|||
void
|
||||
RegionEditor::length_clock_changed ()
|
||||
{
|
||||
nframes_t frames = length_clock.current_time();
|
||||
framecnt_t frames = length_clock.current_time();
|
||||
|
||||
_session->begin_reversible_command (_("change region length"));
|
||||
|
||||
|
@ -343,7 +343,7 @@ RegionEditor::bounds_changed (const PropertyChange& what_changed)
|
|||
|
||||
if (what_changed.contains (ARDOUR::Properties::sync_position) || what_changed.contains (ARDOUR::Properties::position)) {
|
||||
int dir;
|
||||
nframes_t off = _region->sync_offset (dir);
|
||||
frameoffset_t off = _region->sync_offset (dir);
|
||||
if (dir == -1) {
|
||||
off = -off;
|
||||
}
|
||||
|
|
|
@ -468,7 +468,7 @@ void
|
|||
RegionView::region_sync_changed ()
|
||||
{
|
||||
int sync_dir;
|
||||
nframes_t sync_offset;
|
||||
framecnt_t sync_offset;
|
||||
|
||||
sync_offset = _region->sync_offset (sync_dir);
|
||||
|
||||
|
@ -595,7 +595,7 @@ RegionView::set_height (double h)
|
|||
if (sync_line) {
|
||||
Points points;
|
||||
int sync_dir;
|
||||
nframes_t sync_offset;
|
||||
framecnt_t sync_offset;
|
||||
sync_offset = _region->sync_offset (sync_dir);
|
||||
double offset = sync_offset / samples_per_unit;
|
||||
|
||||
|
@ -631,9 +631,9 @@ RegionView::update_coverage_frames (LayerDisplay d)
|
|||
return;
|
||||
}
|
||||
|
||||
nframes_t const position = _region->first_frame ();
|
||||
nframes_t t = position;
|
||||
nframes_t const end = _region->last_frame ();
|
||||
framepos_t const position = _region->first_frame ();
|
||||
framepos_t t = position;
|
||||
framepos_t const end = _region->last_frame ();
|
||||
|
||||
ArdourCanvas::SimpleRect* cr = 0;
|
||||
bool me = false;
|
||||
|
|
|
@ -260,7 +260,7 @@ RouteParams_UI::refresh_latency ()
|
|||
latency_widget->refresh();
|
||||
|
||||
char buf[128];
|
||||
snprintf (buf, sizeof (buf), _("Playback delay: %u samples"), _route->initial_delay());
|
||||
snprintf (buf, sizeof (buf), _("Playback delay: %" PRId64 " samples"), _route->initial_delay());
|
||||
delay_label.set_text (buf);
|
||||
}
|
||||
}
|
||||
|
@ -288,7 +288,7 @@ RouteParams_UI::setup_latency_frame ()
|
|||
latency_widget = new LatencyGUI (*(_route->output()), _session->frame_rate(), _session->engine().frames_per_cycle());
|
||||
|
||||
char buf[128];
|
||||
snprintf (buf, sizeof (buf), _("Playback delay: %u samples"), _route->initial_delay());
|
||||
snprintf (buf, sizeof (buf), _("Playback delay: %" PRId64 " samples"), _route->initial_delay());
|
||||
delay_label.set_text (buf);
|
||||
|
||||
latency_packer.pack_start (*latency_widget, false, false);
|
||||
|
|
|
@ -672,7 +672,7 @@ RouteTimeAxisView::track_mode_changed ()
|
|||
}
|
||||
|
||||
void
|
||||
RouteTimeAxisView::show_timestretch (nframes_t start, nframes_t end)
|
||||
RouteTimeAxisView::show_timestretch (framepos_t start, framepos_t end)
|
||||
{
|
||||
double x1;
|
||||
double x2;
|
||||
|
@ -1208,8 +1208,8 @@ RouteTimeAxisView::get_selectables (framepos_t start, framepos_t end, double top
|
|||
speed = track()->speed();
|
||||
}
|
||||
|
||||
nframes_t start_adjusted = session_frame_to_track_frame(start, speed);
|
||||
nframes_t end_adjusted = session_frame_to_track_frame(end, speed);
|
||||
framepos_t const start_adjusted = session_frame_to_track_frame(start, speed);
|
||||
framepos_t const end_adjusted = session_frame_to_track_frame(end, speed);
|
||||
|
||||
if ((_view && ((top < 0.0 && bot < 0.0))) || touched (top, bot)) {
|
||||
_view->get_selectables (start_adjusted, end_adjusted, top, bot, results);
|
||||
|
@ -1295,7 +1295,7 @@ RouteTimeAxisView::name_entry_changed ()
|
|||
}
|
||||
|
||||
boost::shared_ptr<Region>
|
||||
RouteTimeAxisView::find_next_region (nframes_t pos, RegionPoint point, int32_t dir)
|
||||
RouteTimeAxisView::find_next_region (framepos_t pos, RegionPoint point, int32_t dir)
|
||||
{
|
||||
boost::shared_ptr<Playlist> pl = playlist ();
|
||||
|
||||
|
|
|
@ -78,7 +78,7 @@ public:
|
|||
|
||||
void set_samples_per_unit (double);
|
||||
void set_height (uint32_t h);
|
||||
void show_timestretch (nframes_t start, nframes_t end);
|
||||
void show_timestretch (framepos_t start, framepos_t end);
|
||||
void hide_timestretch ();
|
||||
void selection_click (GdkEventButton*);
|
||||
void set_selected_points (PointSelection&);
|
||||
|
@ -88,7 +88,7 @@ public:
|
|||
void set_layer_display (LayerDisplay d);
|
||||
LayerDisplay layer_display () const;
|
||||
|
||||
boost::shared_ptr<ARDOUR::Region> find_next_region (nframes_t pos, ARDOUR::RegionPoint, int32_t dir);
|
||||
boost::shared_ptr<ARDOUR::Region> find_next_region (framepos_t pos, ARDOUR::RegionPoint, int32_t dir);
|
||||
framepos_t find_next_region_boundary (framepos_t pos, int32_t dir);
|
||||
|
||||
/* Editing operations */
|
||||
|
@ -232,7 +232,7 @@ protected:
|
|||
virtual void show_existing_automation ();
|
||||
virtual void hide_all_automation ();
|
||||
|
||||
void timestretch (nframes_t start, nframes_t end);
|
||||
void timestretch (framepos_t start, framepos_t end);
|
||||
|
||||
void speed_changed ();
|
||||
|
||||
|
|
|
@ -304,7 +304,7 @@ Selection::toggle (vector<RegionView*>& r)
|
|||
}
|
||||
|
||||
long
|
||||
Selection::toggle (nframes_t start, nframes_t end)
|
||||
Selection::toggle (framepos_t start, framepos_t end)
|
||||
{
|
||||
AudioRangeComparator cmp;
|
||||
|
||||
|
@ -462,7 +462,7 @@ Selection::add (MidiRegionView* mrv)
|
|||
}
|
||||
|
||||
long
|
||||
Selection::add (nframes_t start, nframes_t end)
|
||||
Selection::add (framepos_t start, framepos_t end)
|
||||
{
|
||||
AudioRangeComparator cmp;
|
||||
|
||||
|
@ -478,7 +478,7 @@ Selection::add (nframes_t start, nframes_t end)
|
|||
}
|
||||
|
||||
void
|
||||
Selection::replace (uint32_t sid, nframes_t start, nframes_t end)
|
||||
Selection::replace (uint32_t sid, framepos_t start, framepos_t end)
|
||||
{
|
||||
for (list<AudioRange>::iterator i = time.begin(); i != time.end(); ++i) {
|
||||
if ((*i).id == sid) {
|
||||
|
@ -654,7 +654,7 @@ Selection::remove (uint32_t selection_id)
|
|||
}
|
||||
|
||||
void
|
||||
Selection::remove (nframes_t /*start*/, nframes_t /*end*/)
|
||||
Selection::remove (framepos_t /*start*/, framepos_t /*end*/)
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -744,7 +744,7 @@ Selection::set (vector<RegionView*>& v)
|
|||
* the list of tracks it applies to.
|
||||
*/
|
||||
long
|
||||
Selection::set (nframes_t start, nframes_t end)
|
||||
Selection::set (framepos_t start, framepos_t end)
|
||||
{
|
||||
if ((start == 0 && end == 0) || end < start) {
|
||||
return 0;
|
||||
|
|
|
@ -121,7 +121,7 @@ class Selection : public sigc::trackable, public PBD::ScopedConnectionList
|
|||
void set (RegionView*, bool also_clear_tracks = true);
|
||||
void set (MidiRegionView*);
|
||||
void set (std::vector<RegionView*>&);
|
||||
long set (nframes_t, nframes_t);
|
||||
long set (framepos_t, framepos_t);
|
||||
void set (boost::shared_ptr<Evoral::ControlList>);
|
||||
void set (boost::shared_ptr<ARDOUR::Playlist>);
|
||||
void set (const std::list<boost::shared_ptr<ARDOUR::Playlist> >&);
|
||||
|
@ -136,7 +136,7 @@ class Selection : public sigc::trackable, public PBD::ScopedConnectionList
|
|||
void toggle (MidiRegionView*);
|
||||
void toggle (MidiCutBuffer*);
|
||||
void toggle (std::vector<RegionView*>&);
|
||||
long toggle (nframes_t, nframes_t);
|
||||
long toggle (framepos_t, framepos_t);
|
||||
void toggle (ARDOUR::AutomationList*);
|
||||
void toggle (boost::shared_ptr<ARDOUR::Playlist>);
|
||||
void toggle (const std::list<boost::shared_ptr<ARDOUR::Playlist> >&);
|
||||
|
@ -151,7 +151,7 @@ class Selection : public sigc::trackable, public PBD::ScopedConnectionList
|
|||
void add (MidiRegionView*);
|
||||
void add (MidiCutBuffer*);
|
||||
void add (std::vector<RegionView*>&);
|
||||
long add (nframes_t, nframes_t);
|
||||
long add (framepos_t, framepos_t);
|
||||
void add (boost::shared_ptr<Evoral::ControlList>);
|
||||
void add (boost::shared_ptr<ARDOUR::Playlist>);
|
||||
void add (const std::list<boost::shared_ptr<ARDOUR::Playlist> >&);
|
||||
|
@ -167,14 +167,14 @@ class Selection : public sigc::trackable, public PBD::ScopedConnectionList
|
|||
void remove (MidiRegionView*);
|
||||
void remove (MidiCutBuffer*);
|
||||
void remove (uint32_t selection_id);
|
||||
void remove (nframes_t, nframes_t);
|
||||
void remove (framepos_t, framepos_t);
|
||||
void remove (boost::shared_ptr<ARDOUR::AutomationList>);
|
||||
void remove (boost::shared_ptr<ARDOUR::Playlist>);
|
||||
void remove (const std::list<boost::shared_ptr<ARDOUR::Playlist> >&);
|
||||
void remove (const std::list<Selectable*>&);
|
||||
void remove (Marker*);
|
||||
|
||||
void replace (uint32_t time_index, nframes_t start, nframes_t end);
|
||||
void replace (uint32_t time_index, framepos_t start, framepos_t end);
|
||||
|
||||
void clear_regions();
|
||||
void clear_tracks ();
|
||||
|
|
|
@ -268,7 +268,7 @@ SoundFileBox::setup_labels (const string& filename)
|
|||
samplerate.set_name ("NewSessionSR2Label");
|
||||
}
|
||||
|
||||
nframes_t const nfr = _session ? _session->nominal_frame_rate() : 25;
|
||||
framecnt_t const nfr = _session ? _session->nominal_frame_rate() : 25;
|
||||
double src_coef = (double) nfr / sf_info.samplerate;
|
||||
|
||||
length_clock.set (sf_info.length * src_coef + 0.5, true);
|
||||
|
@ -1128,7 +1128,7 @@ SoundFileOmega::check_info (const vector<string>& paths, bool& same_size, bool&
|
|||
}
|
||||
}
|
||||
|
||||
if ((nframes_t) info.samplerate != _session->frame_rate()) {
|
||||
if (info.samplerate != _session->frame_rate()) {
|
||||
src_needed = true;
|
||||
}
|
||||
|
||||
|
|
|
@ -158,14 +158,14 @@ StepEditor::stop_step_editing ()
|
|||
void
|
||||
StepEditor::check_step_edit ()
|
||||
{
|
||||
MidiRingBuffer<nframes_t>& incoming (_track->step_edit_ring_buffer());
|
||||
MidiRingBuffer<framepos_t>& incoming (_track->step_edit_ring_buffer());
|
||||
uint8_t* buf;
|
||||
uint32_t bufsize = 32;
|
||||
|
||||
buf = new uint8_t[bufsize];
|
||||
|
||||
while (incoming.read_space()) {
|
||||
nframes_t time;
|
||||
framepos_t time;
|
||||
Evoral::EventType type;
|
||||
uint32_t size;
|
||||
|
||||
|
|
|
@ -43,9 +43,9 @@ namespace ARDOUR {
|
|||
}
|
||||
|
||||
struct RecBoxInfo {
|
||||
ArdourCanvas::SimpleRect* rectangle;
|
||||
nframes_t start;
|
||||
nframes_t length;
|
||||
ArdourCanvas::SimpleRect* rectangle;
|
||||
framepos_t start;
|
||||
ARDOUR::framecnt_t length;
|
||||
};
|
||||
|
||||
class Selectable;
|
||||
|
@ -171,7 +171,7 @@ protected:
|
|||
double height;
|
||||
|
||||
PBD::ScopedConnectionList rec_data_ready_connections;
|
||||
nframes_t last_rec_data_frame;
|
||||
framepos_t last_rec_data_frame;
|
||||
|
||||
/* When recording, the session time at which a new layer must be created for the region
|
||||
being recorded, or max_framepos if not applicable.
|
||||
|
|
|
@ -493,13 +493,13 @@ StripSilenceDialog::update_stats (const SilenceResult& res)
|
|||
}
|
||||
}
|
||||
|
||||
nframes_t
|
||||
framecnt_t
|
||||
StripSilenceDialog::minimum_length () const
|
||||
{
|
||||
return _minimum_length.current_duration (_waves.front()->region->position());
|
||||
}
|
||||
|
||||
nframes_t
|
||||
framecnt_t
|
||||
StripSilenceDialog::fade_length () const
|
||||
{
|
||||
return _minimum_length.current_duration (_waves.front()->region->position());
|
||||
|
|
|
@ -41,8 +41,8 @@ public:
|
|||
return _threshold.get_value ();
|
||||
}
|
||||
|
||||
nframes_t minimum_length () const;
|
||||
nframes_t fade_length () const;
|
||||
ARDOUR::framecnt_t minimum_length () const;
|
||||
ARDOUR::framecnt_t fade_length () const;
|
||||
|
||||
private:
|
||||
typedef std::list<std::pair<ARDOUR::frameoffset_t,ARDOUR::framecnt_t> > SilenceResult;
|
||||
|
|
|
@ -33,7 +33,7 @@ using namespace Gtkmm2ext;
|
|||
using namespace ARDOUR;
|
||||
using namespace PBD;
|
||||
|
||||
TempoDialog::TempoDialog (TempoMap& map, nframes_t frame, const string & action)
|
||||
TempoDialog::TempoDialog (TempoMap& map, framepos_t frame, const string & action)
|
||||
: ArdourDialog (_("New Tempo")),
|
||||
bpm_adjustment (60.0, 1.0, 999.9, 0.1, 1.0),
|
||||
bpm_spinner (bpm_adjustment),
|
||||
|
@ -239,7 +239,7 @@ TempoDialog::note_types_change ()
|
|||
}
|
||||
|
||||
|
||||
MeterDialog::MeterDialog (TempoMap& map, nframes_t frame, const string & action)
|
||||
MeterDialog::MeterDialog (TempoMap& map, framepos_t frame, const string & action)
|
||||
: ArdourDialog ("New Meter"),
|
||||
ok_button (action),
|
||||
cancel_button (_("Cancel"))
|
||||
|
|
|
@ -38,7 +38,7 @@
|
|||
class TempoDialog : public ArdourDialog
|
||||
{
|
||||
public:
|
||||
TempoDialog (ARDOUR::TempoMap&, nframes_t, const std::string & action);
|
||||
TempoDialog (ARDOUR::TempoMap&, framepos_t, const std::string & action);
|
||||
TempoDialog (ARDOUR::TempoSection&, const std::string & action);
|
||||
|
||||
double get_bpm ();
|
||||
|
@ -70,7 +70,7 @@ class MeterDialog : public ArdourDialog
|
|||
{
|
||||
public:
|
||||
|
||||
MeterDialog (ARDOUR::TempoMap&, nframes_t, const std::string & action);
|
||||
MeterDialog (ARDOUR::TempoMap&, framepos_t, const std::string & action);
|
||||
MeterDialog (ARDOUR::MeterSection&, const std::string & action);
|
||||
|
||||
double get_bpb ();
|
||||
|
|
|
@ -672,7 +672,7 @@ TimeAxisView::set_samples_per_unit (double spu)
|
|||
}
|
||||
|
||||
void
|
||||
TimeAxisView::show_timestretch (nframes_t start, nframes_t end)
|
||||
TimeAxisView::show_timestretch (framepos_t start, framepos_t end)
|
||||
{
|
||||
for (Children::iterator i = children.begin(); i != children.end(); ++i) {
|
||||
(*i)->show_timestretch (start, end);
|
||||
|
@ -714,7 +714,8 @@ TimeAxisView::show_selection (TimeSelection& ts)
|
|||
selection_group->raise_to_top();
|
||||
|
||||
for (list<AudioRange>::iterator i = ts.begin(); i != ts.end(); ++i) {
|
||||
nframes_t start, end, cnt;
|
||||
framepos_t start, end;
|
||||
framecnt_t cnt;
|
||||
|
||||
start = (*i).start;
|
||||
end = (*i).end;
|
||||
|
|
|
@ -169,7 +169,7 @@ class TimeAxisView : public virtual AxisView, public PBD::Stateful
|
|||
virtual void show_selection (TimeSelection&);
|
||||
virtual void hide_selection ();
|
||||
virtual void reshow_selection (TimeSelection&);
|
||||
virtual void show_timestretch (nframes_t start, nframes_t end);
|
||||
virtual void show_timestretch (framepos_t start, framepos_t end);
|
||||
virtual void hide_timestretch ();
|
||||
|
||||
virtual void hide_dependent_views (TimeAxisViewItem&) {}
|
||||
|
@ -183,7 +183,7 @@ class TimeAxisView : public virtual AxisView, public PBD::Stateful
|
|||
virtual void set_selected_regionviews (RegionSelection&) {}
|
||||
virtual void set_selected_points (PointSelection&) {}
|
||||
|
||||
virtual boost::shared_ptr<ARDOUR::Region> find_next_region (nframes_t /*pos*/, ARDOUR::RegionPoint, int32_t /*dir*/) {
|
||||
virtual boost::shared_ptr<ARDOUR::Region> find_next_region (framepos_t /*pos*/, ARDOUR::RegionPoint, int32_t /*dir*/) {
|
||||
return boost::shared_ptr<ARDOUR::Region> ();
|
||||
}
|
||||
|
||||
|
|
|
@ -409,15 +409,15 @@ VisualTimeAxis::name_entry_key_release_handler(GdkEventKey* ev)
|
|||
// Super class methods not handled by VisualTimeAxis
|
||||
|
||||
void
|
||||
VisualTimeAxis::show_timestretch (nframes_t start, nframes_t end)
|
||||
VisualTimeAxis::show_timestretch (framepos_t start, framepos_t end)
|
||||
{
|
||||
// Not handled by purely visual TimeAxis
|
||||
// Not handled by purely visual TimeAxis
|
||||
}
|
||||
|
||||
void
|
||||
VisualTimeAxis::hide_timestretch()
|
||||
{
|
||||
// Not handled by purely visual TimeAxis
|
||||
// Not handled by purely visual TimeAxis
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -71,7 +71,7 @@ Amp::configure_io (ChanCount in, ChanCount out)
|
|||
}
|
||||
|
||||
void
|
||||
Amp::run (BufferSet& bufs, framepos_t /*start_frame*/, framepos_t /*end_frame*/, nframes_t nframes, bool)
|
||||
Amp::run (BufferSet& bufs, framepos_t /*start_frame*/, framepos_t /*end_frame*/, pframes_t nframes, bool)
|
||||
{
|
||||
if (!_active && !_pending_active) {
|
||||
return;
|
||||
|
@ -85,7 +85,7 @@ Amp::run (BufferSet& bufs, framepos_t /*start_frame*/, framepos_t /*end_frame*/,
|
|||
|
||||
for (BufferSet::audio_iterator i = bufs.audio_begin(); i != bufs.audio_end(); ++i) {
|
||||
Sample* const sp = i->data();
|
||||
for (nframes_t nx = 0; nx < nframes; ++nx) {
|
||||
for (pframes_t nx = 0; nx < nframes; ++nx) {
|
||||
sp[nx] *= gab[nx];
|
||||
}
|
||||
}
|
||||
|
@ -129,7 +129,7 @@ Amp::run (BufferSet& bufs, framepos_t /*start_frame*/, framepos_t /*end_frame*/,
|
|||
}
|
||||
|
||||
void
|
||||
Amp::apply_gain (BufferSet& bufs, nframes_t nframes, gain_t initial, gain_t target)
|
||||
Amp::apply_gain (BufferSet& bufs, framecnt_t nframes, gain_t initial, gain_t target)
|
||||
{
|
||||
/** Apply a (potentially) declicked gain to the buffers of @a bufs
|
||||
*/
|
||||
|
@ -144,7 +144,7 @@ Amp::apply_gain (BufferSet& bufs, nframes_t nframes, gain_t initial, gain_t targ
|
|||
return;
|
||||
}
|
||||
|
||||
const nframes_t declick = std::min ((nframes_t)128, nframes);
|
||||
const framecnt_t declick = std::min ((framecnt_t) 128, nframes);
|
||||
gain_t delta;
|
||||
double fractional_shift = -1.0/declick;
|
||||
double fractional_pos;
|
||||
|
@ -180,7 +180,7 @@ Amp::apply_gain (BufferSet& bufs, nframes_t nframes, gain_t initial, gain_t targ
|
|||
|
||||
fractional_pos = 1.0;
|
||||
|
||||
for (nframes_t nx = 0; nx < declick; ++nx) {
|
||||
for (pframes_t nx = 0; nx < declick; ++nx) {
|
||||
buffer[nx] *= (initial + (delta * (0.5 + 0.5 * cos (M_PI * fractional_pos))));
|
||||
fractional_pos += fractional_shift;
|
||||
}
|
||||
|
@ -199,7 +199,7 @@ Amp::apply_gain (BufferSet& bufs, nframes_t nframes, gain_t initial, gain_t targ
|
|||
}
|
||||
|
||||
void
|
||||
Amp::declick (BufferSet& bufs, nframes_t nframes, int dir)
|
||||
Amp::declick (BufferSet& bufs, framecnt_t nframes, int dir)
|
||||
{
|
||||
/* Almost exactly like ::apply_gain() but skips MIDI buffers and has fixed initial+target
|
||||
values.
|
||||
|
@ -209,7 +209,7 @@ Amp::declick (BufferSet& bufs, nframes_t nframes, int dir)
|
|||
return;
|
||||
}
|
||||
|
||||
const nframes_t declick = std::min ((nframes_t)128, nframes);
|
||||
const framecnt_t declick = std::min ((framecnt_t) 128, nframes);
|
||||
gain_t delta, initial, target;
|
||||
double fractional_shift = -1.0/declick;
|
||||
double fractional_pos;
|
||||
|
@ -233,7 +233,7 @@ Amp::declick (BufferSet& bufs, nframes_t nframes, int dir)
|
|||
|
||||
fractional_pos = 1.0;
|
||||
|
||||
for (nframes_t nx = 0; nx < declick; ++nx) {
|
||||
for (pframes_t nx = 0; nx < declick; ++nx) {
|
||||
buffer[nx] *= (initial + (delta * (0.5 + 0.5 * cos (M_PI * fractional_pos))));
|
||||
fractional_pos += fractional_shift;
|
||||
}
|
||||
|
@ -252,7 +252,7 @@ Amp::declick (BufferSet& bufs, nframes_t nframes, int dir)
|
|||
}
|
||||
|
||||
void
|
||||
Amp::apply_gain (AudioBuffer& buf, nframes_t nframes, gain_t initial, gain_t target)
|
||||
Amp::apply_gain (AudioBuffer& buf, framecnt_t nframes, gain_t initial, gain_t target)
|
||||
{
|
||||
/** Apply a (potentially) declicked gain to the contents of @a buf
|
||||
*/
|
||||
|
@ -267,7 +267,7 @@ Amp::apply_gain (AudioBuffer& buf, nframes_t nframes, gain_t initial, gain_t tar
|
|||
return;
|
||||
}
|
||||
|
||||
const nframes_t declick = std::min ((nframes_t)128, nframes);
|
||||
const framecnt_t declick = std::min ((framecnt_t) 128, nframes);
|
||||
gain_t delta;
|
||||
double fractional_shift = -1.0/declick;
|
||||
double fractional_pos;
|
||||
|
@ -285,7 +285,7 @@ Amp::apply_gain (AudioBuffer& buf, nframes_t nframes, gain_t initial, gain_t tar
|
|||
|
||||
fractional_pos = 1.0;
|
||||
|
||||
for (nframes_t nx = 0; nx < declick; ++nx) {
|
||||
for (pframes_t nx = 0; nx < declick; ++nx) {
|
||||
buffer[nx] *= (initial + (delta * (0.5 + 0.5 * cos (M_PI * fractional_pos))));
|
||||
fractional_pos += fractional_shift;
|
||||
}
|
||||
|
@ -303,7 +303,7 @@ Amp::apply_gain (AudioBuffer& buf, nframes_t nframes, gain_t initial, gain_t tar
|
|||
}
|
||||
|
||||
void
|
||||
Amp::apply_simple_gain (BufferSet& bufs, nframes_t nframes, gain_t target)
|
||||
Amp::apply_simple_gain (BufferSet& bufs, framecnt_t nframes, gain_t target)
|
||||
{
|
||||
if (target == 0.0) {
|
||||
|
||||
|
@ -342,7 +342,7 @@ Amp::apply_simple_gain (BufferSet& bufs, nframes_t nframes, gain_t target)
|
|||
}
|
||||
|
||||
void
|
||||
Amp::apply_simple_gain (AudioBuffer& buf, nframes_t nframes, gain_t target)
|
||||
Amp::apply_simple_gain (AudioBuffer& buf, framecnt_t nframes, gain_t target)
|
||||
{
|
||||
if (target == 0.0) {
|
||||
memset (buf.data(), 0, sizeof (Sample) * nframes);
|
||||
|
@ -412,8 +412,9 @@ void
|
|||
Amp::GainControl::set_value (double val)
|
||||
{
|
||||
// max gain at about +6dB (10.0 ^ ( 6 dB * 0.05))
|
||||
if (val > 1.99526231f)
|
||||
if (val > 1.99526231f) {
|
||||
val = 1.99526231f;
|
||||
}
|
||||
|
||||
_amp->set_gain (val, this);
|
||||
|
||||
|
@ -427,7 +428,7 @@ Amp::GainControl::get_value (void) const
|
|||
}
|
||||
|
||||
void
|
||||
Amp::setup_gain_automation (framepos_t start_frame, framepos_t end_frame, nframes_t nframes)
|
||||
Amp::setup_gain_automation (framepos_t start_frame, framepos_t end_frame, framecnt_t nframes)
|
||||
{
|
||||
Glib::Mutex::Lock am (control_lock(), Glib::TRY_LOCK);
|
||||
|
||||
|
|
|
@ -43,12 +43,12 @@ public:
|
|||
bool can_support_io_configuration (const ChanCount& in, ChanCount& out) const;
|
||||
bool configure_io (ChanCount in, ChanCount out);
|
||||
|
||||
void run (BufferSet& bufs, framepos_t start_frame, framepos_t end_frame, nframes_t nframes, bool);
|
||||
void run (BufferSet& bufs, framepos_t start_frame, framepos_t end_frame, pframes_t nframes, bool);
|
||||
|
||||
bool apply_gain() const { return _apply_gain; }
|
||||
void apply_gain(bool yn) { _apply_gain = yn; }
|
||||
bool apply_gain () const { return _apply_gain; }
|
||||
void apply_gain (bool yn) { _apply_gain = yn; }
|
||||
|
||||
void setup_gain_automation (framepos_t start_frame, framepos_t end_frame, nframes_t nframes);
|
||||
void setup_gain_automation (framepos_t start_frame, framepos_t end_frame, framecnt_t nframes);
|
||||
|
||||
bool apply_gain_automation() const { return _apply_gain_automation; }
|
||||
void apply_gain_automation(bool yn) { _apply_gain_automation = yn; }
|
||||
|
@ -56,13 +56,13 @@ public:
|
|||
XMLNode& state (bool full);
|
||||
int set_state (const XMLNode&, int version);
|
||||
|
||||
static void apply_gain (BufferSet& bufs, nframes_t nframes, gain_t initial, gain_t target);
|
||||
static void apply_simple_gain(BufferSet& bufs, nframes_t nframes, gain_t target);
|
||||
static void apply_gain (BufferSet& bufs, framecnt_t nframes, gain_t initial, gain_t target);
|
||||
static void apply_simple_gain(BufferSet& bufs, framecnt_t nframes, gain_t target);
|
||||
|
||||
static void apply_gain (AudioBuffer& buf, nframes_t nframes, gain_t initial, gain_t target);
|
||||
static void apply_simple_gain(AudioBuffer& buf, nframes_t nframes, gain_t target);
|
||||
static void apply_gain (AudioBuffer& buf, framecnt_t nframes, gain_t initial, gain_t target);
|
||||
static void apply_simple_gain(AudioBuffer& buf, framecnt_t nframes, gain_t target);
|
||||
|
||||
static void declick (BufferSet& bufs, nframes_t nframes, int dir);
|
||||
static void declick (BufferSet& bufs, framecnt_t nframes, int dir);
|
||||
|
||||
gain_t gain () const { return _gain_control->user_double(); }
|
||||
|
||||
|
|
|
@ -30,7 +30,7 @@ public:
|
|||
AudioBuffer(size_t capacity);
|
||||
~AudioBuffer();
|
||||
|
||||
void silence (nframes_t len, nframes_t offset = 0) {
|
||||
void silence (framecnt_t len, framecnt_t offset = 0) {
|
||||
if (!_silent) {
|
||||
assert(_capacity > 0);
|
||||
assert(offset + len <= _capacity);
|
||||
|
@ -43,7 +43,7 @@ public:
|
|||
}
|
||||
|
||||
/** Read @a len frames @a src starting at @a src_offset into self starting at @ dst_offset*/
|
||||
void read_from (const Buffer& src, nframes_t len, nframes_t dst_offset = 0, nframes_t src_offset = 0) {
|
||||
void read_from (const Buffer& src, framecnt_t len, framecnt_t dst_offset = 0, framecnt_t src_offset = 0) {
|
||||
assert(&src != this);
|
||||
assert(_capacity > 0);
|
||||
assert(src.type() == DataType::AUDIO);
|
||||
|
@ -58,14 +58,14 @@ public:
|
|||
}
|
||||
|
||||
/** Acumulate (add) @a len frames @a src starting at @a src_offset into self starting at @ dst_offset*/
|
||||
void merge_from (const Buffer& src, nframes_t len, nframes_t dst_offset = 0, nframes_t src_offset = 0) {
|
||||
void merge_from (const Buffer& src, framecnt_t len, framecnt_t dst_offset = 0, framecnt_t src_offset = 0) {
|
||||
const AudioBuffer* ab = dynamic_cast<const AudioBuffer*>(&src);
|
||||
assert (ab);
|
||||
accumulate_from (*ab, len, dst_offset, src_offset);
|
||||
}
|
||||
|
||||
/** Acumulate (add) @a len frames @a src starting at @a src_offset into self starting at @ dst_offset*/
|
||||
void accumulate_from (const AudioBuffer& src, nframes_t len, nframes_t dst_offset = 0, nframes_t src_offset = 0) {
|
||||
void accumulate_from (const AudioBuffer& src, framecnt_t len, framecnt_t dst_offset = 0, framecnt_t src_offset = 0) {
|
||||
assert(_capacity > 0);
|
||||
assert(len <= _capacity);
|
||||
|
||||
|
@ -80,7 +80,7 @@ public:
|
|||
|
||||
/** Acumulate (add) @a len frames @a src starting at @a src_offset into self starting at @ dst_offset
|
||||
* scaling by @a gain_coeff */
|
||||
void accumulate_with_gain_from (const AudioBuffer& src, nframes_t len, gain_t gain_coeff, nframes_t dst_offset = 0, nframes_t src_offset = 0) {
|
||||
void accumulate_with_gain_from (const AudioBuffer& src, framecnt_t len, gain_t gain_coeff, framecnt_t dst_offset = 0, framecnt_t src_offset = 0) {
|
||||
|
||||
assert(_capacity > 0);
|
||||
assert(len <= _capacity);
|
||||
|
@ -100,7 +100,7 @@ public:
|
|||
|
||||
/** Accumulate (add) @a len frames FROM THE START OF @a src into self
|
||||
* scaling by @a gain_coeff */
|
||||
void accumulate_with_gain_from (const Sample* src_raw, nframes_t len, gain_t gain_coeff, nframes_t dst_offset = 0) {
|
||||
void accumulate_with_gain_from (const Sample* src_raw, framecnt_t len, gain_t gain_coeff, framecnt_t dst_offset = 0) {
|
||||
|
||||
assert(_capacity > 0);
|
||||
assert(len <= _capacity);
|
||||
|
@ -113,7 +113,7 @@ public:
|
|||
_written = true;
|
||||
}
|
||||
|
||||
void apply_gain (gain_t gain, nframes_t len) {
|
||||
void apply_gain (gain_t gain, framecnt_t len) {
|
||||
apply_gain_to_buffer (_data, len, gain);
|
||||
}
|
||||
|
||||
|
@ -137,12 +137,12 @@ public:
|
|||
void resize (size_t nframes);
|
||||
|
||||
|
||||
const Sample* data (nframes_t offset = 0) const {
|
||||
const Sample* data (framecnt_t offset = 0) const {
|
||||
assert(offset <= _capacity);
|
||||
return _data + offset;
|
||||
}
|
||||
|
||||
Sample* data (nframes_t offset = 0) {
|
||||
Sample* data (framecnt_t offset = 0) {
|
||||
assert(offset <= _capacity);
|
||||
return _data + offset;
|
||||
}
|
||||
|
|
|
@ -139,7 +139,7 @@ class AudioDiskstream : public Diskstream
|
|||
}
|
||||
}
|
||||
|
||||
static void swap_by_ptr (Sample *first, Sample *last, nframes_t n) {
|
||||
static void swap_by_ptr (Sample *first, Sample *last, framecnt_t n) {
|
||||
while (n--) {
|
||||
Sample tmp = *first;
|
||||
*first++ = *last;
|
||||
|
@ -161,7 +161,7 @@ class AudioDiskstream : public Diskstream
|
|||
|
||||
void set_pending_overwrite(bool);
|
||||
int overwrite_existing_buffers ();
|
||||
void set_block_size (nframes_t);
|
||||
void set_block_size (pframes_t);
|
||||
int internal_playback_seek (framecnt_t distance);
|
||||
int can_internal_playback_seek (framecnt_t distance);
|
||||
int rename_write_sources ();
|
||||
|
@ -177,17 +177,17 @@ class AudioDiskstream : public Diskstream
|
|||
protected:
|
||||
friend class AudioTrack;
|
||||
|
||||
int process (framepos_t transport_frame, nframes_t nframes, bool can_record, bool rec_monitors_input, bool& need_butler);
|
||||
bool commit (nframes_t nframes);
|
||||
int process (framepos_t transport_frame, pframes_t nframes, bool can_record, bool rec_monitors_input, bool& need_butler);
|
||||
bool commit (framecnt_t nframes);
|
||||
|
||||
private:
|
||||
|
||||
struct ChannelInfo : public boost::noncopyable {
|
||||
|
||||
ChannelInfo (nframes_t playback_buffer_size,
|
||||
nframes_t capture_buffer_size,
|
||||
nframes_t speed_buffer_size,
|
||||
nframes_t wrap_buffer_size);
|
||||
ChannelInfo (framecnt_t playback_buffer_size,
|
||||
framecnt_t capture_buffer_size,
|
||||
framecnt_t speed_buffer_size,
|
||||
framecnt_t wrap_buffer_size);
|
||||
~ChannelInfo ();
|
||||
|
||||
Sample *playback_wrap_buffer;
|
||||
|
@ -216,15 +216,15 @@ class AudioDiskstream : public Diskstream
|
|||
|
||||
RingBufferNPT<CaptureTransition> * capture_transition_buf;
|
||||
// the following are used in the butler thread only
|
||||
nframes_t curr_capture_cnt;
|
||||
framecnt_t curr_capture_cnt;
|
||||
|
||||
void resize_playback (nframes_t);
|
||||
void resize_capture (nframes_t);
|
||||
void resize_playback (framecnt_t);
|
||||
void resize_capture (framecnt_t);
|
||||
};
|
||||
|
||||
typedef std::vector<ChannelInfo*> ChannelList;
|
||||
|
||||
void process_varispeed_playback(nframes_t nframes, boost::shared_ptr<ChannelList> c);
|
||||
void process_varispeed_playback (pframes_t nframes, boost::shared_ptr<ChannelList> c);
|
||||
|
||||
/* The two central butler operations */
|
||||
int do_flush (RunContext context, bool force = false);
|
||||
|
@ -233,7 +233,7 @@ class AudioDiskstream : public Diskstream
|
|||
int do_refill_with_alloc ();
|
||||
|
||||
int read (Sample* buf, Sample* mixdown_buffer, float* gain_buffer,
|
||||
framepos_t& start, nframes_t cnt,
|
||||
framepos_t& start, framecnt_t cnt,
|
||||
ChannelInfo* channel_info, int channel, bool reversed);
|
||||
|
||||
void finish_capture (bool rec_monitors_input, boost::shared_ptr<ChannelList>);
|
||||
|
|
|
@ -35,25 +35,25 @@ class AudioPort : public Port
|
|||
return DataType::AUDIO;
|
||||
}
|
||||
|
||||
void cycle_start (nframes_t);
|
||||
void cycle_end (nframes_t);
|
||||
void cycle_start (pframes_t);
|
||||
void cycle_end (pframes_t);
|
||||
void cycle_split ();
|
||||
|
||||
size_t raw_buffer_size(jack_nframes_t nframes) const;
|
||||
size_t raw_buffer_size (pframes_t nframes) const;
|
||||
|
||||
Buffer& get_buffer (nframes_t nframes, nframes_t offset = 0) {
|
||||
Buffer& get_buffer (framecnt_t nframes, framecnt_t offset = 0) {
|
||||
return get_audio_buffer (nframes, offset);
|
||||
}
|
||||
|
||||
AudioBuffer& get_audio_buffer (nframes_t nframes, nframes_t offset = 0);
|
||||
AudioBuffer& get_audio_buffer (framecnt_t nframes, framecnt_t offset = 0);
|
||||
|
||||
static nframes_t port_offset() { return _port_offset; }
|
||||
static framecnt_t port_offset() { return _port_offset; }
|
||||
|
||||
static void set_port_offset (nframes_t off) {
|
||||
static void set_port_offset (framecnt_t off) {
|
||||
_port_offset = off;
|
||||
}
|
||||
|
||||
static void increment_port_offset (nframes_t n) {
|
||||
static void increment_port_offset (framecnt_t n) {
|
||||
_port_offset += n;
|
||||
}
|
||||
|
||||
|
@ -65,7 +65,7 @@ class AudioPort : public Port
|
|||
private:
|
||||
AudioBuffer* _buffer;
|
||||
|
||||
static nframes_t _port_offset;
|
||||
static framecnt_t _port_offset;
|
||||
};
|
||||
|
||||
} // namespace ARDOUR
|
||||
|
|
|
@ -39,7 +39,7 @@ class AudioTrack : public Track
|
|||
int set_mode (TrackMode m);
|
||||
bool can_use_mode (TrackMode m, bool& bounce_required);
|
||||
|
||||
int roll (nframes_t nframes, framepos_t start_frame, framepos_t end_frame,
|
||||
int roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
|
||||
int declick, bool can_record, bool rec_monitors_input, bool& need_butler);
|
||||
|
||||
void use_new_diskstream ();
|
||||
|
@ -55,7 +55,7 @@ class AudioTrack : public Track
|
|||
void unfreeze ();
|
||||
|
||||
boost::shared_ptr<Region> bounce (InterThreadInfo&);
|
||||
boost::shared_ptr<Region> bounce_range (nframes_t start, nframes_t end, InterThreadInfo&, bool enable_processing);
|
||||
boost::shared_ptr<Region> bounce_range (framepos_t start, framepos_t end, InterThreadInfo&, bool enable_processing);
|
||||
|
||||
int set_state(const XMLNode&, int version);
|
||||
|
||||
|
|
|
@ -71,7 +71,7 @@ class AUPlugin : public ARDOUR::Plugin
|
|||
const char * maker () const { return _info->creator.c_str(); }
|
||||
uint32_t parameter_count () const;
|
||||
float default_value (uint32_t port);
|
||||
nframes_t signal_latency() const;
|
||||
framecnt_t signal_latency() const;
|
||||
void set_parameter (uint32_t which, float val);
|
||||
float get_parameter (uint32_t which) const;
|
||||
|
||||
|
@ -80,11 +80,11 @@ class AUPlugin : public ARDOUR::Plugin
|
|||
void activate ();
|
||||
void deactivate ();
|
||||
void flush ();
|
||||
int set_block_size (nframes_t nframes);
|
||||
int set_block_size (pframes_t nframes);
|
||||
|
||||
int connect_and_run (BufferSet& bufs,
|
||||
ChanMapping in, ChanMapping out,
|
||||
nframes_t nframes, nframes_t offset);
|
||||
pframes_t nframes, framecnt_t offset);
|
||||
std::set<Evoral::Parameter> automatable() const;
|
||||
std::string describe_parameter (Evoral::Parameter);
|
||||
std::string state_node_name () const { return "audiounit"; }
|
||||
|
@ -150,8 +150,8 @@ class AUPlugin : public ARDOUR::Plugin
|
|||
int32_t input_channels;
|
||||
int32_t output_channels;
|
||||
std::vector<std::pair<int,int> > io_configs;
|
||||
nframes_t _current_block_size;
|
||||
nframes_t _last_nframes;
|
||||
pframes_t _current_block_size;
|
||||
framecnt_t _last_nframes;
|
||||
bool _requires_fixed_size_buffers;
|
||||
AudioBufferList* buffers;
|
||||
bool _has_midi_input;
|
||||
|
@ -181,10 +181,10 @@ class AUPlugin : public ARDOUR::Plugin
|
|||
|
||||
std::vector<std::pair<uint32_t, uint32_t> > parameter_map;
|
||||
uint32_t current_maxbuf;
|
||||
nframes_t current_offset;
|
||||
nframes_t cb_offset;
|
||||
framecnt_t current_offset;
|
||||
framecnt_t cb_offset;
|
||||
BufferSet* current_buffers;
|
||||
nframes_t frames_processed;
|
||||
framecnt_t frames_processed;
|
||||
|
||||
std::vector<AUParameterDescriptor> descriptors;
|
||||
void init ();
|
||||
|
|
|
@ -56,8 +56,8 @@ class AudioAnalyser : public boost::noncopyable {
|
|||
AnalysisPlugin* plugin;
|
||||
AnalysisPluginKey plugin_key;
|
||||
|
||||
nframes_t bufsize;
|
||||
nframes_t stepsize;
|
||||
framecnt_t bufsize;
|
||||
framecnt_t stepsize;
|
||||
|
||||
int initialize_plugin (AnalysisPluginKey name, float sample_rate);
|
||||
int analyse (const std::string& path, Readable*, uint32_t channel);
|
||||
|
|
|
@ -91,46 +91,57 @@ class AudioEngine : public SessionHandlePtr
|
|||
|
||||
Glib::Mutex& process_lock() { return _process_lock; }
|
||||
|
||||
nframes_t frame_rate() const;
|
||||
nframes_t frames_per_cycle() const;
|
||||
framecnt_t frame_rate () const;
|
||||
framecnt_t frames_per_cycle () const;
|
||||
|
||||
size_t raw_buffer_size(DataType t);
|
||||
|
||||
int usecs_per_cycle () const { return _usecs_per_cycle; }
|
||||
|
||||
bool get_sync_offset (nframes_t& offset) const;
|
||||
bool get_sync_offset (pframes_t & offset) const;
|
||||
|
||||
nframes_t frames_since_cycle_start () {
|
||||
pframes_t frames_since_cycle_start () {
|
||||
jack_client_t* _priv_jack = _jack;
|
||||
if (!_running || !_priv_jack) return 0;
|
||||
if (!_running || !_priv_jack) {
|
||||
return 0;
|
||||
}
|
||||
return jack_frames_since_cycle_start (_priv_jack);
|
||||
}
|
||||
nframes_t frame_time () {
|
||||
|
||||
pframes_t frame_time () {
|
||||
jack_client_t* _priv_jack = _jack;
|
||||
if (!_running || !_priv_jack) return 0;
|
||||
if (!_running || !_priv_jack) {
|
||||
return 0;
|
||||
}
|
||||
return jack_frame_time (_priv_jack);
|
||||
}
|
||||
|
||||
nframes_t frame_time_at_cycle_start () {
|
||||
pframes_t frame_time_at_cycle_start () {
|
||||
jack_client_t* _priv_jack = _jack;
|
||||
if (!_running || !_priv_jack) return 0;
|
||||
if (!_running || !_priv_jack) {
|
||||
return 0;
|
||||
}
|
||||
return jack_last_frame_time (_priv_jack);
|
||||
}
|
||||
|
||||
nframes_t transport_frame () const {
|
||||
pframes_t transport_frame () const {
|
||||
const jack_client_t* _priv_jack = _jack;
|
||||
if (!_running || !_priv_jack) return 0;
|
||||
if (!_running || !_priv_jack) {
|
||||
return 0;
|
||||
}
|
||||
return jack_get_current_transport_frame (_priv_jack);
|
||||
}
|
||||
|
||||
int request_buffer_size (nframes_t);
|
||||
int request_buffer_size (pframes_t);
|
||||
|
||||
nframes_t set_monitor_check_interval (nframes_t);
|
||||
nframes_t processed_frames() const { return _processed_frames; }
|
||||
framecnt_t set_monitor_check_interval (framecnt_t);
|
||||
framecnt_t processed_frames() const { return _processed_frames; }
|
||||
|
||||
float get_cpu_load() {
|
||||
jack_client_t* _priv_jack = _jack;
|
||||
if (!_running || !_priv_jack) return 0;
|
||||
if (!_running || !_priv_jack) {
|
||||
return 0;
|
||||
}
|
||||
return jack_cpu_load (_priv_jack);
|
||||
}
|
||||
|
||||
|
@ -159,7 +170,7 @@ class AudioEngine : public SessionHandlePtr
|
|||
Port *register_output_port (DataType, const std::string& portname);
|
||||
int unregister_port (Port &);
|
||||
|
||||
void split_cycle (nframes_t offset);
|
||||
void split_cycle (pframes_t offset);
|
||||
|
||||
int connect (const std::string& source, const std::string& destination);
|
||||
int disconnect (const std::string& source, const std::string& destination);
|
||||
|
@ -189,7 +200,7 @@ class AudioEngine : public SessionHandlePtr
|
|||
|
||||
void transport_start ();
|
||||
void transport_stop ();
|
||||
void transport_locate (nframes_t);
|
||||
void transport_locate (framepos_t);
|
||||
TransportState transport_state ();
|
||||
|
||||
int reset_timebase ();
|
||||
|
@ -203,7 +214,7 @@ class AudioEngine : public SessionHandlePtr
|
|||
_ the regular process() call to session->process() is not made.
|
||||
*/
|
||||
|
||||
PBD::Signal1<int,nframes_t> Freewheel;
|
||||
PBD::Signal1<int, pframes_t> Freewheel;
|
||||
|
||||
PBD::Signal0<void> Xrun;
|
||||
|
||||
|
@ -218,7 +229,7 @@ _ the regular process() call to session->process() is not made.
|
|||
|
||||
/* this signal is emitted if the sample rate changes */
|
||||
|
||||
PBD::Signal1<void,nframes_t> SampleRateChanged;
|
||||
PBD::Signal1<void, framecnt_t> SampleRateChanged;
|
||||
|
||||
/* this signal is sent if JACK ever disconnects us */
|
||||
|
||||
|
@ -255,18 +266,18 @@ _ the regular process() call to session->process() is not made.
|
|||
bool session_remove_pending;
|
||||
bool _running;
|
||||
bool _has_run;
|
||||
mutable nframes_t _buffer_size;
|
||||
mutable framecnt_t _buffer_size;
|
||||
std::map<DataType,size_t> _raw_buffer_sizes;
|
||||
mutable nframes_t _frame_rate;
|
||||
mutable framecnt_t _frame_rate;
|
||||
/// number of frames between each check for changes in monitor input
|
||||
nframes_t monitor_check_interval;
|
||||
framecnt_t monitor_check_interval;
|
||||
/// time of the last monitor check in frames
|
||||
nframes_t last_monitor_check;
|
||||
framecnt_t last_monitor_check;
|
||||
/// the number of frames processed since start() was called
|
||||
nframes_t _processed_frames;
|
||||
framecnt_t _processed_frames;
|
||||
bool _freewheeling;
|
||||
bool _freewheel_pending;
|
||||
boost::function<int(nframes_t)> freewheel_action;
|
||||
boost::function<int(framecnt_t)> freewheel_action;
|
||||
bool reconnect_on_halt;
|
||||
int _usecs_per_cycle;
|
||||
|
||||
|
@ -274,7 +285,7 @@ _ the regular process() call to session->process() is not made.
|
|||
|
||||
Port *register_port (DataType type, const std::string& portname, bool input);
|
||||
|
||||
int process_callback (nframes_t nframes);
|
||||
int process_callback (pframes_t nframes);
|
||||
void* process_thread ();
|
||||
void finish_process_cycle (int status);
|
||||
void remove_all_ports ();
|
||||
|
@ -289,20 +300,20 @@ _ the regular process() call to session->process() is not made.
|
|||
static void _session_callback (jack_session_event_t *event, void *arg);
|
||||
#endif
|
||||
static int _graph_order_callback (void *arg);
|
||||
static int _process_callback (nframes_t nframes, void *arg);
|
||||
static int _process_callback (pframes_t nframes, void *arg);
|
||||
static void* _process_thread (void *arg);
|
||||
static int _sample_rate_callback (nframes_t nframes, void *arg);
|
||||
static int _bufsize_callback (nframes_t nframes, void *arg);
|
||||
static void _jack_timebase_callback (jack_transport_state_t, nframes_t, jack_position_t*, int, void*);
|
||||
static int _sample_rate_callback (pframes_t nframes, void *arg);
|
||||
static int _bufsize_callback (pframes_t nframes, void *arg);
|
||||
static void _jack_timebase_callback (jack_transport_state_t, pframes_t, jack_position_t*, int, void*);
|
||||
static int _jack_sync_callback (jack_transport_state_t, jack_position_t*, void *arg);
|
||||
static void _freewheel_callback (int , void *arg);
|
||||
static void _registration_callback (jack_port_id_t, int, void *);
|
||||
static void _connect_callback (jack_port_id_t, jack_port_id_t, int, void *);
|
||||
|
||||
void jack_timebase_callback (jack_transport_state_t, nframes_t, jack_position_t*, int);
|
||||
void jack_timebase_callback (jack_transport_state_t, pframes_t, jack_position_t*, int);
|
||||
int jack_sync_callback (jack_transport_state_t, jack_position_t*);
|
||||
int jack_bufsize_callback (nframes_t);
|
||||
int jack_sample_rate_callback (nframes_t);
|
||||
int jack_bufsize_callback (pframes_t);
|
||||
int jack_sample_rate_callback (pframes_t);
|
||||
|
||||
int connect_to_jack (std::string client_name, std::string session_uuid);
|
||||
|
||||
|
|
|
@ -82,7 +82,7 @@ public:
|
|||
static bool is_empty (Session&, std::string path);
|
||||
|
||||
static void set_bwf_serial_number (int);
|
||||
static void set_header_position_offset (nframes_t offset );
|
||||
static void set_header_position_offset (framecnt_t offset);
|
||||
|
||||
static PBD::Signal0<void> HeaderPositionOffsetChanged;
|
||||
|
||||
|
@ -104,7 +104,7 @@ protected:
|
|||
|
||||
int move_dependents_to_trash();
|
||||
|
||||
static Sample* get_interleave_buffer (nframes_t size);
|
||||
static Sample* get_interleave_buffer (framecnt_t size);
|
||||
|
||||
static std::string peak_dir;
|
||||
|
||||
|
|
|
@ -72,7 +72,7 @@ public:
|
|||
AudioPlaylist (Session&, const XMLNode&, bool hidden = false);
|
||||
AudioPlaylist (Session&, std::string name, bool hidden = false);
|
||||
AudioPlaylist (boost::shared_ptr<const AudioPlaylist>, std::string name, bool hidden = false);
|
||||
AudioPlaylist (boost::shared_ptr<const AudioPlaylist>, nframes_t start, nframes_t cnt, std::string name, bool hidden = false);
|
||||
AudioPlaylist (boost::shared_ptr<const AudioPlaylist>, framepos_t start, framecnt_t cnt, std::string name, bool hidden = false);
|
||||
|
||||
~AudioPlaylist ();
|
||||
|
||||
|
@ -85,7 +85,7 @@ public:
|
|||
PBD::Signal1<void,boost::shared_ptr<Crossfade> > NewCrossfade;
|
||||
|
||||
void foreach_crossfade (boost::function<void (boost::shared_ptr<Crossfade>)>);
|
||||
void crossfades_at (nframes_t frame, Crossfades&);
|
||||
void crossfades_at (framepos_t frame, Crossfades&);
|
||||
|
||||
bool destroy_region (boost::shared_ptr<Region>);
|
||||
|
||||
|
|
|
@ -93,8 +93,8 @@ class AudioRegion : public Region
|
|||
boost::shared_ptr<AutomationList> fade_out() { return _fade_out; }
|
||||
boost::shared_ptr<AutomationList> envelope() { return _envelope; }
|
||||
|
||||
virtual nframes_t read_peaks (PeakData *buf, nframes_t npeaks,
|
||||
nframes_t offset, nframes_t cnt,
|
||||
virtual framecnt_t read_peaks (PeakData *buf, framecnt_t npeaks,
|
||||
framecnt_t offset, framecnt_t cnt,
|
||||
uint32_t chan_n=0, double samples_per_unit= 1.0) const;
|
||||
|
||||
/* Readable interface */
|
||||
|
|
|
@ -69,7 +69,7 @@ class AudioSource : virtual public Source,
|
|||
|
||||
uint32_t read_data_count() const { return _read_data_count; }
|
||||
uint32_t write_data_count() const { return _write_data_count; }
|
||||
void dec_read_data_count(nframes_t);
|
||||
void dec_read_data_count (framecnt_t);
|
||||
|
||||
int read_peaks (PeakData *peaks, framecnt_t npeaks,
|
||||
framepos_t start, framecnt_t cnt, double samples_per_visual_peak) const;
|
||||
|
|
|
@ -46,7 +46,7 @@ class Auditioner : public AudioTrack
|
|||
ARDOUR::AudioPlaylist& prepare_playlist ();
|
||||
void audition_current_playlist ();
|
||||
|
||||
int play_audition (nframes_t nframes);
|
||||
int play_audition (framecnt_t nframes);
|
||||
|
||||
void cancel_audition () {
|
||||
g_atomic_int_set (&_auditioning, 0);
|
||||
|
@ -57,10 +57,10 @@ class Auditioner : public AudioTrack
|
|||
|
||||
private:
|
||||
boost::shared_ptr<AudioRegion> the_region;
|
||||
nframes_t current_frame;
|
||||
framepos_t current_frame;
|
||||
mutable gint _auditioning;
|
||||
Glib::Mutex lock;
|
||||
nframes_t length;
|
||||
framecnt_t length;
|
||||
bool via_monitor;
|
||||
|
||||
void drop_ports ();
|
||||
|
|
|
@ -60,7 +60,7 @@ public:
|
|||
virtual void add_control(boost::shared_ptr<Evoral::Control>);
|
||||
void clear_controls ();
|
||||
|
||||
virtual void automation_snapshot(nframes_t now, bool force);
|
||||
virtual void automation_snapshot (framepos_t now, bool force);
|
||||
virtual void transport_stopped (framepos_t now);
|
||||
|
||||
virtual std::string describe_parameter(Evoral::Parameter param);
|
||||
|
@ -78,16 +78,16 @@ public:
|
|||
|
||||
void mark_automation_visible(Evoral::Parameter, bool);
|
||||
|
||||
inline bool should_snapshot (nframes_t now) {
|
||||
inline bool should_snapshot (framepos_t now) {
|
||||
return (_last_automation_snapshot > now
|
||||
|| (now - _last_automation_snapshot) > _automation_interval);
|
||||
}
|
||||
|
||||
static void set_automation_interval (jack_nframes_t frames) {
|
||||
static void set_automation_interval (framecnt_t frames) {
|
||||
_automation_interval = frames;
|
||||
}
|
||||
|
||||
static jack_nframes_t automation_interval() {
|
||||
static framecnt_t automation_interval() {
|
||||
return _automation_interval;
|
||||
}
|
||||
|
||||
|
@ -109,8 +109,8 @@ public:
|
|||
std::set<Evoral::Parameter> _visible_controls;
|
||||
std::set<Evoral::Parameter> _can_automate_list;
|
||||
|
||||
nframes_t _last_automation_snapshot;
|
||||
static nframes_t _automation_interval;
|
||||
framepos_t _last_automation_snapshot;
|
||||
static framecnt_t _automation_interval;
|
||||
|
||||
private:
|
||||
PBD::ScopedConnectionList _control_connections; ///< connections to our controls' signals
|
||||
|
|
|
@ -71,13 +71,13 @@ public:
|
|||
virtual void resize (size_t) = 0;
|
||||
|
||||
/** Clear (eg zero, or empty) buffer */
|
||||
virtual void silence (nframes_t len, nframes_t offset = 0) = 0;
|
||||
virtual void silence (framecnt_t len, framecnt_t offset = 0) = 0;
|
||||
|
||||
/** Clear the entire buffer */
|
||||
virtual void clear() { silence(_capacity, 0); }
|
||||
|
||||
virtual void read_from (const Buffer& src, nframes_t len, nframes_t dst_offset = 0, nframes_t src_offset = 0) = 0;
|
||||
virtual void merge_from (const Buffer& src, nframes_t len, nframes_t dst_offset = 0, nframes_t src_offset = 0) = 0;
|
||||
virtual void read_from (const Buffer& src, framecnt_t len, framecnt_t dst_offset = 0, framecnt_t src_offset = 0) = 0;
|
||||
virtual void merge_from (const Buffer& src, framecnt_t len, framecnt_t dst_offset = 0, framecnt_t src_offset = 0) = 0;
|
||||
|
||||
protected:
|
||||
Buffer(DataType type, size_t capacity)
|
||||
|
|
|
@ -66,7 +66,7 @@ public:
|
|||
|
||||
void clear();
|
||||
|
||||
void attach_buffers(PortSet& ports, nframes_t nframes, nframes_t offset = 0);
|
||||
void attach_buffers(PortSet& ports, framecnt_t nframes, framecnt_t offset = 0);
|
||||
|
||||
/* the capacity here is a size_t and has a different interpretation depending
|
||||
on the DataType of the buffers. for audio, its a frame count. for MIDI
|
||||
|
@ -83,7 +83,7 @@ public:
|
|||
ChanCount& count() { return _count; }
|
||||
|
||||
void is_silent(bool yn);
|
||||
void silence (nframes_t nframes, nframes_t offset);
|
||||
void silence (framecnt_t nframes, framecnt_t offset);
|
||||
bool is_mirror() const { return _is_mirror; }
|
||||
|
||||
void set_count(const ChanCount& count) { assert(count <= _available); _count = count; }
|
||||
|
@ -115,8 +115,8 @@ public:
|
|||
VstEvents* get_vst_midi (size_t);
|
||||
#endif
|
||||
|
||||
void read_from(const BufferSet& in, nframes_t nframes);
|
||||
void merge_from(const BufferSet& in, nframes_t nframes);
|
||||
void read_from(const BufferSet& in, framecnt_t nframes);
|
||||
void merge_from(const BufferSet& in, framecnt_t nframes);
|
||||
|
||||
template <typename BS, typename B>
|
||||
class iterator_base {
|
||||
|
@ -176,7 +176,7 @@ private:
|
|||
~VSTBuffer ();
|
||||
|
||||
void clear ();
|
||||
void push_back (Evoral::MIDIEvent<nframes_t> const &);
|
||||
void push_back (Evoral::MIDIEvent<framepos_t> const &);
|
||||
VstEvents* events () const {
|
||||
return _events;
|
||||
}
|
||||
|
|
|
@ -54,8 +54,8 @@ class Butler : public SessionHandleRef
|
|||
float read_data_rate() const; ///< in usec
|
||||
float write_data_rate() const;
|
||||
|
||||
nframes_t audio_diskstream_capture_buffer_size() const { return audio_dstream_capture_buffer_size; }
|
||||
nframes_t audio_diskstream_playback_buffer_size() const { return audio_dstream_playback_buffer_size; }
|
||||
framecnt_t audio_diskstream_capture_buffer_size() const { return audio_dstream_capture_buffer_size; }
|
||||
framecnt_t audio_diskstream_playback_buffer_size() const { return audio_dstream_playback_buffer_size; }
|
||||
uint32_t midi_diskstream_buffer_size() const { return midi_dstream_buffer_size; }
|
||||
|
||||
static void* _thread_work(void *arg);
|
||||
|
@ -76,8 +76,8 @@ class Butler : public SessionHandleRef
|
|||
bool should_run;
|
||||
mutable gint should_do_transport_work;
|
||||
int request_pipe[2];
|
||||
nframes_t audio_dstream_capture_buffer_size;
|
||||
nframes_t audio_dstream_playback_buffer_size;
|
||||
framecnt_t audio_dstream_capture_buffer_size;
|
||||
framecnt_t audio_dstream_playback_buffer_size;
|
||||
uint32_t midi_dstream_buffer_size;
|
||||
RingBuffer<CrossThreadPool*> pool_trash;
|
||||
|
||||
|
|
|
@ -29,34 +29,34 @@
|
|||
namespace ARDOUR {
|
||||
|
||||
struct Click {
|
||||
nframes_t start;
|
||||
nframes_t duration;
|
||||
nframes_t offset;
|
||||
const Sample *data;
|
||||
|
||||
Click (nframes_t s, nframes_t d, const Sample *b) : start (s), duration (d), offset (0), data (b) {}
|
||||
framepos_t start;
|
||||
framecnt_t duration;
|
||||
framecnt_t offset;
|
||||
const Sample *data;
|
||||
|
||||
Click (framepos_t s, framecnt_t d, const Sample *b) : start (s), duration (d), offset (0), data (b) {}
|
||||
|
||||
void *operator new (size_t) {
|
||||
return pool.alloc ();
|
||||
void *operator new (size_t) {
|
||||
return pool.alloc ();
|
||||
};
|
||||
|
||||
void operator delete(void *ptr, size_t /*size*/) {
|
||||
pool.release (ptr);
|
||||
}
|
||||
|
||||
|
||||
void operator delete(void *ptr, size_t /*size*/) {
|
||||
pool.release (ptr);
|
||||
}
|
||||
|
||||
private:
|
||||
static Pool pool;
|
||||
static Pool pool;
|
||||
};
|
||||
|
||||
typedef std::list<Click*> Clicks;
|
||||
|
||||
class ClickIO : public IO
|
||||
{
|
||||
public:
|
||||
public:
|
||||
ClickIO (Session& s, const std::string& name) : IO (s, name, IO::Output) {}
|
||||
~ClickIO() {}
|
||||
|
||||
protected:
|
||||
protected:
|
||||
uint32_t pans_required () const { return 1; }
|
||||
};
|
||||
|
||||
|
|
|
@ -66,21 +66,21 @@ public:
|
|||
bool can_support_io_configuration (const ChanCount& in, ChanCount& out) const;
|
||||
bool configure_io (ChanCount in, ChanCount out);
|
||||
|
||||
void run (BufferSet& bufs, framepos_t start_frame, framepos_t end_frame, nframes_t nframes, bool);
|
||||
void run (BufferSet& bufs, framepos_t start_frame, framepos_t end_frame, pframes_t nframes, bool);
|
||||
|
||||
/* supplemental method used with MIDI */
|
||||
|
||||
void flush_buffers (nframes_t nframes, framepos_t time);
|
||||
void flush_buffers (framecnt_t nframes, framepos_t time);
|
||||
void no_outs_cuz_we_no_monitor(bool);
|
||||
void cycle_start (nframes_t);
|
||||
void increment_output_offset (nframes_t);
|
||||
void cycle_start (pframes_t);
|
||||
void increment_output_offset (framecnt_t);
|
||||
void transport_stopped (framepos_t frame);
|
||||
|
||||
BufferSet& output_buffers() { return *_output_buffers; }
|
||||
|
||||
PBD::Signal0<void> MuteChange;
|
||||
|
||||
static PBD::Signal1<void,nframes_t> CycleStart;
|
||||
static PBD::Signal1<void, pframes_t> CycleStart;
|
||||
|
||||
XMLNode& state (bool full);
|
||||
int set_state (const XMLNode&, int version);
|
||||
|
@ -104,7 +104,7 @@ public:
|
|||
Role _role;
|
||||
BufferSet* _output_buffers;
|
||||
gain_t _current_gain;
|
||||
nframes_t _output_offset;
|
||||
framecnt_t _output_offset;
|
||||
bool _no_outs_cuz_we_no_monitor;
|
||||
boost::shared_ptr<MuteMaster> _mute_master;
|
||||
bool no_panner_reset;
|
||||
|
|
|
@ -79,8 +79,8 @@ class Diskstream : public SessionObject, public PublicDiskstream
|
|||
void set_align_style (AlignStyle);
|
||||
void set_persistent_align_style (AlignStyle a) { _persistent_alignment_style = a; }
|
||||
|
||||
nframes_t roll_delay() const { return _roll_delay; }
|
||||
void set_roll_delay (nframes_t);
|
||||
framecnt_t roll_delay() const { return _roll_delay; }
|
||||
void set_roll_delay (framecnt_t);
|
||||
|
||||
bool record_enabled() const { return g_atomic_int_get (&_record_enabled); }
|
||||
virtual void set_record_enabled (bool yn) = 0;
|
||||
|
@ -118,8 +118,8 @@ class Diskstream : public SessionObject, public PublicDiskstream
|
|||
|
||||
ChanCount n_channels() { return _n_channels; }
|
||||
|
||||
static nframes_t disk_io_frames() { return disk_io_chunk_frames; }
|
||||
static void set_disk_io_chunk_frames (uint32_t n) { disk_io_chunk_frames = n; }
|
||||
static framecnt_t disk_io_frames() { return disk_io_chunk_frames; }
|
||||
static void set_disk_io_chunk_frames (framecnt_t n) { disk_io_chunk_frames = n; }
|
||||
|
||||
/* Stateful */
|
||||
virtual XMLNode& get_state(void) = 0;
|
||||
|
@ -127,7 +127,7 @@ class Diskstream : public SessionObject, public PublicDiskstream
|
|||
|
||||
virtual void monitor_input (bool) {}
|
||||
|
||||
nframes_t capture_offset() const { return _capture_offset; }
|
||||
framecnt_t capture_offset() const { return _capture_offset; }
|
||||
virtual void set_capture_offset ();
|
||||
|
||||
bool slaved() const { return _slaved; }
|
||||
|
@ -144,7 +144,7 @@ class Diskstream : public SessionObject, public PublicDiskstream
|
|||
|
||||
/** For non-butler contexts (allocates temporary working buffers) */
|
||||
virtual int do_refill_with_alloc() = 0;
|
||||
virtual void set_block_size (nframes_t) = 0;
|
||||
virtual void set_block_size (pframes_t) = 0;
|
||||
|
||||
bool pending_overwrite () const {
|
||||
return _pending_overwrite;
|
||||
|
@ -186,8 +186,8 @@ class Diskstream : public SessionObject, public PublicDiskstream
|
|||
protected:
|
||||
friend class Track;
|
||||
|
||||
virtual int process (framepos_t transport_frame, nframes_t nframes, bool can_record, bool rec_monitors_input, bool& need_butler) = 0;
|
||||
virtual bool commit (nframes_t nframes) = 0;
|
||||
virtual int process (framepos_t transport_frame, pframes_t nframes, bool can_record, bool rec_monitors_input, bool& need_butler) = 0;
|
||||
virtual bool commit (framecnt_t nframes) = 0;
|
||||
|
||||
//private:
|
||||
|
||||
|
@ -239,9 +239,9 @@ class Diskstream : public SessionObject, public PublicDiskstream
|
|||
virtual void prepare_to_stop (framepos_t pos);
|
||||
|
||||
void calculate_record_range(OverlapType ot, framepos_t transport_frame, framecnt_t nframes,
|
||||
nframes_t& rec_nframes, nframes_t& rec_offset);
|
||||
framecnt_t& rec_nframes, framecnt_t& rec_offset);
|
||||
|
||||
static nframes_t disk_io_chunk_frames;
|
||||
static framecnt_t disk_io_chunk_frames;
|
||||
std::vector<CaptureInfo*> capture_info;
|
||||
mutable Glib::Mutex capture_info_lock;
|
||||
|
||||
|
@ -265,9 +265,9 @@ class Diskstream : public SessionObject, public PublicDiskstream
|
|||
framepos_t capture_start_frame;
|
||||
framecnt_t capture_captured;
|
||||
bool was_recording;
|
||||
nframes_t adjust_capture_position;
|
||||
nframes_t _capture_offset;
|
||||
nframes_t _roll_delay;
|
||||
framecnt_t adjust_capture_position;
|
||||
framecnt_t _capture_offset;
|
||||
framecnt_t _roll_delay;
|
||||
framepos_t first_recordable_frame;
|
||||
framepos_t last_recordable_frame;
|
||||
int last_possibly_recording;
|
||||
|
@ -280,8 +280,8 @@ class Diskstream : public SessionObject, public PublicDiskstream
|
|||
bool _pending_overwrite;
|
||||
bool overwrite_queued;
|
||||
IOChange input_change_pending;
|
||||
nframes_t wrap_buffer_size;
|
||||
nframes_t speed_buffer_size;
|
||||
framecnt_t wrap_buffer_size;
|
||||
framecnt_t speed_buffer_size;
|
||||
|
||||
double _speed;
|
||||
double _target_speed;
|
||||
|
@ -299,10 +299,6 @@ class Diskstream : public SessionObject, public PublicDiskstream
|
|||
|
||||
Glib::Mutex state_lock;
|
||||
|
||||
framepos_t scrub_start;
|
||||
nframes_t scrub_buffer_size;
|
||||
nframes_t scrub_offset;
|
||||
|
||||
PBD::ScopedConnectionList playlist_connections;
|
||||
|
||||
PBD::ScopedConnection ic_connection;
|
||||
|
|
|
@ -109,13 +109,13 @@ class ElementImporter
|
|||
std::string name;
|
||||
|
||||
/// The sample rate of the session from which we are importing
|
||||
nframes_t sample_rate;
|
||||
framecnt_t sample_rate;
|
||||
|
||||
/// Converts timecode time to a string
|
||||
std::string timecode_to_string (Timecode::Time & time) const;
|
||||
|
||||
/// Converts samples so that times match the sessions sample rate
|
||||
nframes_t rate_convert_samples (nframes_t samples) const;
|
||||
framecnt_t rate_convert_samples (framecnt_t samples) const;
|
||||
|
||||
/// Converts samples so that times match the sessions sample rate (for straight use in XML)
|
||||
std::string rate_convert_samples (std::string const & samples) const;
|
||||
|
|
|
@ -43,7 +43,7 @@ class ExportChannel : public boost::less_than_comparable<ExportChannel>
|
|||
|
||||
virtual ~ExportChannel () {}
|
||||
|
||||
virtual void read (Sample * data, nframes_t frames) const = 0;
|
||||
virtual void read (Sample * data, framecnt_t frames) const = 0;
|
||||
virtual bool empty () const = 0;
|
||||
|
||||
/// Adds state to node passed
|
||||
|
@ -75,7 +75,7 @@ class PortExportChannel : public ExportChannel
|
|||
|
||||
PortExportChannel () {}
|
||||
|
||||
void read (Sample * data, nframes_t frames) const;
|
||||
void read (Sample * data, framecnt_t frames) const;
|
||||
bool empty () const { return ports.empty(); }
|
||||
|
||||
void get_state (XMLNode * node) const;
|
||||
|
@ -104,23 +104,23 @@ class RegionExportChannelFactory
|
|||
~RegionExportChannelFactory ();
|
||||
|
||||
ExportChannelPtr create (uint32_t channel);
|
||||
void read (uint32_t channel, Sample * data, nframes_t frames_to_read);
|
||||
void read (uint32_t channel, Sample * data, framecnt_t frames_to_read);
|
||||
|
||||
private:
|
||||
|
||||
int new_cycle_started (nframes_t) { buffers_up_to_date = false; return 0; }
|
||||
void update_buffers (nframes_t frames);
|
||||
int new_cycle_started (framecnt_t) { buffers_up_to_date = false; return 0; }
|
||||
void update_buffers (framecnt_t frames);
|
||||
|
||||
AudioRegion const & region;
|
||||
AudioTrack & track;
|
||||
Type type;
|
||||
|
||||
nframes_t frames_per_cycle;
|
||||
framecnt_t frames_per_cycle;
|
||||
size_t n_channels;
|
||||
BufferSet buffers;
|
||||
bool buffers_up_to_date;
|
||||
nframes_t region_start;
|
||||
nframes_t position;
|
||||
framecnt_t region_start;
|
||||
framecnt_t position;
|
||||
|
||||
Sample * mixdown_buffer;
|
||||
Sample * gain_buffer;
|
||||
|
@ -134,7 +134,7 @@ class RegionExportChannel : public ExportChannel
|
|||
friend class RegionExportChannelFactory;
|
||||
|
||||
public:
|
||||
void read (Sample * data, nframes_t frames_to_read) const { factory.read (channel, data, frames_to_read); }
|
||||
void read (Sample * data, framecnt_t frames_to_read) const { factory.read (channel, data, frames_to_read); }
|
||||
void get_state (XMLNode * /*node*/) const {};
|
||||
void set_state (XMLNode * /*node*/, Session & /*session*/) {};
|
||||
bool empty () const { return false; }
|
||||
|
|
|
@ -47,7 +47,7 @@ class ExportFormatSpecification : public ExportFormatBase {
|
|||
Time (Session & session) : AnyTime (), session (session) {}
|
||||
Time & operator= (AnyTime const & other);
|
||||
|
||||
nframes_t get_frames (nframes_t target_rate) const;
|
||||
framecnt_t get_frames (framecnt_t target_rate) const;
|
||||
|
||||
/* Serialization */
|
||||
|
||||
|
@ -123,11 +123,11 @@ class ExportFormatSpecification : public ExportFormatBase {
|
|||
|
||||
bool tag () const { return _tag && supports_tagging; }
|
||||
|
||||
nframes_t silence_beginning () const { return _silence_beginning.get_frames (sample_rate()); }
|
||||
nframes_t silence_end () const { return _silence_end.get_frames (sample_rate()); }
|
||||
framecnt_t silence_beginning () const { return _silence_beginning.get_frames (sample_rate()); }
|
||||
framecnt_t silence_end () const { return _silence_end.get_frames (sample_rate()); }
|
||||
|
||||
nframes_t silence_beginning (nframes_t samplerate) const { return _silence_beginning.get_frames (samplerate); }
|
||||
nframes_t silence_end (nframes_t samplerate) const { return _silence_end.get_frames (samplerate); }
|
||||
framecnt_t silence_beginning (framecnt_t samplerate) const { return _silence_beginning.get_frames (samplerate); }
|
||||
framecnt_t silence_end (framecnt_t samplerate) const { return _silence_end.get_frames (samplerate); }
|
||||
|
||||
AnyTime silence_beginning_time () const { return _silence_beginning; }
|
||||
AnyTime silence_end_time () const { return _silence_end; }
|
||||
|
|
|
@ -62,7 +62,7 @@ class ExportGraphBuilder
|
|||
ExportGraphBuilder (Session const & session);
|
||||
~ExportGraphBuilder ();
|
||||
|
||||
int process (nframes_t frames, bool last_cycle);
|
||||
int process (framecnt_t frames, bool last_cycle);
|
||||
bool process_normalize (); // returns true when finished
|
||||
|
||||
void reset ();
|
||||
|
@ -102,7 +102,7 @@ class ExportGraphBuilder
|
|||
class SFC {
|
||||
public:
|
||||
// This constructor so that this can be constructed like a Normalizer
|
||||
SFC (ExportGraphBuilder &, FileSpec const & new_config, nframes_t max_frames);
|
||||
SFC (ExportGraphBuilder &, FileSpec const & new_config, framecnt_t max_frames);
|
||||
FloatSinkPtr sink ();
|
||||
void add_child (FileSpec const & new_config);
|
||||
bool operator== (FileSpec const & other_config) const;
|
||||
|
@ -124,7 +124,7 @@ class ExportGraphBuilder
|
|||
|
||||
class Normalizer {
|
||||
public:
|
||||
Normalizer (ExportGraphBuilder & parent, FileSpec const & new_config, nframes_t max_frames);
|
||||
Normalizer (ExportGraphBuilder & parent, FileSpec const & new_config, framecnt_t max_frames);
|
||||
FloatSinkPtr sink ();
|
||||
void add_child (FileSpec const & new_config);
|
||||
bool operator== (FileSpec const & other_config) const;
|
||||
|
@ -144,7 +144,7 @@ class ExportGraphBuilder
|
|||
ExportGraphBuilder & parent;
|
||||
|
||||
FileSpec config;
|
||||
nframes_t max_frames_out;
|
||||
framecnt_t max_frames_out;
|
||||
|
||||
BufferPtr buffer;
|
||||
PeakReaderPtr peak_reader;
|
||||
|
@ -159,7 +159,7 @@ class ExportGraphBuilder
|
|||
// sample rate converter
|
||||
class SRC {
|
||||
public:
|
||||
SRC (ExportGraphBuilder & parent, FileSpec const & new_config, nframes_t max_frames);
|
||||
SRC (ExportGraphBuilder & parent, FileSpec const & new_config, framecnt_t max_frames);
|
||||
FloatSinkPtr sink ();
|
||||
void add_child (FileSpec const & new_config);
|
||||
bool operator== (FileSpec const & other_config) const;
|
||||
|
@ -175,13 +175,13 @@ class ExportGraphBuilder
|
|||
boost::ptr_list<SFC> children;
|
||||
boost::ptr_list<Normalizer> normalized_children;
|
||||
SRConverterPtr converter;
|
||||
nframes_t max_frames_out;
|
||||
framecnt_t max_frames_out;
|
||||
};
|
||||
|
||||
// Silence trimmer + adder
|
||||
class SilenceHandler {
|
||||
public:
|
||||
SilenceHandler (ExportGraphBuilder & parent, FileSpec const & new_config, nframes_t max_frames);
|
||||
SilenceHandler (ExportGraphBuilder & parent, FileSpec const & new_config, framecnt_t max_frames);
|
||||
FloatSinkPtr sink ();
|
||||
void add_child (FileSpec const & new_config);
|
||||
bool operator== (FileSpec const & other_config) const;
|
||||
|
@ -193,7 +193,7 @@ class ExportGraphBuilder
|
|||
FileSpec config;
|
||||
boost::ptr_list<SRC> children;
|
||||
SilenceTrimmerPtr silence_trimmer;
|
||||
nframes_t max_frames_in;
|
||||
framecnt_t max_frames_in;
|
||||
};
|
||||
|
||||
// channel configuration
|
||||
|
@ -210,7 +210,7 @@ class ExportGraphBuilder
|
|||
FileSpec config;
|
||||
boost::ptr_list<SilenceHandler> children;
|
||||
InterleaverPtr interleaver;
|
||||
nframes_t max_frames;
|
||||
framecnt_t max_frames;
|
||||
};
|
||||
|
||||
Session const & session;
|
||||
|
@ -223,7 +223,7 @@ class ExportGraphBuilder
|
|||
ChannelMap channels;
|
||||
|
||||
Sample * process_buffer;
|
||||
nframes_t process_buffer_frames;
|
||||
framecnt_t process_buffer_frames;
|
||||
|
||||
std::list<Normalizer *> normalizers;
|
||||
|
||||
|
|
|
@ -119,7 +119,7 @@ class ExportHandler : public ExportElementFactory
|
|||
|
||||
private:
|
||||
|
||||
int process (nframes_t frames);
|
||||
int process (framecnt_t frames);
|
||||
|
||||
Session & session;
|
||||
GraphBuilderPtr graph_builder;
|
||||
|
@ -132,7 +132,7 @@ class ExportHandler : public ExportElementFactory
|
|||
/* Timespan management */
|
||||
|
||||
void start_timespan ();
|
||||
int process_timespan (nframes_t frames);
|
||||
int process_timespan (framecnt_t frames);
|
||||
int process_normalize ();
|
||||
void finish_timespan ();
|
||||
|
||||
|
|
|
@ -136,8 +136,8 @@ class ExportProfileManager
|
|||
typedef boost::shared_ptr<TimespanState> TimespanStatePtr;
|
||||
typedef std::list<TimespanStatePtr> TimespanStateList;
|
||||
|
||||
void set_selection_range (nframes_t start = 0, nframes_t end = 0);
|
||||
std::string set_single_range (nframes_t start, nframes_t end, std::string name);
|
||||
void set_selection_range (framepos_t start = 0, framepos_t end = 0);
|
||||
std::string set_single_range (framepos_t start, framepos_t end, std::string name);
|
||||
TimespanStateList const & get_timespans () { return check_list (timespans); }
|
||||
|
||||
private:
|
||||
|
|
|
@ -42,7 +42,7 @@ class ExportTimespan
|
|||
|
||||
private:
|
||||
friend class ExportElementFactory;
|
||||
ExportTimespan (ExportStatusPtr status, nframes_t frame_rate);
|
||||
ExportTimespan (ExportStatusPtr status, framecnt_t frame_rate);
|
||||
|
||||
public:
|
||||
~ExportTimespan ();
|
||||
|
@ -53,19 +53,19 @@ class ExportTimespan
|
|||
std::string range_id () const { return _range_id; }
|
||||
void set_range_id (std::string range_id) { _range_id = range_id; }
|
||||
|
||||
void set_range (nframes_t start, nframes_t end);
|
||||
nframes_t get_length () const { return end_frame - start_frame; }
|
||||
nframes_t get_start () const { return start_frame; }
|
||||
nframes_t get_end () const { return end_frame; }
|
||||
void set_range (framepos_t start, framepos_t end);
|
||||
framecnt_t get_length () const { return end_frame - start_frame; }
|
||||
framepos_t get_start () const { return start_frame; }
|
||||
framepos_t get_end () const { return end_frame; }
|
||||
|
||||
private:
|
||||
|
||||
ExportStatusPtr status;
|
||||
|
||||
nframes_t start_frame;
|
||||
nframes_t end_frame;
|
||||
nframes_t position;
|
||||
nframes_t frame_rate;
|
||||
framepos_t start_frame;
|
||||
framepos_t end_frame;
|
||||
framepos_t position;
|
||||
framecnt_t frame_rate;
|
||||
|
||||
std::string _name;
|
||||
std::string _range_id;
|
||||
|
|
|
@ -31,10 +31,10 @@ struct Gain : public AutomationList {
|
|||
Gain (const Gain&);
|
||||
Gain& operator= (const Gain&);
|
||||
|
||||
static void fill_linear_fade_in (Gain& curve, nframes_t frames);
|
||||
static void fill_linear_volume_fade_in (Gain& curve, nframes_t frames);
|
||||
static void fill_linear_fade_out (Gain& curve, nframes_t frames);
|
||||
static void fill_linear_volume_fade_out (Gain& curve, nframes_t frames);
|
||||
static void fill_linear_fade_in (Gain& curve, framecnt_t frames);
|
||||
static void fill_linear_volume_fade_in (Gain& curve, framecnt_t frames);
|
||||
static void fill_linear_fade_out (Gain& curve, framecnt_t frames);
|
||||
static void fill_linear_volume_fade_out (Gain& curve, framecnt_t frames);
|
||||
|
||||
};
|
||||
|
||||
|
|
|
@ -71,14 +71,14 @@ class Graph : public SessionHandleRef
|
|||
void helper_thread();
|
||||
void main_thread();
|
||||
|
||||
int silent_process_routes (nframes_t nframes, framepos_t start_frame, framepos_t end_frame,
|
||||
bool can_record, bool rec_monitors_input, bool& need_butler);
|
||||
int silent_process_routes (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
|
||||
bool can_record, bool rec_monitors_input, bool& need_butler);
|
||||
|
||||
int process_routes (nframes_t nframes, framepos_t start_frame, framepos_t end_frame, int declick,
|
||||
bool can_record, bool rec_monitors_input, bool& need_butler);
|
||||
int process_routes (pframes_t nframes, framepos_t start_frame, framepos_t end_frame, int declick,
|
||||
bool can_record, bool rec_monitors_input, bool& need_butler);
|
||||
|
||||
int routes_no_roll (nframes_t nframes, framepos_t start_frame, framepos_t end_frame,
|
||||
bool non_rt_pending, bool can_record, int declick);
|
||||
int routes_no_roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
|
||||
bool non_rt_pending, bool can_record, int declick);
|
||||
|
||||
void process_one_route (Route * route);
|
||||
|
||||
|
@ -118,7 +118,7 @@ class Graph : public SessionHandleRef
|
|||
volatile int _setup_chain;
|
||||
|
||||
// parameter caches.
|
||||
nframes_t _process_nframes;
|
||||
pframes_t _process_nframes;
|
||||
framepos_t _process_start_frame;
|
||||
framepos_t _process_end_frame;
|
||||
bool _process_can_record;
|
||||
|
|
|
@ -30,12 +30,12 @@ public:
|
|||
ImportableSource () {}
|
||||
virtual ~ImportableSource() {}
|
||||
|
||||
virtual nframes_t read (Sample* buffer, nframes_t nframes) = 0;
|
||||
virtual framecnt_t read (Sample* buffer, framecnt_t nframes) = 0;
|
||||
virtual float ratio() const { return 1.0f; }
|
||||
virtual uint32_t channels() const = 0;
|
||||
virtual framecnt_t length() const = 0;
|
||||
virtual nframes_t samplerate() const = 0;
|
||||
virtual void seek (nframes_t pos) = 0;
|
||||
virtual framecnt_t samplerate() const = 0;
|
||||
virtual void seek (framecnt_t pos) = 0;
|
||||
virtual framepos_t natural_position() const = 0;
|
||||
|
||||
virtual bool clamped_at_unity () const = 0;
|
||||
|
|
|
@ -36,21 +36,21 @@ XMLNode& state(bool full);
|
|||
XMLNode& get_state(void);
|
||||
int set_state(const XMLNode&, int version);
|
||||
|
||||
void run (BufferSet& bufs, framepos_t start_frame, framepos_t end_frame, nframes_t nframes, bool);
|
||||
void run (BufferSet& bufs, framepos_t start_frame, framepos_t end_frame, pframes_t nframes, bool);
|
||||
bool configure_io (ChanCount in, ChanCount out);
|
||||
bool can_support_io_configuration (const ChanCount& in, ChanCount& out) const;
|
||||
int set_block_size (nframes_t);
|
||||
int set_block_size (pframes_t);
|
||||
|
||||
BufferSet* get_buffers();
|
||||
void release_buffers();
|
||||
|
||||
static PBD::Signal1<void,nframes_t> CycleStart;
|
||||
static PBD::Signal1<void, pframes_t> CycleStart;
|
||||
|
||||
private:
|
||||
BufferSet buffers;
|
||||
gint user_count; /* atomic */
|
||||
void allocate_buffers (nframes_t);
|
||||
void cycle_start (nframes_t);
|
||||
void allocate_buffers (pframes_t);
|
||||
void cycle_start (pframes_t);
|
||||
};
|
||||
|
||||
} // namespace ARDOUR
|
||||
|
|
|
@ -39,11 +39,11 @@ class InternalSend : public Send
|
|||
XMLNode& get_state(void);
|
||||
int set_state(const XMLNode& node, int version);
|
||||
|
||||
void run (BufferSet& bufs, framepos_t start_frame, framepos_t end_frame, nframes_t nframes, bool);
|
||||
void run (BufferSet& bufs, framepos_t start_frame, framepos_t end_frame, pframes_t nframes, bool);
|
||||
bool feeds (boost::shared_ptr<Route> other) const;
|
||||
bool can_support_io_configuration (const ChanCount& in, ChanCount& out) const;
|
||||
bool configure_io (ChanCount in, ChanCount out);
|
||||
int set_block_size (nframes_t);
|
||||
int set_block_size (pframes_t);
|
||||
|
||||
boost::shared_ptr<Route> target_route() const { return _send_to; }
|
||||
const PBD::ID& target_id() const { return _send_to_id; }
|
||||
|
|
|
@ -39,13 +39,13 @@ class Interpolation {
|
|||
};
|
||||
|
||||
class LinearInterpolation : public Interpolation {
|
||||
public:
|
||||
nframes_t interpolate (int channel, nframes_t nframes, Sample* input, Sample* output);
|
||||
public:
|
||||
framecnt_t interpolate (int channel, framecnt_t nframes, Sample* input, Sample* output);
|
||||
};
|
||||
|
||||
class CubicInterpolation : public Interpolation {
|
||||
public:
|
||||
nframes_t interpolate (int channel, nframes_t nframes, Sample* input, Sample* output);
|
||||
public:
|
||||
framecnt_t interpolate (int channel, framecnt_t nframes, Sample* input, Sample* output);
|
||||
};
|
||||
|
||||
} // namespace ARDOUR
|
||||
|
|
|
@ -89,7 +89,7 @@ class IO : public SessionObject, public Latent
|
|||
|
||||
bool set_name (const std::string& str);
|
||||
|
||||
virtual void silence (nframes_t);
|
||||
virtual void silence (framecnt_t);
|
||||
|
||||
int ensure_io (ChanCount cnt, bool clear, void *src);
|
||||
|
||||
|
@ -109,9 +109,9 @@ class IO : public SessionObject, public Latent
|
|||
bool connected () const;
|
||||
bool physically_connected () const;
|
||||
|
||||
nframes_t signal_latency() const { return _own_latency; }
|
||||
nframes_t latency() const;
|
||||
void set_port_latency (nframes_t);
|
||||
framecnt_t signal_latency () const { return _own_latency; }
|
||||
framecnt_t latency () const;
|
||||
void set_port_latency (framecnt_t);
|
||||
|
||||
void update_port_total_latencies ();
|
||||
|
||||
|
@ -188,9 +188,9 @@ class IO : public SessionObject, public Latent
|
|||
|
||||
/* three utility functions - this just seems to be simplest place to put them */
|
||||
|
||||
void collect_input (BufferSet& bufs, nframes_t nframes, ChanCount offset);
|
||||
void process_input (boost::shared_ptr<Processor>, framepos_t start_frame, framepos_t end_frame, nframes_t nframes);
|
||||
void copy_to_outputs (BufferSet& bufs, DataType type, nframes_t nframes, nframes_t offset);
|
||||
void collect_input (BufferSet& bufs, pframes_t nframes, ChanCount offset);
|
||||
void process_input (boost::shared_ptr<Processor>, framepos_t start_frame, framepos_t end_frame, pframes_t nframes);
|
||||
void copy_to_outputs (BufferSet& bufs, DataType type, pframes_t nframes, framecnt_t offset);
|
||||
|
||||
/* AudioTrack::deprecated_use_diskstream_connections() needs these */
|
||||
|
||||
|
|
|
@ -62,7 +62,7 @@ class IOProcessor : public Processor
|
|||
void set_input (boost::shared_ptr<IO>);
|
||||
void set_output (boost::shared_ptr<IO>);
|
||||
|
||||
void silence (nframes_t nframes);
|
||||
void silence (framecnt_t nframes);
|
||||
void disconnect ();
|
||||
|
||||
virtual bool feeds (boost::shared_ptr<Route> other) const;
|
||||
|
|
|
@ -39,7 +39,7 @@ class Session;
|
|||
class LadspaPlugin : public ARDOUR::Plugin
|
||||
{
|
||||
public:
|
||||
LadspaPlugin (void *module, ARDOUR::AudioEngine&, ARDOUR::Session&, uint32_t index, nframes_t sample_rate);
|
||||
LadspaPlugin (void *module, ARDOUR::AudioEngine&, ARDOUR::Session&, uint32_t index, framecnt_t sample_rate);
|
||||
LadspaPlugin (const LadspaPlugin &);
|
||||
~LadspaPlugin ();
|
||||
|
||||
|
@ -51,7 +51,7 @@ class LadspaPlugin : public ARDOUR::Plugin
|
|||
const char* maker() const { return _descriptor->Maker; }
|
||||
uint32_t parameter_count() const { return _descriptor->PortCount; }
|
||||
float default_value (uint32_t port);
|
||||
nframes_t signal_latency() const;
|
||||
framecnt_t signal_latency() const;
|
||||
void set_parameter (uint32_t port, float val);
|
||||
float get_parameter (uint32_t port) const;
|
||||
int get_parameter_descriptor (uint32_t which, ParameterDescriptor&) const;
|
||||
|
@ -81,11 +81,11 @@ class LadspaPlugin : public ARDOUR::Plugin
|
|||
_descriptor->cleanup (_handle);
|
||||
}
|
||||
|
||||
int set_block_size (nframes_t /*nframes*/) { return 0; }
|
||||
int set_block_size (pframes_t /*nframes*/) { return 0; }
|
||||
|
||||
int connect_and_run (BufferSet& bufs,
|
||||
ChanMapping in, ChanMapping out,
|
||||
nframes_t nframes, nframes_t offset);
|
||||
pframes_t nframes, framecnt_t offset);
|
||||
|
||||
std::string describe_parameter (Evoral::Parameter);
|
||||
std::string state_node_name() const { return "ladspa"; }
|
||||
|
@ -122,15 +122,15 @@ class LadspaPlugin : public ARDOUR::Plugin
|
|||
void* _module;
|
||||
const LADSPA_Descriptor* _descriptor;
|
||||
LADSPA_Handle _handle;
|
||||
nframes_t _sample_rate;
|
||||
framecnt_t _sample_rate;
|
||||
LADSPA_Data* _control_data;
|
||||
LADSPA_Data* _shadow_data;
|
||||
LADSPA_Data* _latency_control_port;
|
||||
uint32_t _index;
|
||||
bool _was_activated;
|
||||
|
||||
void init (void *mod, uint32_t index, nframes_t rate);
|
||||
void run_in_place (nframes_t nsamples);
|
||||
void init (void *mod, uint32_t index, framecnt_t rate);
|
||||
void run_in_place (pframes_t nsamples);
|
||||
void latency_compute_run ();
|
||||
int set_state_2X (const XMLNode&, int version);
|
||||
};
|
||||
|
|
|
@ -10,10 +10,10 @@ class Latent {
|
|||
Latent() : _own_latency (0), _user_latency (0) {}
|
||||
virtual ~Latent() {}
|
||||
|
||||
virtual nframes_t signal_latency() const = 0;
|
||||
nframes_t user_latency () const { return _user_latency; }
|
||||
virtual framecnt_t signal_latency() const = 0;
|
||||
framecnt_t user_latency () const { return _user_latency; }
|
||||
|
||||
nframes_t effective_latency() const {
|
||||
framecnt_t effective_latency() const {
|
||||
if (_user_latency) {
|
||||
return _user_latency;
|
||||
} else {
|
||||
|
@ -21,12 +21,12 @@ class Latent {
|
|||
}
|
||||
}
|
||||
|
||||
virtual void set_latency_delay (nframes_t val) { _own_latency = val; }
|
||||
virtual void set_user_latency (nframes_t val) { _user_latency = val; }
|
||||
virtual void set_latency_delay (framecnt_t val) { _own_latency = val; }
|
||||
virtual void set_user_latency (framecnt_t val) { _user_latency = val; }
|
||||
|
||||
protected:
|
||||
nframes_t _own_latency;
|
||||
nframes_t _user_latency;
|
||||
framecnt_t _own_latency;
|
||||
framecnt_t _user_latency;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
@ -41,7 +41,7 @@ struct LV2World;
|
|||
class LV2Plugin : public ARDOUR::Plugin
|
||||
{
|
||||
public:
|
||||
LV2Plugin (ARDOUR::AudioEngine&, ARDOUR::Session&, ARDOUR::LV2World&, SLV2Plugin plugin, nframes_t sample_rate);
|
||||
LV2Plugin (ARDOUR::AudioEngine&, ARDOUR::Session&, ARDOUR::LV2World&, SLV2Plugin plugin, framecnt_t sample_rate);
|
||||
LV2Plugin (const LV2Plugin &);
|
||||
~LV2Plugin ();
|
||||
|
||||
|
@ -53,7 +53,7 @@ class LV2Plugin : public ARDOUR::Plugin
|
|||
const char* maker() const { return _author ? slv2_value_as_string(_author) : "Unknown"; }
|
||||
uint32_t parameter_count() const { return slv2_plugin_get_num_ports(_plugin); }
|
||||
float default_value (uint32_t port);
|
||||
nframes_t signal_latency() const;
|
||||
framecnt_t signal_latency () const;
|
||||
void set_parameter (uint32_t port, float val);
|
||||
float get_parameter (uint32_t port) const;
|
||||
int get_parameter_descriptor (uint32_t which, ParameterDescriptor&) const;
|
||||
|
@ -93,11 +93,11 @@ class LV2Plugin : public ARDOUR::Plugin
|
|||
_instance = NULL;
|
||||
}
|
||||
|
||||
int set_block_size (nframes_t /*nframes*/) { return 0; }
|
||||
int set_block_size (pframes_t /*nframes*/) { return 0; }
|
||||
|
||||
int connect_and_run (BufferSet& bufs,
|
||||
ChanMapping in, ChanMapping out,
|
||||
nframes_t nframes, nframes_t offset);
|
||||
pframes_t nframes, framecnt_t offset);
|
||||
|
||||
std::string describe_parameter (Evoral::Parameter);
|
||||
std::string state_node_name() const { return "lv2"; }
|
||||
|
@ -129,7 +129,7 @@ class LV2Plugin : public ARDOUR::Plugin
|
|||
SLV2Value _name;
|
||||
SLV2Value _author;
|
||||
SLV2Instance _instance;
|
||||
nframes_t _sample_rate;
|
||||
framecnt_t _sample_rate;
|
||||
float* _control_data;
|
||||
float* _shadow_data;
|
||||
float* _defaults;
|
||||
|
@ -149,8 +149,8 @@ class LV2Plugin : public ARDOUR::Plugin
|
|||
static URIMap _uri_map;
|
||||
static uint32_t _midi_event_type;
|
||||
|
||||
void init (LV2World& world, SLV2Plugin plugin, nframes_t rate);
|
||||
void run (nframes_t nsamples);
|
||||
void init (LV2World& world, SLV2Plugin plugin, framecnt_t rate);
|
||||
void run (pframes_t nsamples);
|
||||
void latency_compute_run ();
|
||||
};
|
||||
|
||||
|
|
|
@ -68,7 +68,7 @@ public:
|
|||
void reflect_inputs (const ChanCount& in);
|
||||
|
||||
/** Compute peaks */
|
||||
void run (BufferSet& bufs, framepos_t start_frame, framepos_t end_frame, nframes_t nframes, bool);
|
||||
void run (BufferSet& bufs, framepos_t start_frame, framepos_t end_frame, pframes_t nframes, bool);
|
||||
|
||||
ChanCount input_streams () const { return current_meters; }
|
||||
ChanCount output_streams () const { return current_meters; }
|
||||
|
|
|
@ -32,14 +32,14 @@ namespace ARDOUR {
|
|||
class MidiBuffer : public Buffer
|
||||
{
|
||||
public:
|
||||
typedef nframes_t TimeType;
|
||||
typedef framepos_t TimeType;
|
||||
|
||||
MidiBuffer(size_t capacity);
|
||||
~MidiBuffer();
|
||||
|
||||
void silence (nframes_t nframes, nframes_t offset = 0);
|
||||
void read_from (const Buffer& src, nframes_t nframes, nframes_t dst_offset = 0, nframes_t src_offset = 0);
|
||||
void merge_from (const Buffer& src, nframes_t nframes, nframes_t dst_offset = 0, nframes_t src_offset = 0);
|
||||
void silence (framecnt_t nframes, framecnt_t offset = 0);
|
||||
void read_from (const Buffer& src, framecnt_t nframes, framecnt_t dst_offset = 0, framecnt_t src_offset = 0);
|
||||
void merge_from (const Buffer& src, framecnt_t nframes, framecnt_t dst_offset = 0, framecnt_t src_offset = 0);
|
||||
|
||||
void copy(const MidiBuffer& copy);
|
||||
|
||||
|
@ -55,7 +55,7 @@ public:
|
|||
|
||||
template<typename BufferType, typename EventType>
|
||||
struct iterator_base {
|
||||
iterator_base<BufferType, EventType>(BufferType& b, nframes_t o) : buffer(b), offset(o) {}
|
||||
iterator_base<BufferType, EventType>(BufferType& b, framecnt_t o) : buffer(b), offset(o) {}
|
||||
inline EventType operator*() const {
|
||||
uint8_t* ev_start = buffer._data + offset + sizeof(TimeType);
|
||||
int event_size = Evoral::midi_event_size(ev_start);
|
||||
|
|
|
@ -124,7 +124,7 @@ class MidiDiskstream : public Diskstream
|
|||
|
||||
void set_pending_overwrite(bool);
|
||||
int overwrite_existing_buffers ();
|
||||
void set_block_size (nframes_t);
|
||||
void set_block_size (pframes_t);
|
||||
int internal_playback_seek (framecnt_t distance);
|
||||
int can_internal_playback_seek (framecnt_t distance);
|
||||
int rename_write_sources ();
|
||||
|
@ -133,7 +133,7 @@ class MidiDiskstream : public Diskstream
|
|||
void non_realtime_input_change ();
|
||||
void non_realtime_locate (framepos_t location);
|
||||
|
||||
static void set_readahead_frames(nframes_t frames_ahead) { midi_readahead = frames_ahead; }
|
||||
static void set_readahead_frames (framecnt_t frames_ahead) { midi_readahead = frames_ahead; }
|
||||
|
||||
protected:
|
||||
int seek (framepos_t which_sample, bool complete_refill = false);
|
||||
|
@ -141,9 +141,9 @@ class MidiDiskstream : public Diskstream
|
|||
protected:
|
||||
friend class MidiTrack;
|
||||
|
||||
int process (framepos_t transport_frame, nframes_t nframes, bool can_record, bool rec_monitors_input, bool& need_butler);
|
||||
bool commit (nframes_t nframes);
|
||||
static nframes_t midi_readahead;
|
||||
int process (framepos_t transport_frame, pframes_t nframes, bool can_record, bool rec_monitors_input, bool& need_butler);
|
||||
bool commit (framecnt_t nframes);
|
||||
static framecnt_t midi_readahead;
|
||||
|
||||
private:
|
||||
|
||||
|
@ -153,7 +153,7 @@ class MidiDiskstream : public Diskstream
|
|||
|
||||
int do_refill_with_alloc();
|
||||
|
||||
int read (framepos_t& start, nframes_t cnt, bool reversed);
|
||||
int read (framepos_t& start, framecnt_t cnt, bool reversed);
|
||||
|
||||
void finish_capture (bool rec_monitors_input);
|
||||
void transport_stopped_wallclock (struct tm&, time_t, bool abort);
|
||||
|
@ -181,11 +181,11 @@ class MidiDiskstream : public Diskstream
|
|||
void engage_record_enable ();
|
||||
void disengage_record_enable ();
|
||||
|
||||
MidiRingBuffer<nframes_t>* _playback_buf;
|
||||
MidiRingBuffer<nframes_t>* _capture_buf;
|
||||
MidiRingBuffer<framepos_t>* _playback_buf;
|
||||
MidiRingBuffer<framepos_t>* _capture_buf;
|
||||
MidiPort* _source_port;
|
||||
boost::shared_ptr<SMFSource> _write_source;
|
||||
nframes_t _last_flush_frame;
|
||||
framepos_t _last_flush_frame;
|
||||
NoteMode _note_mode;
|
||||
volatile gint _frames_written_to_ringbuffer;
|
||||
volatile gint _frames_read_from_ringbuffer;
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user