Skip to content

Commit

Permalink
fixes for destructive track offsets of various kinds; move from jack_…
Browse files Browse the repository at this point in the history
…nframes_t -> nframes_t

git-svn-id: svn://localhost/ardour2/trunk@933 d708f5d6-7413-0410-9779-e7cbd77b26cf
  • Loading branch information
pauldavisthefirst committed Sep 28, 2006
1 parent 3e6feb6 commit 93c7aeb
Show file tree
Hide file tree
Showing 181 changed files with 2,030 additions and 1,985 deletions.
4 changes: 2 additions & 2 deletions gtk2_ardour/analysis_window.cc
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,7 @@ AnalysisWindow::analyze_data (Gtk::Button *button)

for (std::list<ARDOUR::AudioRange>::iterator j = ts.begin(); j != ts.end(); ++j) {

jack_nframes_t i = 0;
nframes_t i = 0;
int n;

while ( i < (*j).length() ) {
Expand Down Expand Up @@ -289,7 +289,7 @@ AnalysisWindow::analyze_data (Gtk::Button *button)
continue;

// cerr << " - " << (*j)->region().name() << ": " << (*j)->region().length() << " samples starting at " << (*j)->region().position() << endl;
jack_nframes_t i = 0;
nframes_t i = 0;
int n;

while ( i < arv->region()->length() ) {
Expand Down
20 changes: 10 additions & 10 deletions gtk2_ardour/ardour_ui.cc
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ ARDOUR_UI *ARDOUR_UI::theArdourUI = 0;
sigc::signal<void,bool> ARDOUR_UI::Blink;
sigc::signal<void> ARDOUR_UI::RapidScreenUpdate;
sigc::signal<void> ARDOUR_UI::SuperRapidScreenUpdate;
sigc::signal<void,jack_nframes_t> ARDOUR_UI::Clock;
sigc::signal<void,nframes_t> ARDOUR_UI::Clock;

ARDOUR_UI::ARDOUR_UI (int *argcp, char **argvp[], string rcfile)

Expand Down Expand Up @@ -488,7 +488,7 @@ ARDOUR_UI::every_point_zero_one_seconds ()
}

void
ARDOUR_UI::update_sample_rate (jack_nframes_t ignored)
ARDOUR_UI::update_sample_rate (nframes_t ignored)
{
char buf[32];

Expand All @@ -500,7 +500,7 @@ ARDOUR_UI::update_sample_rate (jack_nframes_t ignored)

} else {

jack_nframes_t rate = engine->frame_rate();
nframes_t rate = engine->frame_rate();

if (fmod (rate, 1000.0) != 0.0) {
snprintf (buf, sizeof (buf), _("%.1f kHz / %4.1f msecs"),
Expand Down Expand Up @@ -554,7 +554,7 @@ ARDOUR_UI::update_disk_space()
return;
}

jack_nframes_t frames = session->available_capture_duration();
nframes_t frames = session->available_capture_duration();
char buf[64];

if (frames == max_frames) {
Expand All @@ -563,7 +563,7 @@ ARDOUR_UI::update_disk_space()
int hrs;
int mins;
int secs;
jack_nframes_t fr = session->frame_rate();
nframes_t fr = session->frame_rate();

if (session->actively_recording()){

Expand Down Expand Up @@ -930,9 +930,9 @@ restart JACK with more ports."));
}

void
ARDOUR_UI::do_transport_locate (jack_nframes_t new_position)
ARDOUR_UI::do_transport_locate (nframes_t new_position)
{
jack_nframes_t _preroll = 0;
nframes_t _preroll = 0;

if (session) {
// XXX CONFIG_CHANGE FIX - requires AnyTime handling
Expand Down Expand Up @@ -986,7 +986,7 @@ void
ARDOUR_UI::transport_goto_end ()
{
if (session) {
jack_nframes_t frame = session->current_end_frame();
nframes_t frame = session->current_end_frame();
session->request_locate (frame);

/* force displayed area in editor to start no matter
Expand Down Expand Up @@ -1846,7 +1846,7 @@ ARDOUR_UI::build_session (const string & path, const string & snap_name,
AutoConnectOption output_connect,
uint32_t nphysin,
uint32_t nphysout,
jack_nframes_t initial_length)
nframes_t initial_length)
{
Session *new_session;
int x;
Expand Down Expand Up @@ -2317,7 +2317,7 @@ ARDOUR_UI::reconnect_to_jack ()
}

void
ARDOUR_UI::set_jack_buffer_size (jack_nframes_t nframes)
ARDOUR_UI::set_jack_buffer_size (nframes_t nframes)
{
engine->request_buffer_size (nframes);
update_sample_rate (0);
Expand Down
10 changes: 5 additions & 5 deletions gtk2_ardour/ardour_ui.h
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI
ARDOUR::AutoConnectOption output_connect,
uint32_t nphysin,
uint32_t nphysout,
jack_nframes_t initial_length);
nframes_t initial_length);
bool session_is_new() const { return _session_is_new; }

ARDOUR::Session* the_session() { return session; }
Expand Down Expand Up @@ -159,7 +159,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI
static sigc::signal<void,bool> Blink;
static sigc::signal<void> RapidScreenUpdate;
static sigc::signal<void> SuperRapidScreenUpdate;
static sigc::signal<void,jack_nframes_t> Clock;
static sigc::signal<void,nframes_t> Clock;

/* this is a helper function to centralize the (complex) logic for
blinking rec-enable buttons.
Expand All @@ -179,7 +179,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI
void save_ardour_state ();
gboolean configure_handler (GdkEventConfigure* conf);

void do_transport_locate (jack_nframes_t position);
void do_transport_locate (nframes_t position);
void halt_on_xrun_message ();

AudioClock primary_clock;
Expand Down Expand Up @@ -497,7 +497,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI

Gtk::Label sample_rate_label;
Gtk::EventBox sample_rate_box;
void update_sample_rate (jack_nframes_t);
void update_sample_rate (nframes_t);

gint every_second ();
gint every_point_one_seconds ();
Expand Down Expand Up @@ -640,7 +640,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI

void disconnect_from_jack ();
void reconnect_to_jack ();
void set_jack_buffer_size (jack_nframes_t);
void set_jack_buffer_size (nframes_t);

Gtk::MenuItem* jack_disconnect_item;
Gtk::MenuItem* jack_reconnect_item;
Expand Down
18 changes: 9 additions & 9 deletions gtk2_ardour/ardour_ui_ed.cc
Original file line number Diff line number Diff line change
Expand Up @@ -149,23 +149,23 @@ ARDOUR_UI::install_actions ()

RadioAction::Group jack_latency_group;

act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency32"), X_("32"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 32));
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency32"), X_("32"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 32));
ActionManager::jack_sensitive_actions.push_back (act);
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency64"), X_("64"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 64));
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency64"), X_("64"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 64));
ActionManager::jack_sensitive_actions.push_back (act);
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency128"), X_("128"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 128));
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency128"), X_("128"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 128));
ActionManager::jack_sensitive_actions.push_back (act);
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency256"), X_("256"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 256));
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency256"), X_("256"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 256));
ActionManager::jack_sensitive_actions.push_back (act);
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency512"), X_("512"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 512));
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency512"), X_("512"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 512));
ActionManager::jack_sensitive_actions.push_back (act);
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency1024"), X_("1024"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 1024));
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency1024"), X_("1024"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 1024));
ActionManager::jack_sensitive_actions.push_back (act);
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency2048"), X_("2048"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 2048));
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency2048"), X_("2048"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 2048));
ActionManager::jack_sensitive_actions.push_back (act);
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency4096"), X_("4096"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 4096));
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency4096"), X_("4096"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 4096));
ActionManager::jack_sensitive_actions.push_back (act);
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency8192"), X_("8192"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (jack_nframes_t) 8192));
act = ActionManager::register_radio_action (jack_actions, jack_latency_group, X_("JACKLatency8192"), X_("8192"), bind (mem_fun(*this, &ARDOUR_UI::set_jack_buffer_size), (nframes_t) 8192));
ActionManager::jack_sensitive_actions.push_back (act);

/* these actions are intended to be shared across all windows */
Expand Down
Loading

0 comments on commit 93c7aeb

Please sign in to comment.