summaryrefslogtreecommitdiff
path: root/libs/ardour/ardour
diff options
context:
space:
mode:
Diffstat (limited to 'libs/ardour/ardour')
-rw-r--r--libs/ardour/ardour/ardour.h2
-rw-r--r--libs/ardour/ardour/audio_diskstream.h20
-rw-r--r--libs/ardour/ardour/audio_track.h20
-rw-r--r--libs/ardour/ardour/audio_unit.h6
-rw-r--r--libs/ardour/ardour/audioengine.h52
-rw-r--r--libs/ardour/ardour/audiofilesource.h10
-rw-r--r--libs/ardour/ardour/audioplaylist.h6
-rw-r--r--libs/ardour/ardour/audioregion.h50
-rw-r--r--libs/ardour/ardour/audiosource.h33
-rw-r--r--libs/ardour/ardour/auditioner.h6
-rw-r--r--libs/ardour/ardour/configuration_vars.h8
-rw-r--r--libs/ardour/ardour/coreaudiosource.h11
-rw-r--r--libs/ardour/ardour/crossfade.h40
-rw-r--r--libs/ardour/ardour/destructive_filesource.h20
-rw-r--r--libs/ardour/ardour/diskstream.h66
-rw-r--r--libs/ardour/ardour/export.h22
-rw-r--r--libs/ardour/ardour/gain.h8
-rw-r--r--libs/ardour/ardour/insert.h22
-rw-r--r--libs/ardour/ardour/io.h38
-rw-r--r--libs/ardour/ardour/ladspa_plugin.h14
-rw-r--r--libs/ardour/ardour/location.h28
-rw-r--r--libs/ardour/ardour/mix.h32
-rw-r--r--libs/ardour/ardour/panner.h28
-rw-r--r--libs/ardour/ardour/peak.h4
-rw-r--r--libs/ardour/ardour/playlist.h44
-rw-r--r--libs/ardour/ardour/plugin.h6
-rw-r--r--libs/ardour/ardour/port.h18
-rw-r--r--libs/ardour/ardour/redirect.h10
-rw-r--r--libs/ardour/ardour/region.h74
-rw-r--r--libs/ardour/ardour/region_factory.h12
-rw-r--r--libs/ardour/ardour/route.h40
-rw-r--r--libs/ardour/ardour/send.h2
-rw-r--r--libs/ardour/ardour/session.h206
-rw-r--r--libs/ardour/ardour/slave.h28
-rw-r--r--libs/ardour/ardour/sndfilesource.h16
-rw-r--r--libs/ardour/ardour/source_factory.h2
-rw-r--r--libs/ardour/ardour/tempo.h64
-rw-r--r--libs/ardour/ardour/track.h22
-rw-r--r--libs/ardour/ardour/types.h35
-rw-r--r--libs/ardour/ardour/utils.h2
-rw-r--r--libs/ardour/ardour/vst_plugin.h6
41 files changed, 569 insertions, 564 deletions
diff --git a/libs/ardour/ardour/ardour.h b/libs/ardour/ardour/ardour.h
index 668907ea8c..85dad103d4 100644
--- a/libs/ardour/ardour/ardour.h
+++ b/libs/ardour/ardour/ardour.h
@@ -43,7 +43,7 @@ namespace ARDOUR {
extern OSC* osc;
- static const jack_nframes_t max_frames = JACK_MAX_FRAMES;
+ static const nframes_t max_frames = JACK_MAX_FRAMES;
int init (bool with_vst, bool try_optimization);
int cleanup ();
diff --git a/libs/ardour/ardour/audio_diskstream.h b/libs/ardour/ardour/audio_diskstream.h
index a43c198ff2..4dee5e9b00 100644
--- a/libs/ardour/ardour/audio_diskstream.h
+++ b/libs/ardour/ardour/audio_diskstream.h
@@ -131,7 +131,7 @@ class AudioDiskstream : public Diskstream
}
}
- static void swap_by_ptr (Sample *first, Sample *last, jack_nframes_t n) {
+ static void swap_by_ptr (Sample *first, Sample *last, nframes_t n) {
while (n--) {
Sample tmp = *first;
*first++ = *last;
@@ -151,22 +151,22 @@ class AudioDiskstream : public Diskstream
void set_pending_overwrite(bool);
int overwrite_existing_buffers ();
- void set_block_size (jack_nframes_t);
- int internal_playback_seek (jack_nframes_t distance);
- int can_internal_playback_seek (jack_nframes_t distance);
+ void set_block_size (nframes_t);
+ int internal_playback_seek (nframes_t distance);
+ int can_internal_playback_seek (nframes_t distance);
int rename_write_sources ();
void reset_write_sources (bool, bool force = false);
void non_realtime_input_change ();
protected:
friend class Auditioner;
- int seek (jack_nframes_t which_sample, bool complete_refill = false);
+ int seek (nframes_t which_sample, bool complete_refill = false);
protected:
friend class AudioTrack;
- int process (jack_nframes_t transport_frame, jack_nframes_t nframes, jack_nframes_t offset, bool can_record, bool rec_monitors_input);
- bool commit (jack_nframes_t nframes);
+ int process (nframes_t transport_frame, nframes_t nframes, nframes_t offset, bool can_record, bool rec_monitors_input);
+ bool commit (nframes_t nframes);
private:
@@ -197,7 +197,7 @@ class AudioDiskstream : public Diskstream
RingBufferNPT<CaptureTransition> * capture_transition_buf;
// the following are used in the butler thread only
- jack_nframes_t curr_capture_cnt;
+ nframes_t curr_capture_cnt;
};
/* The two central butler operations */
@@ -207,7 +207,7 @@ class AudioDiskstream : public Diskstream
int do_refill_with_alloc();
int read (Sample* buf, Sample* mixdown_buffer, float* gain_buffer,
- jack_nframes_t& start, jack_nframes_t cnt,
+ nframes_t& start, nframes_t cnt,
ChannelInfo& channel_info, int channel, bool reversed);
void finish_capture (bool rec_monitors_input);
@@ -227,7 +227,7 @@ class AudioDiskstream : public Diskstream
int use_pending_capture_data (XMLNode& node);
void get_input_sources ();
- void check_record_status (jack_nframes_t transport_frame, jack_nframes_t nframes, bool can_record);
+ void check_record_status (nframes_t transport_frame, nframes_t nframes, bool can_record);
void set_align_style_from_io();
void setup_destructive_playlist ();
void use_destructive_playlist ();
diff --git a/libs/ardour/ardour/audio_track.h b/libs/ardour/ardour/audio_track.h
index 33010dc880..a074732c39 100644
--- a/libs/ardour/ardour/audio_track.h
+++ b/libs/ardour/ardour/audio_track.h
@@ -37,35 +37,35 @@ class AudioTrack : public Track
AudioTrack (Session&, const XMLNode&);
~AudioTrack ();
- int roll (jack_nframes_t nframes, jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t offset, int declick, bool can_record, bool rec_monitors_input);
+ int roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame,
+ nframes_t offset, int declick, bool can_record, bool rec_monitors_input);
- int no_roll (jack_nframes_t nframes, jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t offset, bool state_changing, bool can_record, bool rec_monitors_input);
+ int no_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame,
+ nframes_t offset, bool state_changing, bool can_record, bool rec_monitors_input);
- int silent_roll (jack_nframes_t nframes, jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t offset, bool can_record, bool rec_monitors_input);
+ int silent_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame,
+ nframes_t offset, bool can_record, bool rec_monitors_input);
boost::shared_ptr<AudioDiskstream> audio_diskstream() const;
int use_diskstream (string name);
int use_diskstream (const PBD::ID& id);
- int export_stuff (vector<Sample*>& buffers, uint32_t nbufs, jack_nframes_t nframes, jack_nframes_t end_frame);
+ int export_stuff (vector<Sample*>& buffers, uint32_t nbufs, nframes_t nframes, nframes_t end_frame);
void freeze (InterThreadInfo&);
void unfreeze ();
void bounce (InterThreadInfo&);
- void bounce_range (jack_nframes_t start, jack_nframes_t end, InterThreadInfo&);
+ void bounce_range (nframes_t start, nframes_t end, InterThreadInfo&);
int set_state(const XMLNode& node);
protected:
XMLNode& state (bool full);
- void passthru_silence (jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t nframes, jack_nframes_t offset, int declick,
+ void passthru_silence (nframes_t start_frame, nframes_t end_frame,
+ nframes_t nframes, nframes_t offset, int declick,
bool meter);
uint32_t n_process_buffers ();
diff --git a/libs/ardour/ardour/audio_unit.h b/libs/ardour/ardour/audio_unit.h
index a007f41d2b..aa7c34a2d2 100644
--- a/libs/ardour/ardour/audio_unit.h
+++ b/libs/ardour/ardour/audio_unit.h
@@ -54,7 +54,7 @@ class AUPlugin : public ARDOUR::Plugin
const char * maker () const;
uint32_t parameter_count () const;
float default_value (uint32_t port);
- jack_nframes_t latency () const;
+ nframes_t latency () const;
void set_parameter (uint32_t which, float val);
float get_parameter (uint32_t which) const;
@@ -62,9 +62,9 @@ class AUPlugin : public ARDOUR::Plugin
uint32_t nth_parameter (uint32_t which, bool& ok) const;
void activate ();
void deactivate ();
- void set_block_size (jack_nframes_t nframes);
+ void set_block_size (nframes_t nframes);
- int connect_and_run (vector<Sample*>& bufs, uint32_t maxbuf, int32_t& in, int32_t& out, jack_nframes_t nframes, jack_nframes_t offset);
+ int connect_and_run (vector<Sample*>& bufs, uint32_t maxbuf, int32_t& in, int32_t& out, nframes_t nframes, nframes_t offset);
std::set<uint32_t> automatable() const;
void store_state (ARDOUR::PluginState&);
void restore_state (ARDOUR::PluginState&);
diff --git a/libs/ardour/ardour/audioengine.h b/libs/ardour/ardour/audioengine.h
index 36a08e237e..e53eb8a85e 100644
--- a/libs/ardour/ardour/audioengine.h
+++ b/libs/ardour/ardour/audioengine.h
@@ -67,30 +67,30 @@ class AudioEngine : public sigc::trackable
Glib::Mutex& process_lock() { return _process_lock; }
- jack_nframes_t frame_rate();
- jack_nframes_t frames_per_cycle();
+ nframes_t frame_rate();
+ nframes_t frames_per_cycle();
int usecs_per_cycle () const { return _usecs_per_cycle; }
- bool get_sync_offset (jack_nframes_t& offset) const;
+ bool get_sync_offset (nframes_t& offset) const;
- jack_nframes_t frames_since_cycle_start () {
+ nframes_t frames_since_cycle_start () {
if (!_running || !_jack) return 0;
return jack_frames_since_cycle_start (_jack);
}
- jack_nframes_t frame_time () {
+ nframes_t frame_time () {
if (!_running || !_jack) return 0;
return jack_frame_time (_jack);
}
- jack_nframes_t transport_frame () const {
+ nframes_t transport_frame () const {
if (!_running || !_jack) return 0;
return jack_get_current_transport_frame (_jack);
}
- int request_buffer_size (jack_nframes_t);
+ int request_buffer_size (nframes_t);
- jack_nframes_t set_monitor_check_interval (jack_nframes_t);
+ nframes_t set_monitor_check_interval (nframes_t);
float get_cpu_load() {
if (!_running || !_jack) return 0;
@@ -134,7 +134,7 @@ class AudioEngine : public sigc::trackable
return get_nth_physical (n, JackPortIsOutput);
}
- jack_nframes_t get_port_total_latency (const Port&);
+ nframes_t get_port_total_latency (const Port&);
void update_total_latencies ();
/* the caller may not delete the object pointed to by
@@ -152,7 +152,7 @@ class AudioEngine : public sigc::trackable
void transport_start ();
void transport_stop ();
- void transport_locate (jack_nframes_t);
+ void transport_locate (nframes_t);
TransportState transport_state ();
int reset_timebase ();
@@ -166,7 +166,7 @@ class AudioEngine : public sigc::trackable
the regular process() call to session->process() is not made.
*/
- sigc::signal<int,jack_nframes_t> Freewheel;
+ sigc::signal<int,nframes_t> Freewheel;
sigc::signal<void> Xrun;
@@ -176,7 +176,7 @@ class AudioEngine : public sigc::trackable
/* this signal is emitted if the sample rate changes */
- sigc::signal<void,jack_nframes_t> SampleRateChanged;
+ sigc::signal<void,nframes_t> SampleRateChanged;
/* this signal is sent if JACK ever disconnects us */
@@ -202,21 +202,21 @@ class AudioEngine : public sigc::trackable
bool session_remove_pending;
bool _running;
bool _has_run;
- jack_nframes_t _buffer_size;
- jack_nframes_t _frame_rate;
- jack_nframes_t monitor_check_interval;
- jack_nframes_t last_monitor_check;
- jack_nframes_t _processed_frames;
+ nframes_t _buffer_size;
+ nframes_t _frame_rate;
+ nframes_t monitor_check_interval;
+ nframes_t last_monitor_check;
+ nframes_t _processed_frames;
bool _freewheeling;
bool _freewheel_thread_registered;
- sigc::slot<int,jack_nframes_t> freewheel_action;
+ sigc::slot<int,nframes_t> freewheel_action;
bool reconnect_on_halt;
int _usecs_per_cycle;
typedef std::set<Port*> Ports;
SerializedRCUManager<Ports> ports;
- int process_callback (jack_nframes_t nframes);
+ int process_callback (nframes_t nframes);
void remove_all_ports ();
typedef std::pair<std::string,std::string> PortConnection;
@@ -229,17 +229,17 @@ class AudioEngine : public sigc::trackable
static int _xrun_callback (void *arg);
static int _graph_order_callback (void *arg);
- static int _process_callback (jack_nframes_t nframes, void *arg);
- static int _sample_rate_callback (jack_nframes_t nframes, void *arg);
- static int _bufsize_callback (jack_nframes_t nframes, void *arg);
- static void _jack_timebase_callback (jack_transport_state_t, jack_nframes_t, jack_position_t*, int, void*);
+ static int _process_callback (nframes_t nframes, 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 _jack_sync_callback (jack_transport_state_t, jack_position_t*, void *arg);
static void _freewheel_callback (int , void *arg);
- void jack_timebase_callback (jack_transport_state_t, jack_nframes_t, jack_position_t*, int);
+ void jack_timebase_callback (jack_transport_state_t, nframes_t, jack_position_t*, int);
int jack_sync_callback (jack_transport_state_t, jack_position_t*);
- int jack_bufsize_callback (jack_nframes_t);
- int jack_sample_rate_callback (jack_nframes_t);
+ int jack_bufsize_callback (nframes_t);
+ int jack_sample_rate_callback (nframes_t);
static void halted (void *);
diff --git a/libs/ardour/ardour/audiofilesource.h b/libs/ardour/ardour/audiofilesource.h
index 507a464421..fb32d892d2 100644
--- a/libs/ardour/ardour/audiofilesource.h
+++ b/libs/ardour/ardour/audiofilesource.h
@@ -65,12 +65,12 @@ class AudioFileSource : public AudioSource {
for files used in destructive recording.
*/
- virtual jack_nframes_t last_capture_start_frame() const { return 0; }
- virtual void mark_capture_start (jack_nframes_t) {}
+ virtual nframes_t last_capture_start_frame() const { return 0; }
+ virtual void mark_capture_start (nframes_t) {}
virtual void mark_capture_end () {}
virtual void clear_capture_marks() {}
- virtual int update_header (jack_nframes_t when, struct tm&, time_t) = 0;
+ virtual int update_header (nframes_t when, struct tm&, time_t) = 0;
virtual int flush_header () = 0;
int move_to_trash (const string trash_dir_name);
@@ -86,7 +86,7 @@ class AudioFileSource : public AudioSource {
static void set_bwf_serial_number (int);
static void set_search_path (string);
- static void set_header_position_offset (jack_nframes_t offset );
+ static void set_header_position_offset (nframes_t offset );
static sigc::signal<void> HeaderPositionOffsetChanged;
@@ -132,7 +132,7 @@ class AudioFileSource : public AudioSource {
static uint64_t header_position_offset;
- virtual void set_timeline_position (jack_nframes_t pos);
+ virtual void set_timeline_position (nframes_t pos);
virtual void set_header_timeline_position () = 0;
bool find (std::string path, bool must_exist, bool& is_new);
diff --git a/libs/ardour/ardour/audioplaylist.h b/libs/ardour/ardour/audioplaylist.h
index 6a52f1c16f..341b08930c 100644
--- a/libs/ardour/ardour/audioplaylist.h
+++ b/libs/ardour/ardour/audioplaylist.h
@@ -56,11 +56,11 @@ class AudioPlaylist : public ARDOUR::Playlist
AudioPlaylist (Session&, const XMLNode&, bool hidden = false);
AudioPlaylist (Session&, string name, bool hidden = false);
AudioPlaylist (const AudioPlaylist&, string name, bool hidden = false);
- AudioPlaylist (const AudioPlaylist&, jack_nframes_t start, jack_nframes_t cnt, string name, bool hidden = false);
+ AudioPlaylist (const AudioPlaylist&, nframes_t start, nframes_t cnt, string name, bool hidden = false);
void clear (bool with_save = true);
- jack_nframes_t read (Sample *dst, Sample *mixdown, float *gain_buffer, jack_nframes_t start, jack_nframes_t cnt, uint32_t chan_n=0);
+ nframes_t read (Sample *dst, Sample *mixdown, float *gain_buffer, nframes_t start, nframes_t cnt, uint32_t chan_n=0);
int set_state (const XMLNode&);
UndoAction get_memento() const;
@@ -68,7 +68,7 @@ class AudioPlaylist : public ARDOUR::Playlist
sigc::signal<void,Crossfade *> NewCrossfade;
template<class T> void foreach_crossfade (T *t, void (T::*func)(Crossfade *));
- void crossfades_at (jack_nframes_t frame, Crossfades&);
+ void crossfades_at (nframes_t frame, Crossfades&);
template<class T> void apply_to_history (T& obj, void (T::*method)(const ARDOUR::StateManager::StateMap&, state_id_t)) {
RegionLock rlock (this);
diff --git a/libs/ardour/ardour/audioregion.h b/libs/ardour/ardour/audioregion.h
index 06115aa8b0..d1d7c6e5fb 100644
--- a/libs/ardour/ardour/audioregion.h
+++ b/libs/ardour/ardour/audioregion.h
@@ -90,24 +90,24 @@ class AudioRegion : public Region
Curve& fade_out() { return _fade_out; }
Curve& envelope() { return _envelope; }
- jack_nframes_t read_peaks (PeakData *buf, jack_nframes_t npeaks,
- jack_nframes_t offset, jack_nframes_t cnt,
+ nframes_t read_peaks (PeakData *buf, nframes_t npeaks,
+ nframes_t offset, nframes_t cnt,
uint32_t chan_n=0, double samples_per_unit= 1.0) const;
- virtual jack_nframes_t read_at (Sample *buf, Sample *mixdown_buf,
- float *gain_buf, jack_nframes_t position, jack_nframes_t cnt,
+ virtual nframes_t read_at (Sample *buf, Sample *mixdown_buf,
+ float *gain_buf, nframes_t position, nframes_t cnt,
uint32_t chan_n = 0,
- jack_nframes_t read_frames = 0,
- jack_nframes_t skip_frames = 0) const;
+ nframes_t read_frames = 0,
+ nframes_t skip_frames = 0) const;
- jack_nframes_t master_read_at (Sample *buf, Sample *mixdown_buf,
+ nframes_t master_read_at (Sample *buf, Sample *mixdown_buf,
float *gain_buf,
- jack_nframes_t position, jack_nframes_t cnt, uint32_t chan_n=0) const;
+ nframes_t position, nframes_t cnt, uint32_t chan_n=0) const;
XMLNode& state (bool);
int set_state (const XMLNode&);
- static void set_default_fade (float steepness, jack_nframes_t len);
+ static void set_default_fade (float steepness, nframes_t len);
enum FadeShape {
Linear,
@@ -119,13 +119,13 @@ class AudioRegion : public Region
void set_fade_in_active (bool yn);
void set_fade_in_shape (FadeShape);
- void set_fade_in_length (jack_nframes_t);
- void set_fade_in (FadeShape, jack_nframes_t);
+ void set_fade_in_length (nframes_t);
+ void set_fade_in (FadeShape, nframes_t);
void set_fade_out_active (bool yn);
void set_fade_out_shape (FadeShape);
- void set_fade_out_length (jack_nframes_t);
- void set_fade_out (FadeShape, jack_nframes_t);
+ void set_fade_out_length (nframes_t);
+ void set_fade_out (FadeShape, nframes_t);
void set_envelope_active (bool yn);
@@ -153,10 +153,10 @@ class AudioRegion : public Region
private:
friend class RegionFactory;
- AudioRegion (boost::shared_ptr<AudioSource>, jack_nframes_t start, jack_nframes_t length);
- AudioRegion (boost::shared_ptr<AudioSource>, jack_nframes_t start, jack_nframes_t length, const string& name, layer_t = 0, Region::Flag flags = Region::DefaultFlags);
- AudioRegion (SourceList &, jack_nframes_t start, jack_nframes_t length, const string& name, layer_t = 0, Region::Flag flags = Region::DefaultFlags);
- AudioRegion (boost::shared_ptr<const AudioRegion>, jack_nframes_t start, jack_nframes_t length, const string& name, layer_t = 0, Region::Flag flags = Region::DefaultFlags);
+ AudioRegion (boost::shared_ptr<AudioSource>, nframes_t start, nframes_t length);
+ AudioRegion (boost::shared_ptr<AudioSource>, nframes_t start, nframes_t length, const string& name, layer_t = 0, Region::Flag flags = Region::DefaultFlags);
+ AudioRegion (SourceList &, nframes_t start, nframes_t length, const string& name, layer_t = 0, Region::Flag flags = Region::DefaultFlags);
+ AudioRegion (boost::shared_ptr<const AudioRegion>, nframes_t start, nframes_t length, const string& name, layer_t = 0, Region::Flag flags = Region::DefaultFlags);
AudioRegion (boost::shared_ptr<const AudioRegion>);
AudioRegion (boost::shared_ptr<AudioSource>, const XMLNode&);
AudioRegion (SourceList &, const XMLNode&);
@@ -173,16 +173,16 @@ class AudioRegion : public Region
void recompute_gain_at_end ();
void recompute_gain_at_start ();
- jack_nframes_t _read_at (const SourceList&, Sample *buf, Sample *mixdown_buffer,
- float *gain_buffer, jack_nframes_t position, jack_nframes_t cnt,
+ nframes_t _read_at (const SourceList&, Sample *buf, Sample *mixdown_buffer,
+ float *gain_buffer, nframes_t position, nframes_t cnt,
uint32_t chan_n = 0,
- jack_nframes_t read_frames = 0,
- jack_nframes_t skip_frames = 0) const;
+ nframes_t read_frames = 0,
+ nframes_t skip_frames = 0) const;
- bool verify_start (jack_nframes_t position);
- bool verify_length (jack_nframes_t position);
- bool verify_start_mutable (jack_nframes_t& start);
- bool verify_start_and_length (jack_nframes_t start, jack_nframes_t length);
+ bool verify_start (nframes_t position);
+ bool verify_length (nframes_t position);
+ bool verify_start_mutable (nframes_t& start);
+ bool verify_start_and_length (nframes_t start, nframes_t length);
void recompute_at_start ();
void recompute_at_end ();
diff --git a/libs/ardour/ardour/audiosource.h b/libs/ardour/ardour/audiosource.h
index d598e424ac..d2d23bcfab 100644
--- a/libs/ardour/ardour/audiosource.h
+++ b/libs/ardour/ardour/audiosource.h
@@ -42,7 +42,7 @@ using std::string;
namespace ARDOUR {
-const jack_nframes_t frames_per_peak = 256;
+const nframes_t frames_per_peak = 256;
class AudioSource : public Source
{
@@ -56,18 +56,18 @@ class AudioSource : public Source
so its here in AudioSource for now.
*/
- virtual jack_nframes_t natural_position() const { return 0; }
+ virtual nframes_t natural_position() const { return 0; }
/* returns the number of items in this `audio_source' */
- virtual jack_nframes_t length() const {
+ virtual nframes_t length() const {
return _length;
}
- virtual jack_nframes_t available_peaks (double zoom) const;
+ virtual nframes_t available_peaks (double zoom) const;
- virtual jack_nframes_t read (Sample *dst, jack_nframes_t start, jack_nframes_t cnt) const;
- virtual jack_nframes_t write (Sample *src, jack_nframes_t cnt);
+ virtual nframes_t read (Sample *dst, nframes_t start, nframes_t cnt) const;
+ virtual nframes_t write (Sample *src, nframes_t cnt);
virtual float sample_rate () const = 0;
@@ -80,12 +80,12 @@ class AudioSource : public Source
uint32_t read_data_count() const { return _read_data_count; }
uint32_t write_data_count() const { return _write_data_count; }
- int read_peaks (PeakData *peaks, jack_nframes_t npeaks, jack_nframes_t start, jack_nframes_t cnt, double samples_per_unit) const;
+ int read_peaks (PeakData *peaks, nframes_t npeaks, nframes_t start, nframes_t cnt, double samples_per_unit) const;
int build_peaks ();
bool peaks_ready (sigc::slot<void>, sigc::connection&) const;
mutable sigc::signal<void> PeaksReady;
- mutable sigc::signal<void,jack_nframes_t,jack_nframes_t> PeakRangeReady;
+ mutable sigc::signal<void,nframes_t,nframes_t> PeakRangeReady;
XMLNode& get_state ();
int set_state (const XMLNode&);
@@ -94,6 +94,7 @@ class AudioSource : public Source
static void stop_peak_thread ();
int rename_peakfile (std::string newpath);
+ void touch_peakfile ();
static void set_build_missing_peakfiles (bool yn) {
_build_missing_peakfiles = yn;
@@ -109,7 +110,7 @@ class AudioSource : public Source
bool _peaks_built;
mutable Glib::Mutex _lock;
- jack_nframes_t _length;
+ nframes_t _length;
bool next_peak_clear_should_notify;
string peakpath;
string _captured_for;
@@ -120,14 +121,14 @@ class AudioSource : public Source
int initialize_peakfile (bool newfile, string path);
void build_peaks_from_scratch ();
- int do_build_peak (jack_nframes_t, jack_nframes_t);
+ int do_build_peak (nframes_t, nframes_t);
- virtual jack_nframes_t read_unlocked (Sample *dst, jack_nframes_t start, jack_nframes_t cnt) const = 0;
- virtual jack_nframes_t write_unlocked (Sample *dst, jack_nframes_t cnt) = 0;
+ virtual nframes_t read_unlocked (Sample *dst, nframes_t start, nframes_t cnt) const = 0;
+ virtual nframes_t write_unlocked (Sample *dst, nframes_t cnt) = 0;
virtual string peak_path(string audio_path) = 0;
virtual string old_peak_path(string audio_path) = 0;
- void update_length (jack_nframes_t pos, jack_nframes_t cnt);
+ void update_length (nframes_t pos, nframes_t cnt);
static pthread_t peak_thread;
static bool have_peak_thread;
@@ -149,10 +150,10 @@ class AudioSource : public Source
static void clear_queue_for_peaks ();
struct PeakBuildRecord {
- jack_nframes_t frame;
- jack_nframes_t cnt;
+ nframes_t frame;
+ nframes_t cnt;
- PeakBuildRecord (jack_nframes_t f, jack_nframes_t c)
+ PeakBuildRecord (nframes_t f, nframes_t c)
: frame (f), cnt (c) {}
PeakBuildRecord (const PeakBuildRecord& other) {
frame = other.frame;
diff --git a/libs/ardour/ardour/auditioner.h b/libs/ardour/ardour/auditioner.h
index 424ede0009..e6091cfba0 100644
--- a/libs/ardour/ardour/auditioner.h
+++ b/libs/ardour/ardour/auditioner.h
@@ -45,7 +45,7 @@ class Auditioner : public AudioTrack
ARDOUR::AudioPlaylist& prepare_playlist ();
void audition_current_playlist ();
- int play_audition (jack_nframes_t nframes);
+ int play_audition (nframes_t nframes);
void cancel_audition () {
g_atomic_int_set (&_active, 0);
@@ -55,10 +55,10 @@ class Auditioner : public AudioTrack
private:
boost::shared_ptr<AudioRegion> the_region;
- jack_nframes_t current_frame;
+ nframes_t current_frame;
mutable gint _active;
Glib::Mutex lock;
- jack_nframes_t length;
+ nframes_t length;
void drop_ports ();
static void *_drop_ports (void *);
diff --git a/libs/ardour/ardour/configuration_vars.h b/libs/ardour/ardour/configuration_vars.h
index a3898feef6..8cd66decb1 100644
--- a/libs/ardour/ardour/configuration_vars.h
+++ b/libs/ardour/ardour/configuration_vars.h
@@ -76,10 +76,10 @@ CONFIG_VARIABLE (float, shuttle_speed_threshold, "shuttle-speed-threshold", 5.0f
CONFIG_VARIABLE (float, smpte_frames_per_second, "smpte-frames-per-second", 30.0f)
CONFIG_VARIABLE (float, video_pullup, "video-pullup", 0.0f)
CONFIG_VARIABLE (bool, smpte_drop_frames, "smpte-drop-frames", false)
-CONFIG_VARIABLE (jack_nframes_t, preroll, "preroll", 0)
-CONFIG_VARIABLE (jack_nframes_t, postroll, "postroll", 0)
-CONFIG_VARIABLE (jack_nframes_t, over_length_short, "over-length-short", 2)
-CONFIG_VARIABLE (jack_nframes_t, over_length_long, "over-length-long", 10)
+CONFIG_VARIABLE (nframes_t, preroll, "preroll", 0)
+CONFIG_VARIABLE (nframes_t, postroll, "postroll", 0)
+CONFIG_VARIABLE (nframes_t, over_length_short, "over-length-short", 2)
+CONFIG_VARIABLE (nframes_t, over_length_long, "over-length-long", 10)
CONFIG_VARIABLE (bool, full_xfades_unmuted, "full-xfades-unmuted", true)
CONFIG_VARIABLE (float, short_xfade_seconds, "short-xfade-seconds", 0.015)
CONFIG_VARIABLE (SlaveSource, slave_source, "slave-source", None)
diff --git a/libs/ardour/ardour/coreaudiosource.h b/libs/ardour/ardour/coreaudiosource.h
index 49009caf53..668fe61102 100644
--- a/libs/ardour/ardour/coreaudiosource.h
+++ b/libs/ardour/ardour/coreaudiosource.h
@@ -33,24 +33,21 @@ class CoreAudioSource : public AudioFileSource {
~CoreAudioSource ();
float sample_rate() const;
- int update_header (jack_nframes_t when, struct tm&, time_t);
+ int update_header (nframes_t when, struct tm&, time_t);
int flush_header () {return 0;};
void set_header_timeline_position () {};
protected:
- jack_nframes_t read_unlocked (Sample *dst, jack_nframes_t start, jack_nframes_t cnt) const;
-
- jack_nframes_t write_unlocked (Sample *dst, jack_nframes_t cnt)
- { return 0; }
-
+ nframes_t read_unlocked (Sample *dst, nframes_t start, nframes_t cnt) const;
+ nframes_t write_unlocked (Sample *dst, nframes_t cnt) { return 0; }
private:
mutable CAAudioFile af;
uint16_t n_channels;
mutable float *tmpbuf;
- mutable jack_nframes_t tmpbufsize;
+ mutable nframes_t tmpbufsize;
mutable Glib::Mutex _tmpbuf_lock;
void init (const string &str);
diff --git a/libs/ardour/ardour/crossfade.h b/libs/ardour/ardour/crossfade.h
index ded41bbfda..7fd7323b36 100644
--- a/libs/ardour/ardour/crossfade.h
+++ b/libs/ardour/ardour/crossfade.h
@@ -46,8 +46,8 @@ struct CrossfadeState : public StateManager::State {
UndoAction fade_in_memento;
UndoAction fade_out_memento;
- jack_nframes_t position;
- jack_nframes_t length;
+ nframes_t position;
+ nframes_t length;
AnchorPoint anchor_point;
bool follow_overlap;
bool active;
@@ -65,8 +65,8 @@ class Crossfade : public PBD::StatefulDestructible, public StateManager
/* constructor for "fixed" xfades at each end of an internal overlap */
Crossfade (boost::shared_ptr<ARDOUR::AudioRegion> in, boost::shared_ptr<ARDOUR::AudioRegion> out,
- jack_nframes_t position,
- jack_nframes_t initial_length,
+ nframes_t position,
+ nframes_t initial_length,
AnchorPoint);
/* constructor for xfade between two regions that are overlapped in any way
@@ -93,11 +93,11 @@ class Crossfade : public PBD::StatefulDestructible, public StateManager
boost::shared_ptr<ARDOUR::AudioRegion> in() const { return _in; }
boost::shared_ptr<ARDOUR::AudioRegion> out() const { return _out; }
- jack_nframes_t read_at (Sample *buf, Sample *mixdown_buffer,
- float *gain_buffer, jack_nframes_t position, jack_nframes_t cnt,
+ nframes_t read_at (Sample *buf, Sample *mixdown_buffer,
+ float *gain_buffer, nframes_t position, nframes_t cnt,
uint32_t chan_n,
- jack_nframes_t read_frames = 0,
- jack_nframes_t skip_frames = 0);
+ nframes_t read_frames = 0,
+ nframes_t skip_frames = 0);
bool refresh ();
@@ -117,21 +117,21 @@ class Crossfade : public PBD::StatefulDestructible, public StateManager
return (_in == a && _out == b) || (_in == b && _out == a);
}
- jack_nframes_t length() const { return _length; }
- jack_nframes_t overlap_length() const;
- jack_nframes_t position() const { return _position; }
+ nframes_t length() const { return _length; }
+ nframes_t overlap_length() const;
+ nframes_t position() const { return _position; }
sigc::signal<void,Crossfade*> Invalidated;
- bool covers (jack_nframes_t frame) const {
+ bool covers (nframes_t frame) const {
return _position <= frame && frame < _position + _length;
}
- OverlapType coverage (jack_nframes_t start, jack_nframes_t end) const;
+ OverlapType coverage (nframes_t start, nframes_t end) const;
UndoAction get_memento() const;
- static void set_buffer_size (jack_nframes_t);
+ static void set_buffer_size (nframes_t);
bool active () const { return _active; }
void set_active (bool yn);
@@ -143,10 +143,10 @@ class Crossfade : public PBD::StatefulDestructible, public StateManager
Curve& fade_in() { return _fade_in; }
Curve& fade_out() { return _fade_out; }
- jack_nframes_t set_length (jack_nframes_t);
+ nframes_t set_length (nframes_t);
- static jack_nframes_t short_xfade_length() { return _short_xfade_length; }
- static void set_short_xfade_length (jack_nframes_t n);
+ static nframes_t short_xfade_length() { return _short_xfade_length; }
+ static void set_short_xfade_length (nframes_t n);
static Change ActiveChanged;
@@ -154,15 +154,15 @@ class Crossfade : public PBD::StatefulDestructible, public StateManager
friend struct CrossfadeComparePtr;
friend class AudioPlaylist;
- static jack_nframes_t _short_xfade_length;
+ static nframes_t _short_xfade_length;
boost::shared_ptr<ARDOUR::AudioRegion> _in;
boost::shared_ptr<ARDOUR::AudioRegion> _out;
bool _active;
bool _in_update;
OverlapType overlap_type;
- jack_nframes_t _length;
- jack_nframes_t _position;
+ nframes_t _length;
+ nframes_t _position;
AnchorPoint _anchor_point;
bool _follow_overlap;
bool _fixed;
diff --git a/libs/ardour/ardour/destructive_filesource.h b/libs/ardour/ardour/destructive_filesource.h
index fed84217e7..1e75042ce9 100644
--- a/libs/ardour/ardour/destructive_filesource.h
+++ b/libs/ardour/ardour/destructive_filesource.h
@@ -31,7 +31,7 @@ namespace ARDOUR {
class DestructiveFileSource : public SndFileSource {
public:
- DestructiveFileSource (Session&, std::string path, SampleFormat samp_format, HeaderFormat hdr_format, jack_nframes_t rate,
+ DestructiveFileSource (Session&, std::string path, SampleFormat samp_format, HeaderFormat hdr_format, nframes_t rate,
Flag flags = AudioFileSource::Flag (AudioFileSource::Writable));
DestructiveFileSource (Session&, std::string path, Flag flags);
@@ -39,34 +39,34 @@ class DestructiveFileSource : public SndFileSource {
DestructiveFileSource (Session&, const XMLNode&);
~DestructiveFileSource ();
- jack_nframes_t last_capture_start_frame() const;
- void mark_capture_start (jack_nframes_t);
+ nframes_t last_capture_start_frame() const;
+ void mark_capture_start (nframes_t);
void mark_capture_end ();
void clear_capture_marks();
XMLNode& get_state ();
- static void setup_standard_crossfades (jack_nframes_t sample_rate);
+ static void setup_standard_crossfades (nframes_t sample_rate);
protected:
- jack_nframes_t write_unlocked (Sample *src, jack_nframes_t cnt);
+ nframes_t write_unlocked (Sample *src, nframes_t cnt);
virtual void handle_header_position_change ();
private:
- static jack_nframes_t xfade_frames;
+ static nframes_t xfade_frames;
static gain_t* out_coefficient;
static gain_t* in_coefficient;
bool _capture_start;
bool _capture_end;
- jack_nframes_t capture_start_frame;
- jack_nframes_t file_pos; // unit is frames
+ nframes_t capture_start_frame;
+ nframes_t file_pos; // unit is frames
Sample* xfade_buf;
void init ();
- jack_nframes_t crossfade (Sample* data, jack_nframes_t cnt, int dir);
- void set_timeline_position (jack_nframes_t);
+ nframes_t crossfade (Sample* data, nframes_t cnt, int dir);
+ void set_timeline_position (nframes_t);
};
}
diff --git a/libs/ardour/ardour/diskstream.h b/libs/ardour/ardour/diskstream.h
index 08041d949f..d3b5d6dce4 100644
--- a/libs/ardour/ardour/diskstream.h
+++ b/libs/ardour/ardour/diskstream.h
@@ -83,8 +83,8 @@ class IO;
void set_align_style (AlignStyle);
void set_persistent_align_style (AlignStyle a) { _persistent_alignment_style = a; }
- jack_nframes_t roll_delay() const { return _roll_delay; }
- void set_roll_delay (jack_nframes_t);
+ nframes_t roll_delay() const { return _roll_delay; }
+ void set_roll_delay (nframes_t);
bool record_enabled() const { return g_atomic_int_get (&_record_enabled); }
virtual void set_record_enabled (bool yn) = 0;
@@ -109,14 +109,14 @@ class IO;
virtual int use_new_playlist () = 0;
virtual int use_copy_playlist () = 0;
- jack_nframes_t current_capture_start() const { return capture_start_frame; }
- jack_nframes_t current_capture_end() const { return capture_start_frame + capture_captured; }
- jack_nframes_t get_capture_start_frame (uint32_t n=0);
- jack_nframes_t get_captured_frames (uint32_t n=0);
+ nframes_t current_capture_start() const { return capture_start_frame; }
+ nframes_t current_capture_end() const { return capture_start_frame + capture_captured; }
+ nframes_t get_capture_start_frame (uint32_t n=0);
+ nframes_t get_captured_frames (uint32_t n=0);
uint32_t n_channels() { return _n_channels; }
- static jack_nframes_t disk_io_frames() { return disk_io_chunk_frames; }
+ 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; }
/* Stateful */
@@ -126,7 +126,7 @@ class IO;
// FIXME: makes sense for all diskstream types?
virtual void monitor_input (bool) {}
- jack_nframes_t capture_offset() const { return _capture_offset; }
+ nframes_t capture_offset() const { return _capture_offset; }
virtual void set_capture_offset ();
bool slaved() const { return _slaved; }
@@ -158,9 +158,9 @@ class IO;
virtual void set_pending_overwrite (bool) = 0;
virtual int overwrite_existing_buffers () = 0;
- virtual void set_block_size (jack_nframes_t) = 0;
- virtual int internal_playback_seek (jack_nframes_t distance) = 0;
- virtual int can_internal_playback_seek (jack_nframes_t distance) = 0;
+ virtual void set_block_size (nframes_t) = 0;
+ virtual int internal_playback_seek (nframes_t distance) = 0;
+ virtual int can_internal_playback_seek (nframes_t distance) = 0;
virtual int rename_write_sources () = 0;
virtual void reset_write_sources (bool, bool force = false) = 0;
virtual void non_realtime_input_change () = 0;
@@ -170,14 +170,14 @@ class IO;
protected:
friend class Auditioner;
- virtual int seek (jack_nframes_t which_sample, bool complete_refill = false) = 0;
+ virtual int seek (nframes_t which_sample, bool complete_refill = false) = 0;
protected:
friend class Track;
virtual void prepare ();
- virtual int process (jack_nframes_t transport_frame, jack_nframes_t nframes, jack_nframes_t offset, bool can_record, bool rec_monitors_input) = 0;
- virtual bool commit (jack_nframes_t nframes) = 0;
+ virtual int process (nframes_t transport_frame, nframes_t nframes, nframes_t offset, bool can_record, bool rec_monitors_input) = 0;
+ virtual bool commit (nframes_t nframes) = 0;
virtual void recover (); /* called if commit will not be called, but process was */
//private:
@@ -189,7 +189,7 @@ class IO;
struct CaptureTransition {
TransitionType type;
- jack_nframes_t capture_val; ///< The start or end file frame position
+ nframes_t capture_val; ///< The start or end file frame position
};
/* The two central butler operations */
@@ -228,12 +228,12 @@ class IO;
virtual int use_pending_capture_data (XMLNode& node) = 0;
virtual void get_input_sources () = 0;
- virtual void check_record_status (jack_nframes_t transport_frame, jack_nframes_t nframes, bool can_record) = 0;
+ virtual void check_record_status (nframes_t transport_frame, nframes_t nframes, bool can_record) = 0;
virtual void set_align_style_from_io() {}
virtual void setup_destructive_playlist () = 0;
virtual void use_destructive_playlist () = 0;
- static jack_nframes_t disk_io_chunk_frames;
+ static nframes_t disk_io_chunk_frames;
vector<CaptureInfo*> capture_info;
Glib::Mutex capture_info_lock;
@@ -253,34 +253,34 @@ class IO;
bool _seek_required;
bool force_refill;
- jack_nframes_t capture_start_frame;
- jack_nframes_t capture_captured;
+ nframes_t capture_start_frame;
+ nframes_t capture_captured;
bool was_recording;
- jack_nframes_t adjust_capture_position;
- jack_nframes_t _capture_offset;
- jack_nframes_t _roll_delay;
- jack_nframes_t first_recordable_frame;
- jack_nframes_t last_recordable_frame;
+ nframes_t adjust_capture_position;
+ nframes_t _capture_offset;
+ nframes_t _roll_delay;
+ nframes_t first_recordable_frame;
+ nframes_t last_recordable_frame;
int last_possibly_recording;
AlignStyle _alignment_style;
bool _scrubbing;
bool _slaved;
bool _processed;
Location* loop_location;
- jack_nframes_t overwrite_frame;
+ nframes_t overwrite_frame;
off_t overwrite_offset;
bool pending_overwrite;
bool overwrite_queued;
IOChange input_change_pending;
- jack_nframes_t wrap_buffer_size;
- jack_nframes_t speed_buffer_size;
+ nframes_t wrap_buffer_size;
+ nframes_t speed_buffer_size;
uint64_t last_phase;
uint64_t phi;
- jack_nframes_t file_frame;
- jack_nframes_t playback_sample;
- jack_nframes_t playback_distance;
+ nframes_t file_frame;
+ nframes_t playback_sample;
+ nframes_t playback_distance;
uint32_t _read_data_count;
uint32_t _write_data_count;
@@ -291,9 +291,9 @@ class IO;
Glib::Mutex state_lock;
- jack_nframes_t scrub_start;
- jack_nframes_t scrub_buffer_size;
- jack_nframes_t scrub_offset;
+ nframes_t scrub_start;
+ nframes_t scrub_buffer_size;
+ nframes_t scrub_offset;
sigc::connection ports_created_c;
sigc::connection plmod_connection;
diff --git a/libs/ardour/ardour/export.h b/libs/ardour/ardour/export.h
index 075464767e..f66acec893 100644
--- a/libs/ardour/ardour/export.h
+++ b/libs/ardour/ardour/export.h
@@ -34,43 +34,43 @@ namespace ARDOUR
void clear ();
- int prepare (jack_nframes_t blocksize, jack_nframes_t frame_rate);
+ int prepare (nframes_t blocksize, nframes_t frame_rate);
- int process (jack_nframes_t nframes);
+ int process (nframes_t nframes);
/* set by the user */
string path;
- jack_nframes_t sample_rate;
+ nframes_t sample_rate;
int src_quality;
SNDFILE* out;
uint32_t channels;
AudioExportPortMap port_map;
- jack_nframes_t start_frame;
- jack_nframes_t end_frame;
+ nframes_t start_frame;
+ nframes_t end_frame;
GDitherType dither_type;
bool do_freewheel;
/* used exclusively during export */
- jack_nframes_t frame_rate;
+ nframes_t frame_rate;
GDither dither;
float* dataF;
float* dataF2;
float* leftoverF;
- jack_nframes_t leftover_frames;
- jack_nframes_t max_leftover_frames;
+ nframes_t leftover_frames;
+ nframes_t max_leftover_frames;
void* output_data;
- jack_nframes_t out_samples_max;
+ nframes_t out_samples_max;
uint32_t sample_bytes;
uint32_t data_width;
- jack_nframes_t total_frames;
+ nframes_t total_frames;
SF_INFO sfinfo;
SRC_DATA src_data;
SRC_STATE* src_state;
- jack_nframes_t pos;
+ nframes_t pos;
sigc::connection freewheel_connection;
diff --git a/libs/ardour/ardour/gain.h b/libs/ardour/ardour/gain.h
index 3bd2d3be61..3613ea1a5a 100644
--- a/libs/ardour/ardour/gain.h
+++ b/libs/ardour/ardour/gain.h
@@ -32,10 +32,10 @@ struct Gain : public Curve {
Gain (const Gain&);
Gain& operator= (const Gain&);
- static void fill_linear_fade_in (Gain& curve, jack_nframes_t frames);
- static void fill_linear_volume_fade_in (Gain& curve, jack_nframes_t frames);
- static void fill_linear_fade_out (Gain& curve, jack_nframes_t frames);
- static void fill_linear_volume_fade_out (Gain& curve, jack_nframes_t frames);
+ 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);
};
diff --git a/libs/ardour/ardour/insert.h b/libs/ardour/ardour/insert.h
index c81d4e5761..ee07b7ebd3 100644
--- a/libs/ardour/ardour/insert.h
+++ b/libs/ardour/ardour/insert.h
@@ -53,7 +53,7 @@ class Insert : public Redirect
virtual ~Insert() { }
- virtual void run (vector<Sample *>& bufs, uint32_t nbufs, jack_nframes_t nframes, jack_nframes_t offset) = 0;
+ virtual void run (vector<Sample *>& bufs, uint32_t nbufs, nframes_t nframes, nframes_t offset) = 0;
virtual void activate () {}
virtual void deactivate () {}
@@ -75,9 +75,9 @@ class PortInsert : public Insert
int set_state(const XMLNode&);
void init ();
- void run (vector<Sample *>& bufs, uint32_t nbufs, jack_nframes_t nframes, jack_nframes_t offset);
+ void run (vector<Sample *>& bufs, uint32_t nbufs, nframes_t nframes, nframes_t offset);
- jack_nframes_t latency();
+ nframes_t latency();
uint32_t output_streams() const;
uint32_t input_streams() const;
@@ -113,12 +113,12 @@ class PluginInsert : public Insert
StateManager::State* state_factory (std::string why) const;
Change restore_state (StateManager::State&);
- void run (vector<Sample *>& bufs, uint32_t nbufs, jack_nframes_t nframes, jack_nframes_t offset);
- void silence (jack_nframes_t nframes, jack_nframes_t offset);
+ void run (vector<Sample *>& bufs, uint32_t nbufs, nframes_t nframes, nframes_t offset);
+ void silence (nframes_t nframes, nframes_t offset);
void activate ();
void deactivate ();
- void set_block_size (jack_nframes_t nframes);
+ void set_block_size (nframes_t nframes);
uint32_t output_streams() const;
uint32_t input_streams() const;
@@ -154,10 +154,10 @@ class PluginInsert : public Insert
string describe_parameter (uint32_t);
- jack_nframes_t latency();
+ nframes_t latency();
- void transport_stopped (jack_nframes_t now);
- void automation_snapshot (jack_nframes_t now);
+ void transport_stopped (nframes_t now);
+ void automation_snapshot (nframes_t now);
protected:
void store_state (PluginInsertState&) const;
@@ -167,8 +167,8 @@ class PluginInsert : public Insert
void parameter_changed (uint32_t, float);
vector<boost::shared_ptr<Plugin> > _plugins;
- void automation_run (vector<Sample *>& bufs, uint32_t nbufs, jack_nframes_t nframes, jack_nframes_t offset);
- void connect_and_run (vector<Sample *>& bufs, uint32_t nbufs, jack_nframes_t nframes, jack_nframes_t offset, bool with_auto, jack_nframes_t now = 0);
+ void automation_run (vector<Sample *>& bufs, uint32_t nbufs, nframes_t nframes, nframes_t offset);
+ void connect_and_run (vector<Sample *>& bufs, uint32_t nbufs, nframes_t nframes, nframes_t offset, bool with_auto, nframes_t now = 0);
void init ();
void set_automatable ();
diff --git a/libs/ardour/ardour/io.h b/libs/ardour/ardour/io.h
index 77f72f82d7..163ae462f3 100644
--- a/libs/ardour/ardour/io.h
+++ b/libs/ardour/ardour/io.h
@@ -87,18 +87,18 @@ virtual ~IO();
const string& name() const { return _name; }
virtual int set_name (string str, void *src);
- virtual void silence (jack_nframes_t, jack_nframes_t offset);
+ virtual void silence (nframes_t, nframes_t offset);
// These should be moved in to a separate object that manipulates an IO
- void pan (vector<Sample*>& bufs, uint32_t nbufs, jack_nframes_t nframes, jack_nframes_t offset, gain_t gain_coeff);
- void pan_automated (vector<Sample*>& bufs, uint32_t nbufs, jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t nframes, jack_nframes_t offset);
- void collect_input (vector<Sample*>&, uint32_t nbufs, jack_nframes_t nframes, jack_nframes_t offset);
- void deliver_output (vector<Sample*>&, uint32_t nbufs, jack_nframes_t nframes, jack_nframes_t offset);
- void deliver_output_no_pan (vector<Sample*>&, uint32_t nbufs, jack_nframes_t nframes, jack_nframes_t offset);
- void just_meter_input (jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t nframes, jack_nframes_t offset);
+ void pan (vector<Sample*>& bufs, uint32_t nbufs, nframes_t nframes, nframes_t offset, gain_t gain_coeff);
+ void pan_automated (vector<Sample*>& bufs, uint32_t nbufs, nframes_t start_frame, nframes_t end_frame,
+ nframes_t nframes, nframes_t offset);
+ void collect_input (vector<Sample*>&, uint32_t nbufs, nframes_t nframes, nframes_t offset);
+ void deliver_output (vector<Sample*>&, uint32_t nbufs, nframes_t nframes, nframes_t offset);
+ void deliver_output_no_pan (vector<Sample*>&, uint32_t nbufs, nframes_t nframes, nframes_t offset);
+ void just_meter_input (nframes_t start_frame, nframes_t end_frame,
+ nframes_t nframes, nframes_t offset);
virtual uint32_t n_process_buffers () { return 0; }
@@ -134,9 +134,9 @@ virtual ~IO();
int disconnect_inputs (void *src);
int disconnect_outputs (void *src);
- jack_nframes_t output_latency() const;
- jack_nframes_t input_latency() const;
- void set_port_latency (jack_nframes_t);
+ nframes_t output_latency() const;
+ nframes_t input_latency() const;
+ void set_port_latency (nframes_t);
Port *output (uint32_t n) const {
if (n < _noutputs) {
@@ -234,16 +234,16 @@ public:
AutoStyle gain_automation_style () const { return _gain_automation_curve.automation_style(); }
sigc::signal<void> gain_automation_style_changed;
- static void set_automation_interval (jack_nframes_t frames) {
+ static void set_automation_interval (nframes_t frames) {
_automation_interval = frames;
}
- static jack_nframes_t automation_interval() {
+ static nframes_t automation_interval() {
return _automation_interval;
}
- virtual void transport_stopped (jack_nframes_t now);
- virtual void automation_snapshot (jack_nframes_t now);
+ virtual void transport_stopped (nframes_t now);
+ virtual void automation_snapshot (nframes_t now);
ARDOUR::Curve& gain_automation_curve () { return _gain_automation_curve; }
@@ -291,7 +291,7 @@ public:
virtual uint32_t pans_required() const { return _ninputs; }
- static void apply_declick (vector<Sample*>&, uint32_t nbufs, jack_nframes_t nframes,
+ static void apply_declick (vector<Sample*>&, uint32_t nbufs, nframes_t nframes,
gain_t initial, gain_t target, bool invert_polarity);
struct GainControllable : public PBD::Controllable {
@@ -312,8 +312,8 @@ public:
/* automation */
- jack_nframes_t last_automation_snapshot;
- static jack_nframes_t _automation_interval;
+ nframes_t last_automation_snapshot;
+ static nframes_t _automation_interval;
AutoState _gain_automation_state;
AutoStyle _gain_automation_style;
diff --git a/libs/ardour/ardour/ladspa_plugin.h b/libs/ardour/ardour/ladspa_plugin.h
index 99fc884898..291ff41dc8 100644
--- a/libs/ardour/ardour/ladspa_plugin.h
+++ b/libs/ardour/ardour/ladspa_plugin.h
@@ -48,7 +48,7 @@ class Session;
class LadspaPlugin : public ARDOUR::Plugin
{
public:
- LadspaPlugin (void *module, ARDOUR::AudioEngine&, ARDOUR::Session&, uint32_t index, jack_nframes_t sample_rate);
+ LadspaPlugin (void *module, ARDOUR::AudioEngine&, ARDOUR::Session&, uint32_t index, nframes_t sample_rate);
LadspaPlugin (const LadspaPlugin &);
~LadspaPlugin ();
@@ -60,7 +60,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);
- jack_nframes_t latency() const;
+ nframes_t 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,9 +81,9 @@ class LadspaPlugin : public ARDOUR::Plugin
descriptor->cleanup (handle);
}
}
- void set_block_size (jack_nframes_t nframes) {}
+ void set_block_size (nframes_t nframes) {}
- int connect_and_run (vector<Sample*>& bufs, uint32_t maxbuf, int32_t& in, int32_t& out, jack_nframes_t nframes, jack_nframes_t offset);
+ int connect_and_run (vector<Sample*>& bufs, uint32_t maxbuf, int32_t& in, int32_t& out, nframes_t nframes, nframes_t offset);
void store_state (ARDOUR::PluginState&);
void restore_state (ARDOUR::PluginState&);
string describe_parameter (uint32_t);
@@ -126,15 +126,15 @@ class LadspaPlugin : public ARDOUR::Plugin
void *module;
const LADSPA_Descriptor *descriptor;
LADSPA_Handle handle;
- jack_nframes_t sample_rate;
+ nframes_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, jack_nframes_t rate);
- void run (jack_nframes_t nsamples);
+ void init (void *mod, uint32_t index, nframes_t rate);
+ void run (nframes_t nsamples);
void latency_compute_run ();
};
diff --git a/libs/ardour/ardour/location.h b/libs/ardour/ardour/location.h
index 96fb1b1bcf..2dd49847fb 100644
--- a/libs/ardour/ardour/location.h
+++ b/libs/ardour/ardour/location.h
@@ -56,8 +56,8 @@ class Location : public sigc::trackable, public PBD::StatefulDestructible
IsStart = 0x80
};
- Location (jack_nframes_t sample_start,
- jack_nframes_t sample_end,
+ Location (nframes_t sample_start,
+ nframes_t sample_end,
const string &name,
Flags bits = Flags(0))
@@ -76,13 +76,13 @@ class Location : public sigc::trackable, public PBD::StatefulDestructible
Location (const XMLNode&);
Location* operator= (const Location& other);
- jack_nframes_t start() { return _start; }
- jack_nframes_t end() { return _end; }
- jack_nframes_t length() { return _end - _start; }
+ nframes_t start() { return _start; }
+ nframes_t end() { return _end; }
+ nframes_t length() { return _end - _start; }
- int set_start (jack_nframes_t s);
- int set_end (jack_nframes_t e);
- int set (jack_nframes_t start, jack_nframes_t end);
+ int set_start (nframes_t s);
+ int set_end (nframes_t e);
+ int set (nframes_t start, nframes_t end);
const string& name() { return _name; }
void set_name (const string &str) { _name = str; name_changed(this); }
@@ -123,8 +123,8 @@ class Location : public sigc::trackable, public PBD::StatefulDestructible
private:
string _name;
- jack_nframes_t _start;
- jack_nframes_t _end;
+ nframes_t _start;
+ nframes_t _end;
uint32_t _flags;
void set_mark (bool yn);
@@ -159,11 +159,11 @@ class Locations : public StateManager, public PBD::StatefulDestructible
int set_current (Location *, bool want_lock = true);
Location *current () const { return current_location; }
- Location *first_location_before (jack_nframes_t);
- Location *first_location_after (jack_nframes_t);
+ Location *first_location_before (nframes_t);
+ Location *first_location_after (nframes_t);
- jack_nframes_t first_mark_before (jack_nframes_t);
- jack_nframes_t first_mark_after (jack_nframes_t);
+ nframes_t first_mark_before (nframes_t);
+ nframes_t first_mark_after (nframes_t);
sigc::signal<void,Location*> current_changed;
sigc::signal<void> changed;
diff --git a/libs/ardour/ardour/mix.h b/libs/ardour/ardour/mix.h
index b351e3ef17..653b61cb95 100644
--- a/libs/ardour/ardour/mix.h
+++ b/libs/ardour/ardour/mix.h
@@ -28,47 +28,47 @@
extern "C" {
/* SSE functions */
- float x86_sse_compute_peak (ARDOUR::Sample *buf, jack_nframes_t nsamples, float current);
+ float x86_sse_compute_peak (ARDOUR::Sample *buf, nframes_t nsamples, float current);
- void x86_sse_apply_gain_to_buffer (ARDOUR::Sample *buf, jack_nframes_t nframes, float gain);
+ void x86_sse_apply_gain_to_buffer (ARDOUR::Sample *buf, nframes_t nframes, float gain);
- void x86_sse_mix_buffers_with_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, jack_nframes_t nframes, float gain);
+ void x86_sse_mix_buffers_with_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, nframes_t nframes, float gain);
- void x86_sse_mix_buffers_no_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, jack_nframes_t nframes);
+ void x86_sse_mix_buffers_no_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, nframes_t nframes);
}
/* debug wrappers for SSE functions */
-float debug_compute_peak (ARDOUR::Sample *buf, jack_nframes_t nsamples, float current);
+float debug_compute_peak (ARDOUR::Sample *buf, nframes_t nsamples, float current);
-void debug_apply_gain_to_buffer (ARDOUR::Sample *buf, jack_nframes_t nframes, float gain);
+void debug_apply_gain_to_buffer (ARDOUR::Sample *buf, nframes_t nframes, float gain);
-void debug_mix_buffers_with_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, jack_nframes_t nframes, float gain);
+void debug_mix_buffers_with_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, nframes_t nframes, float gain);
-void debug_mix_buffers_no_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, jack_nframes_t nframes);
+void debug_mix_buffers_no_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, nframes_t nframes);
#endif
#if defined (__APPLE__)
-float veclib_compute_peak (ARDOUR::Sample *buf, jack_nframes_t nsamples, float current);
+float veclib_compute_peak (ARDOUR::Sample *buf, nframes_t nsamples, float current);
-void veclib_apply_gain_to_buffer (ARDOUR::Sample *buf, jack_nframes_t nframes, float gain);
+void veclib_apply_gain_to_buffer (ARDOUR::Sample *buf, nframes_t nframes, float gain);
-void veclib_mix_buffers_with_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, jack_nframes_t nframes, float gain);
+void veclib_mix_buffers_with_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, nframes_t nframes, float gain);
-void veclib_mix_buffers_no_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, jack_nframes_t nframes);
+void veclib_mix_buffers_no_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, nframes_t nframes);
#endif
/* non-optimized functions */
-float compute_peak (ARDOUR::Sample *buf, jack_nframes_t nsamples, float current);
+float compute_peak (ARDOUR::Sample *buf, nframes_t nsamples, float current);
-void apply_gain_to_buffer (ARDOUR::Sample *buf, jack_nframes_t nframes, float gain);
+void apply_gain_to_buffer (ARDOUR::Sample *buf, nframes_t nframes, float gain);
-void mix_buffers_with_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, jack_nframes_t nframes, float gain);
+void mix_buffers_with_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, nframes_t nframes, float gain);
-void mix_buffers_no_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, jack_nframes_t nframes);
+void mix_buffers_no_gain (ARDOUR::Sample *dst, ARDOUR::Sample *src, nframes_t nframes);
#endif /* __ardour_mix_h__ */
diff --git a/libs/ardour/ardour/panner.h b/libs/ardour/ardour/panner.h
index 75c59eb924..3091527e59 100644
--- a/libs/ardour/ardour/panner.h
+++ b/libs/ardour/ardour/panner.h
@@ -64,14 +64,14 @@ class StreamPanner : public sigc::trackable, public Stateful
/* the basic panner API */
- virtual void distribute (Sample* src, Sample** obufs, gain_t gain_coeff, jack_nframes_t nframes) = 0;
+ virtual void distribute (Sample* src, Sample** obufs, gain_t gain_coeff, nframes_t nframes) = 0;
virtual void distribute_automated (Sample* src, Sample** obufs,
- jack_nframes_t start, jack_nframes_t end, jack_nframes_t nframes, pan_t** buffers) = 0;
+ nframes_t start, nframes_t end, nframes_t nframes, pan_t** buffers) = 0;
/* automation */
- virtual void snapshot (jack_nframes_t now) = 0;
- virtual void transport_stopped (jack_nframes_t frame) = 0;
+ virtual void snapshot (nframes_t now) = 0;
+ virtual void transport_stopped (nframes_t frame) = 0;
virtual void set_automation_state (AutoState) = 0;
virtual void set_automation_style (AutoStyle) = 0;
@@ -141,12 +141,12 @@ class BaseStereoPanner : public StreamPanner
and a type name. See EqualPowerStereoPanner as an example.
*/
- void distribute (Sample* src, Sample** obufs, gain_t gain_coeff, jack_nframes_t nframes);
+ void distribute (Sample* src, Sample** obufs, gain_t gain_coeff, nframes_t nframes);
int load (istream&, string path, uint32_t&);
int save (ostream&) const;
- void snapshot (jack_nframes_t now);
- void transport_stopped (jack_nframes_t frame);
+ void snapshot (nframes_t now);
+ void transport_stopped (nframes_t frame);
void set_automation_state (AutoState);
void set_automation_style (AutoStyle);
@@ -170,7 +170,7 @@ class EqualPowerStereoPanner : public BaseStereoPanner
~EqualPowerStereoPanner ();
void distribute_automated (Sample* src, Sample** obufs,
- jack_nframes_t start, jack_nframes_t end, jack_nframes_t nframes, pan_t** buffers);
+ nframes_t start, nframes_t end, nframes_t nframes, pan_t** buffers);
void get_current_coefficients (pan_t*) const;
void get_desired_coefficients (pan_t*) const;
@@ -192,8 +192,8 @@ class Multi2dPanner : public StreamPanner
Multi2dPanner (Panner& parent);
~Multi2dPanner ();
- void snapshot (jack_nframes_t now);
- void transport_stopped (jack_nframes_t frame);
+ void snapshot (nframes_t now);
+ void transport_stopped (nframes_t frame);
void set_automation_state (AutoState);
void set_automation_style (AutoStyle);
@@ -203,9 +203,9 @@ class Multi2dPanner : public StreamPanner
Curve& automation() { return _automation; }
- void distribute (Sample* src, Sample** obufs, gain_t gain_coeff, jack_nframes_t nframes);
+ void distribute (Sample* src, Sample** obufs, gain_t gain_coeff, nframes_t nframes);
void distribute_automated (Sample* src, Sample** obufs,
- jack_nframes_t start, jack_nframes_t end, jack_nframes_t nframes, pan_t** buffers);
+ nframes_t start, nframes_t end, nframes_t nframes, pan_t** buffers);
int load (istream&, string path, uint32_t&);
int save (ostream&) const;
@@ -249,8 +249,8 @@ class Panner : public std::vector<StreamPanner*>, public Stateful, public sigc::
void clear ();
void reset (uint32_t noutputs, uint32_t npans);
- void snapshot (jack_nframes_t now);
- void transport_stopped (jack_nframes_t frame);
+ void snapshot (nframes_t now);
+ void transport_stopped (nframes_t frame);
void clear_automation ();
diff --git a/libs/ardour/ardour/peak.h b/libs/ardour/ardour/peak.h
index d08357024b..2c8abe7cf4 100644
--- a/libs/ardour/ardour/peak.h
+++ b/libs/ardour/ardour/peak.h
@@ -6,9 +6,9 @@
#include <ardour/utils.h>
static inline float
-compute_peak (ARDOUR::Sample *buf, jack_nframes_t nsamples, float current)
+compute_peak (ARDOUR::Sample *buf, nframes_t nsamples, float current)
{
- for (jack_nframes_t i = 0; i < nsamples; ++i) {
+ for (nframes_t i = 0; i < nsamples; ++i) {
current = f_max (current, fabsf (buf[i]));
}
return current;
diff --git a/libs/ardour/ardour/playlist.h b/libs/ardour/ardour/playlist.h
index e3911dac0b..04f2df0ae9 100644
--- a/libs/ardour/ardour/playlist.h
+++ b/libs/ardour/ardour/playlist.h
@@ -54,7 +54,7 @@ class Playlist : public StateManager, public PBD::StatefulDestructible {
Playlist (Session&, const XMLNode&, bool hidden = false);
Playlist (Session&, string name, bool hidden = false);
Playlist (const Playlist&, string name, bool hidden = false);
- Playlist (const Playlist&, jack_nframes_t start, jack_nframes_t cnt, string name, bool hidden = false);
+ Playlist (const Playlist&, nframes_t start, nframes_t cnt, string name, bool hidden = false);
virtual void clear (bool with_save = true);
virtual void dump () const;
@@ -72,7 +72,7 @@ class Playlist : public StateManager, public PBD::StatefulDestructible {
bool hidden() const { return _hidden; }
bool empty() const;
- jack_nframes_t get_maximum_extent () const;
+ nframes_t get_maximum_extent () const;
layer_t top_layer() const;
EditMode get_edit_mode() const { return _edit_mode; }
@@ -80,29 +80,29 @@ class Playlist : public StateManager, public PBD::StatefulDestructible {
/* Editing operations */
- void add_region (boost::shared_ptr<Region>, jack_nframes_t position, float times = 1, bool with_save = true);
+ void add_region (boost::shared_ptr<Region>, nframes_t position, float times = 1, bool with_save = true);
void remove_region (boost::shared_ptr<Region>);
void get_equivalent_regions (boost::shared_ptr<Region>, std::vector<boost::shared_ptr<Region> >&);
void get_region_list_equivalent_regions (boost::shared_ptr<Region>, std::vector<boost::shared_ptr<Region> >&);
- void replace_region (boost::shared_ptr<Region> old, boost::shared_ptr<Region> newr, jack_nframes_t pos);
- void split_region (boost::shared_ptr<Region>, jack_nframes_t position);
- void partition (jack_nframes_t start, jack_nframes_t end, bool just_top_level);
- void duplicate (boost::shared_ptr<Region>, jack_nframes_t position, float times);
- void nudge_after (jack_nframes_t start, jack_nframes_t distance, bool forwards);
+ void replace_region (boost::shared_ptr<Region> old, boost::shared_ptr<Region> newr, nframes_t pos);
+ void split_region (boost::shared_ptr<Region>, nframes_t position);
+ void partition (nframes_t start, nframes_t end, bool just_top_level);
+ void duplicate (boost::shared_ptr<Region>, nframes_t position, float times);
+ void nudge_after (nframes_t start, nframes_t distance, bool forwards);
boost::shared_ptr<Region> find_region (const PBD::ID&) const;
Playlist* cut (list<AudioRange>&, bool result_is_hidden = true);
Playlist* copy (list<AudioRange>&, bool result_is_hidden = true);
- int paste (Playlist&, jack_nframes_t position, float times);
+ int paste (Playlist&, nframes_t position, float times);
uint32_t read_data_count() { return _read_data_count; }
- RegionList* regions_at (jack_nframes_t frame);
- RegionList* regions_touched (jack_nframes_t start, jack_nframes_t end);
- boost::shared_ptr<Region> top_region_at (jack_nframes_t frame);
+ RegionList* regions_at (nframes_t frame);
+ RegionList* regions_touched (nframes_t start, nframes_t end);
+ boost::shared_ptr<Region> top_region_at (nframes_t frame);
- boost::shared_ptr<Region> find_next_region (jack_nframes_t frame, RegionPoint point, int dir);
+ boost::shared_ptr<Region> find_next_region (nframes_t frame, RegionPoint point, int dir);
template<class T> void foreach_region (T *t, void (T::*func)(boost::shared_ptr<Region>, void *), void *arg);
template<class T> void foreach_region (T *t, void (T::*func)(boost::shared_ptr<Region>));
@@ -194,7 +194,7 @@ class Playlist : public StateManager, public PBD::StatefulDestructible {
uint32_t _read_data_count;
PBD::ID _orig_diskstream_id;
uint64_t layer_op_counter;
- jack_nframes_t freeze_length;
+ nframes_t freeze_length;
void init (bool hide);
@@ -249,25 +249,25 @@ class Playlist : public StateManager, public PBD::StatefulDestructible {
void save_state (std::string why);
void maybe_save_state (std::string why);
- void add_region_internal (boost::shared_ptr<Region>, jack_nframes_t position, bool delay_sort = false);
+ void add_region_internal (boost::shared_ptr<Region>, nframes_t position, bool delay_sort = false);
int remove_region_internal (boost::shared_ptr<Region>, bool delay_sort = false);
- RegionList *find_regions_at (jack_nframes_t frame);
+ RegionList *find_regions_at (nframes_t frame);
void copy_regions (RegionList&) const;
- void partition_internal (jack_nframes_t start, jack_nframes_t end, bool cutting, RegionList& thawlist);
+ void partition_internal (nframes_t start, nframes_t end, bool cutting, RegionList& thawlist);
- jack_nframes_t _get_maximum_extent() const;
+ nframes_t _get_maximum_extent() const;
- Playlist* cut_copy (Playlist* (Playlist::*pmf)(jack_nframes_t, jack_nframes_t, bool),
+ Playlist* cut_copy (Playlist* (Playlist::*pmf)(nframes_t, nframes_t, bool),
list<AudioRange>& ranges, bool result_is_hidden);
- Playlist *cut (jack_nframes_t start, jack_nframes_t cnt, bool result_is_hidden);
- Playlist *copy (jack_nframes_t start, jack_nframes_t cnt, bool result_is_hidden);
+ Playlist *cut (nframes_t start, nframes_t cnt, bool result_is_hidden);
+ Playlist *copy (nframes_t start, nframes_t cnt, bool result_is_hidden);
int move_region_to_layer (layer_t, boost::shared_ptr<Region> r, int dir);
void relayer ();
- static Playlist* copyPlaylist (const Playlist&, jack_nframes_t start, jack_nframes_t length,
+ static Playlist* copyPlaylist (const Playlist&, nframes_t start, nframes_t length,
string name, bool result_is_hidden);
void unset_freeze_parent (Playlist*);
diff --git a/libs/ardour/ardour/plugin.h b/libs/ardour/ardour/plugin.h
index 4800bc35fc..dcc657018a 100644
--- a/libs/ardour/ardour/plugin.h
+++ b/libs/ardour/ardour/plugin.h
@@ -109,7 +109,7 @@ class Plugin : public PBD::StatefulDestructible, public sigc::trackable
virtual const char * maker() const = 0;
virtual uint32_t parameter_count () const = 0;
virtual float default_value (uint32_t port) = 0;
- virtual jack_nframes_t latency() const = 0;
+ virtual nframes_t latency() const = 0;
virtual void set_parameter (uint32_t which, float val) = 0;
virtual float get_parameter(uint32_t which) const = 0;
@@ -117,9 +117,9 @@ class Plugin : public PBD::StatefulDestructible, public sigc::trackable
virtual uint32_t nth_parameter (uint32_t which, bool& ok) const = 0;
virtual void activate () = 0;
virtual void deactivate () = 0;
- virtual void set_block_size (jack_nframes_t nframes) = 0;
+ virtual void set_block_size (nframes_t nframes) = 0;
- virtual int connect_and_run (vector<Sample*>& bufs, uint32_t maxbuf, int32_t& in, int32_t& out, jack_nframes_t nframes, jack_nframes_t offset) = 0;
+ virtual int connect_and_run (vector<Sample*>& bufs, uint32_t maxbuf, int32_t& in, int32_t& out, nframes_t nframes, nframes_t offset) = 0;
virtual std::set<uint32_t> automatable() const = 0;
virtual void store_state (ARDOUR::PluginState&) = 0;
virtual void restore_state (ARDOUR::PluginState&) = 0;
diff --git a/libs/ardour/ardour/port.h b/libs/ardour/ardour/port.h
index 92dd85ee86..b6a8e6fd36 100644
--- a/libs/ardour/ardour/port.h
+++ b/libs/ardour/ardour/port.h
@@ -36,7 +36,7 @@ class Port : public sigc::trackable {
free (_port);
}
- Sample *get_buffer (jack_nframes_t nframes) {
+ Sample *get_buffer (nframes_t nframes) {
if (_flags & JackPortIsOutput) {
return _buffer;
} else {
@@ -116,8 +116,8 @@ class Port : public sigc::trackable {
uint32_t short_overs () const { return _short_overs; }
uint32_t long_overs () const { return _long_overs; }
- static void set_short_over_length (jack_nframes_t);
- static void set_long_over_length (jack_nframes_t);
+ static void set_short_over_length (nframes_t);
+ static void set_long_over_length (nframes_t);
bool receives_input() const {
return _flags & JackPortIsInput;
@@ -150,11 +150,11 @@ class Port : public sigc::trackable {
jack_port_request_monitor (_port, yn);
}
- jack_nframes_t latency () const {
+ nframes_t latency () const {
return jack_port_get_latency (_port);
}
- void set_latency (jack_nframes_t nframes) {
+ void set_latency (nframes_t nframes) {
jack_port_set_latency (_port, nframes);
}
@@ -164,7 +164,7 @@ class Port : public sigc::trackable {
bool is_silent() const { return _silent; }
/** Assumes that the port is an audio output port */
- void silence (jack_nframes_t nframes, jack_nframes_t offset) {
+ void silence (nframes_t nframes, nframes_t offset) {
if (!_silent) {
memset (_buffer + offset, 0, sizeof (Sample) * nframes);
if (offset == 0) {
@@ -203,15 +203,15 @@ class Port : public sigc::trackable {
bool _last_monitor : 1;
bool _silent : 1;
jack_port_t *_port;
- jack_nframes_t _overlen;
+ nframes_t _overlen;
jack_default_audio_sample_t _peak;
float _peak_db;
uint32_t _short_overs;
uint32_t _long_overs;
unsigned short _metering;
- static jack_nframes_t _long_over_length;
- static jack_nframes_t _short_over_length;
+ static nframes_t _long_over_length;
+ static nframes_t _short_over_length;
};
} // namespace ARDOUR
diff --git a/libs/ardour/ardour/redirect.h b/libs/ardour/ardour/redirect.h
index 5f63fad8c8..691e690b47 100644
--- a/libs/ardour/ardour/redirect.h
+++ b/libs/ardour/ardour/redirect.h
@@ -81,12 +81,12 @@ class Redirect : public IO
Placement placement() const { return _placement; }
void set_placement (Placement, void *src);
- virtual void run (vector<Sample *>& ibufs, uint32_t nbufs, jack_nframes_t nframes, jack_nframes_t offset) = 0;
+ virtual void run (vector<Sample *>& ibufs, uint32_t nbufs, nframes_t nframes, nframes_t offset) = 0;
virtual void activate () = 0;
virtual void deactivate () = 0;
- virtual jack_nframes_t latency() { return 0; }
+ virtual nframes_t latency() { return 0; }
- virtual void set_block_size (jack_nframes_t nframes) {}
+ virtual void set_block_size (nframes_t nframes) {}
sigc::signal<void,Redirect*,void*> active_changed;
sigc::signal<void,Redirect*,void*> placement_changed;
@@ -120,9 +120,9 @@ class Redirect : public IO
void mark_automation_visible (uint32_t, bool);
AutomationList& automation_list (uint32_t);
- bool find_next_event (jack_nframes_t, jack_nframes_t, ControlEvent&) const;
+ bool find_next_event (nframes_t, nframes_t, ControlEvent&) const;
- virtual void transport_stopped (jack_nframes_t frame) {};
+ virtual void transport_stopped (nframes_t frame) {};
protected:
void set_placement (const string&, void *src);
diff --git a/libs/ardour/ardour/region.h b/libs/ardour/ardour/region.h
index 2ff7d0bdb2..30cd3267df 100644
--- a/libs/ardour/ardour/region.h
+++ b/libs/ardour/ardour/region.h
@@ -46,11 +46,11 @@ struct RegionState : public StateManager::State
{
RegionState (std::string why) : StateManager::State (why) {}
- jack_nframes_t _start;
- jack_nframes_t _length;
- jack_nframes_t _position;
+ nframes_t _start;
+ nframes_t _length;
+ nframes_t _position;
uint32_t _flags;
- jack_nframes_t _sync_position;
+ nframes_t _sync_position;
layer_t _layer;
string _name;
mutable RegionEditState _first_edit;
@@ -99,20 +99,20 @@ class Region : public PBD::StatefulDestructible, public StateManager, public boo
string name() const { return _name; }
void set_name (string str);
- jack_nframes_t position () const { return _position; }
- jack_nframes_t start () const { return _start; }
- jack_nframes_t length() const { return _length; }
+ nframes_t position () const { return _position; }
+ nframes_t start () const { return _start; }
+ nframes_t length() const { return _length; }
layer_t layer () const { return _layer; }
- jack_nframes_t sync_offset(int& dir) const;
- jack_nframes_t sync_position() const;
+ nframes_t sync_offset(int& dir) const;
+ nframes_t sync_position() const;
- jack_nframes_t adjust_to_sync (jack_nframes_t);
+ nframes_t adjust_to_sync (nframes_t);
/* first_frame() is an alias; last_frame() just hides some math */
- jack_nframes_t first_frame() const { return _position; }
- jack_nframes_t last_frame() const { return _position + _length - 1; }
+ nframes_t first_frame() const { return _position; }
+ nframes_t last_frame() const { return _position + _length - 1; }
bool hidden() const { return _flags & Hidden; }
bool muted() const { return _flags & Muted; }
@@ -127,12 +127,12 @@ class Region : public PBD::StatefulDestructible, public StateManager, public boo
void freeze ();
void thaw (const string& why);
- bool covers (jack_nframes_t frame) const {
- return _position <= frame && frame < _position + _length;
+ bool covers (nframes_t frame) const {
+ return first_frame() <= frame && frame < last_frame();
}
- OverlapType coverage (jack_nframes_t start, jack_nframes_t end) const {
- return ARDOUR::coverage (_position, _position + _length - 1, start, end);
+ OverlapType coverage (nframes_t start, nframes_t end) const {
+ return ARDOUR::coverage (first_frame(), last_frame(), start, end);
}
bool equivalent (boost::shared_ptr<const Region>) const;
@@ -145,19 +145,19 @@ class Region : public PBD::StatefulDestructible, public StateManager, public boo
/* EDITING OPERATIONS */
- void set_length (jack_nframes_t, void *src);
- void set_start (jack_nframes_t, void *src);
- void set_position (jack_nframes_t, void *src);
- void set_position_on_top (jack_nframes_t, void *src);
- void special_set_position (jack_nframes_t);
+ void set_length (nframes_t, void *src);
+ void set_start (nframes_t, void *src);
+ void set_position (nframes_t, void *src);
+ void set_position_on_top (nframes_t, void *src);
+ void special_set_position (nframes_t);
void nudge_position (long, void *src);
void move_to_natural_position (void *src);
- void trim_start (jack_nframes_t new_position, void *src);
- void trim_front (jack_nframes_t new_position, void *src);
- void trim_end (jack_nframes_t new_position, void *src);
- void trim_to (jack_nframes_t position, jack_nframes_t length, void *src);
+ void trim_start (nframes_t new_position, void *src);
+ void trim_front (nframes_t new_position, void *src);
+ void trim_end (nframes_t new_position, void *src);
+ void trim_to (nframes_t position, nframes_t length, void *src);
void set_layer (layer_t l); /* ONLY Playlist can call this */
void raise ();
@@ -165,7 +165,7 @@ class Region : public PBD::StatefulDestructible, public StateManager, public boo
void raise_to_top ();
void lower_to_bottom ();
- void set_sync_position (jack_nframes_t n);
+ void set_sync_position (nframes_t n);
void clear_sync_position ();
void set_hidden (bool yn);
void set_muted (bool yn);
@@ -197,9 +197,9 @@ class Region : public PBD::StatefulDestructible, public StateManager, public boo
protected:
friend class RegionFactory;
- Region (jack_nframes_t start, jack_nframes_t length,
+ Region (nframes_t start, nframes_t length,
const string& name, layer_t = 0, Flag flags = DefaultFlags);
- Region (boost::shared_ptr<const Region>, jack_nframes_t start, jack_nframes_t length, const string& name, layer_t = 0, Flag flags = DefaultFlags);
+ Region (boost::shared_ptr<const Region>, nframes_t start, nframes_t length, const string& name, layer_t = 0, Flag flags = DefaultFlags);
Region (boost::shared_ptr<const Region>);
Region (const XMLNode&);
@@ -216,25 +216,25 @@ class Region : public PBD::StatefulDestructible, public StateManager, public boo
void store_state (RegionState&) const;
Change restore_and_return_flags (RegionState&);
- void trim_to_internal (jack_nframes_t position, jack_nframes_t length, void *src);
+ void trim_to_internal (nframes_t position, nframes_t length, void *src);
bool copied() const { return _flags & Copied; }
void maybe_uncopy ();
void first_edit ();
- virtual bool verify_start (jack_nframes_t) = 0;
- virtual bool verify_start_and_length (jack_nframes_t, jack_nframes_t) = 0;
- virtual bool verify_start_mutable (jack_nframes_t&_start) = 0;
- virtual bool verify_length (jack_nframes_t) = 0;
+ virtual bool verify_start (nframes_t) = 0;
+ virtual bool verify_start_and_length (nframes_t, nframes_t) = 0;
+ virtual bool verify_start_mutable (nframes_t&_start) = 0;
+ virtual bool verify_length (nframes_t) = 0;
virtual void recompute_at_start () = 0;
virtual void recompute_at_end () = 0;
- jack_nframes_t _start;
- jack_nframes_t _length;
- jack_nframes_t _position;
+ nframes_t _start;
+ nframes_t _length;
+ nframes_t _position;
Flag _flags;
- jack_nframes_t _sync_position;
+ nframes_t _sync_position;
layer_t _layer;
string _name;
mutable RegionEditState _first_edit;
diff --git a/libs/ardour/ardour/region_factory.h b/libs/ardour/ardour/region_factory.h
index 3bf1b6005e..f1f5d1e69f 100644
--- a/libs/ardour/ardour/region_factory.h
+++ b/libs/ardour/ardour/region_factory.h
@@ -23,14 +23,14 @@ class RegionFactory {
static sigc::signal<void,boost::shared_ptr<Region> > CheckNewRegion;
- static boost::shared_ptr<Region> create (boost::shared_ptr<Region>, jack_nframes_t start,
- jack_nframes_t length, std::string name,
+ static boost::shared_ptr<Region> create (boost::shared_ptr<Region>, nframes_t start,
+ nframes_t length, std::string name,
layer_t = 0, Region::Flag flags = Region::DefaultFlags, bool announce = true);
- static boost::shared_ptr<Region> create (boost::shared_ptr<AudioRegion>, jack_nframes_t start,
- jack_nframes_t length, std::string name,
+ static boost::shared_ptr<Region> create (boost::shared_ptr<AudioRegion>, nframes_t start,
+ nframes_t length, std::string name,
layer_t = 0, Region::Flag flags = Region::DefaultFlags, bool announce = true);
- static boost::shared_ptr<Region> create (boost::shared_ptr<Source>, jack_nframes_t start, jack_nframes_t length, const string& name, layer_t = 0, Region::Flag flags = Region::DefaultFlags, bool announce = true);
- static boost::shared_ptr<Region> create (SourceList &, jack_nframes_t start, jack_nframes_t length, const string& name, layer_t = 0, Region::Flag flags = Region::DefaultFlags, bool announce = true);
+ static boost::shared_ptr<Region> create (boost::shared_ptr<Source>, nframes_t start, nframes_t length, const string& name, layer_t = 0, Region::Flag flags = Region::DefaultFlags, bool announce = true);
+ static boost::shared_ptr<Region> create (SourceList &, nframes_t start, nframes_t length, const string& name, layer_t = 0, Region::Flag flags = Region::DefaultFlags, bool announce = true);
static boost::shared_ptr<Region> create (boost::shared_ptr<Region>);
static boost::shared_ptr<Region> create (Session&, XMLNode&, bool);
static boost::shared_ptr<Region> create (SourceList &, const XMLNode&);
diff --git a/libs/ardour/ardour/route.h b/libs/ardour/ardour/route.h
index 2191439744..8ebc598e95 100644
--- a/libs/ardour/ardour/route.h
+++ b/libs/ardour/ardour/route.h
@@ -89,14 +89,14 @@ class Route : public IO
/* these are the core of the API of a Route. see the protected sections as well */
- virtual int roll (jack_nframes_t nframes, jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t offset, int declick, bool can_record, bool rec_monitors_input);
+ virtual int roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame,
+ nframes_t offset, int declick, bool can_record, bool rec_monitors_input);
- virtual int no_roll (jack_nframes_t nframes, jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t offset, bool state_changing, bool can_record, bool rec_monitors_input);
+ virtual int no_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame,
+ nframes_t offset, bool state_changing, bool can_record, bool rec_monitors_input);
- virtual int silent_roll (jack_nframes_t nframes, jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t offset, bool can_record, bool rec_monitors_input);
+ virtual int silent_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame,
+ nframes_t offset, bool can_record, bool rec_monitors_input);
virtual void toggle_monitor_input ();
virtual bool can_record() { return false; }
virtual void set_record_enable (bool yn, void *src) {}
@@ -174,9 +174,9 @@ class Route : public IO
void all_redirects_flip();
void all_redirects_active (bool state);
- virtual jack_nframes_t update_total_latency();
- jack_nframes_t signal_latency() const { return _own_latency; }
- virtual void set_latency_delay (jack_nframes_t);
+ virtual nframes_t update_total_latency();
+ nframes_t signal_latency() const { return _own_latency; }
+ virtual void set_latency_delay (nframes_t);
sigc::signal<void,void*> solo_changed;
sigc::signal<void,void*> solo_safe_changed;
@@ -238,7 +238,7 @@ class Route : public IO
return _mute_control;
}
- void automation_snapshot (jack_nframes_t now);
+ void automation_snapshot (nframes_t now);
void protect_automation ();
@@ -250,7 +250,7 @@ class Route : public IO
friend class Session;
void set_solo_mute (bool yn);
- void set_block_size (jack_nframes_t nframes);
+ void set_block_size (nframes_t nframes);
bool has_external_redirects() const;
void curve_reallocate ();
@@ -283,11 +283,11 @@ class Route : public IO
gain_t desired_solo_gain;
gain_t desired_mute_gain;
- jack_nframes_t check_initial_delay (jack_nframes_t, jack_nframes_t&, jack_nframes_t&);
+ nframes_t check_initial_delay (nframes_t, nframes_t&, nframes_t&);
- jack_nframes_t _initial_delay;
- jack_nframes_t _roll_delay;
- jack_nframes_t _own_latency;
+ nframes_t _initial_delay;
+ nframes_t _roll_delay;
+ nframes_t _own_latency;
RedirectList _redirects;
Glib::RWLock redirect_lock;
IO *_control_outs;
@@ -300,12 +300,12 @@ class Route : public IO
ToggleControllable _solo_control;
ToggleControllable _mute_control;
- void passthru (jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t nframes, jack_nframes_t offset, int declick, bool meter_inputs);
+ void passthru (nframes_t start_frame, nframes_t end_frame,
+ nframes_t nframes, nframes_t offset, int declick, bool meter_inputs);
void process_output_buffers (vector<Sample*>& bufs, uint32_t nbufs,
- jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t nframes, jack_nframes_t offset, bool with_redirects, int declick,
+ nframes_t start_frame, nframes_t end_frame,
+ nframes_t nframes, nframes_t offset, bool with_redirects, int declick,
bool meter);
protected:
@@ -313,7 +313,7 @@ class Route : public IO
virtual XMLNode& state(bool);
- void silence (jack_nframes_t nframes, jack_nframes_t offset);
+ void silence (nframes_t nframes, nframes_t offset);
sigc::connection input_signal_connection;
state_id_t _current_state_id;
diff --git a/libs/ardour/ardour/send.h b/libs/ardour/ardour/send.h
index 0a068e8af0..1a9a892f33 100644
--- a/libs/ardour/ardour/send.h
+++ b/libs/ardour/ardour/send.h
@@ -40,7 +40,7 @@ class Send : public Redirect {
Send (const Send&);
~Send ();
- void run (vector<Sample *> &bufs, uint32_t nbufs, jack_nframes_t nframes, jack_nframes_t offset);
+ void run (vector<Sample *> &bufs, uint32_t nbufs, nframes_t nframes, nframes_t offset);
void activate() {}
void deactivate () {}
diff --git a/libs/ardour/ardour/session.h b/libs/ardour/ardour/session.h
index 3d70520c49..2ac2d3c48f 100644
--- a/libs/ardour/ardour/session.h
+++ b/libs/ardour/ardour/session.h
@@ -154,8 +154,8 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
Type type;
Action action;
- jack_nframes_t action_frame;
- jack_nframes_t target_frame;
+ nframes_t action_frame;
+ nframes_t target_frame;
float speed;
union {
@@ -170,7 +170,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
list<AudioRange> audio_range;
list<MusicRange> music_range;
- Event(Type t, Action a, jack_nframes_t when, jack_nframes_t where, float spd, bool yn = false)
+ Event(Type t, Action a, nframes_t when, nframes_t where, float spd, bool yn = false)
: type (t),
action (a),
action_frame (when),
@@ -202,7 +202,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
pool.release (ptr);
}
- static const jack_nframes_t Immediate = 0;
+ static const nframes_t Immediate = 0;
private:
static MultiAllocSingleReleasePool pool;
@@ -226,7 +226,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
uint32_t master_out_channels,
uint32_t n_physical_in,
uint32_t n_physical_out,
- jack_nframes_t initial_length);
+ nframes_t initial_length);
virtual ~Session ();
@@ -261,7 +261,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
static string change_audio_path_by_name (string oldpath, string oldname, string newname, bool destructive);
string audio_path_from_name (string, uint32_t nchans, uint32_t chan, bool destructive);
- void process (jack_nframes_t nframes);
+ void process (nframes_t nframes);
vector<Sample*>& get_passthru_buffers() { return _passthru_buffers; }
vector<Sample*>& get_silent_buffers (uint32_t howmany);
@@ -336,22 +336,22 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
/* Transport mechanism signals */
sigc::signal<void> TransportStateChange; /* generic */
- sigc::signal<void,jack_nframes_t> PositionChanged; /* sent after any non-sequential motion */
+ sigc::signal<void,nframes_t> PositionChanged; /* sent after any non-sequential motion */
sigc::signal<void> DurationChanged;
sigc::signal<void> HaltOnXrun;
sigc::signal<void,RouteList&> RouteAdded;
void request_roll ();
- void request_bounded_roll (jack_nframes_t start, jack_nframes_t end);
+ void request_bounded_roll (nframes_t start, nframes_t end);
void request_stop (bool abort = false);
- void request_locate (jack_nframes_t frame, bool with_roll = false);
+ void request_locate (nframes_t frame, bool with_roll = false);
void request_play_loop (bool yn);
- jack_nframes_t last_transport_start() const { return _last_roll_location; }
+ nframes_t last_transport_start() const { return _last_roll_location; }
void goto_end () { request_locate (end_location->start(), false);}
void goto_start () { request_locate (start_location->start(), false); }
- void set_session_start (jack_nframes_t start) { start_location->set_start(start); }
- void set_session_end (jack_nframes_t end) { end_location->set_start(end); _end_location_is_free = false; }
+ void set_session_start (nframes_t start) { start_location->set_start(start); }
+ void set_session_end (nframes_t end) { end_location->set_start(end); _end_location_is_free = false; }
void use_rf_shuttle_speed ();
void request_transport_speed (float speed);
void request_overwrite_buffer (Diskstream*);
@@ -365,14 +365,14 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
int remove_region_from_region_list (boost::shared_ptr<Region>);
- jack_nframes_t get_maximum_extent () const;
- jack_nframes_t current_end_frame() const { return end_location->start(); }
- jack_nframes_t current_start_frame() const { return start_location->start(); }
- jack_nframes_t frame_rate() const { return _current_frame_rate; }
- jack_nframes_t frames_per_hour() const { return _frames_per_hour; }
+ nframes_t get_maximum_extent () const;
+ nframes_t current_end_frame() const { return end_location->start(); }
+ nframes_t current_start_frame() const { return start_location->start(); }
+ nframes_t frame_rate() const { return _current_frame_rate; }
+ nframes_t frames_per_hour() const { return _frames_per_hour; }
double frames_per_smpte_frame() const { return _frames_per_smpte_frame; }
- jack_nframes_t smpte_frames_per_hour() const { return _smpte_frames_per_hour; }
+ nframes_t smpte_frames_per_hour() const { return _smpte_frames_per_hour; }
/* Locations */
@@ -387,14 +387,14 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
void reset_input_monitor_state ();
- void add_event (jack_nframes_t action_frame, Event::Type type, jack_nframes_t target_frame = 0);
- void remove_event (jack_nframes_t frame, Event::Type type);
+ void add_event (nframes_t action_frame, Event::Type type, nframes_t target_frame = 0);
+ void remove_event (nframes_t frame, Event::Type type);
void clear_events (Event::Type type);
- jack_nframes_t get_block_size() const { return current_block_size; }
- jack_nframes_t worst_output_latency () const { return _worst_output_latency; }
- jack_nframes_t worst_input_latency () const { return _worst_input_latency; }
- jack_nframes_t worst_track_latency () const { return _worst_track_latency; }
+ nframes_t get_block_size() const { return current_block_size; }
+ nframes_t worst_output_latency () const { return _worst_output_latency; }
+ nframes_t worst_input_latency () const { return _worst_input_latency; }
+ nframes_t worst_track_latency () const { return _worst_track_latency; }
int save_state (string snapshot_name, bool pending = false);
int restore_state (string snapshot_name);
@@ -473,8 +473,8 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
/* Time */
- jack_nframes_t transport_frame () const {return _transport_frame; }
- jack_nframes_t audible_frame () const;
+ nframes_t transport_frame () const {return _transport_frame; }
+ nframes_t audible_frame () const;
enum SmpteFormat {
smpte_23976,
@@ -505,22 +505,22 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
void sync_time_vars();
- void bbt_time (jack_nframes_t when, BBT_Time&);
- void smpte_to_sample( SMPTE::Time& smpte, jack_nframes_t& sample, bool use_offset, bool use_subframes ) const;
- void sample_to_smpte( jack_nframes_t sample, SMPTE::Time& smpte, bool use_offset, bool use_subframes ) const;
+ void bbt_time (nframes_t when, BBT_Time&);
+ void smpte_to_sample( SMPTE::Time& smpte, nframes_t& sample, bool use_offset, bool use_subframes ) const;
+ void sample_to_smpte( nframes_t sample, SMPTE::Time& smpte, bool use_offset, bool use_subframes ) const;
void smpte_time (SMPTE::Time &);
- void smpte_time (jack_nframes_t when, SMPTE::Time&);
- void smpte_time_subframes (jack_nframes_t when, SMPTE::Time&);
+ void smpte_time (nframes_t when, SMPTE::Time&);
+ void smpte_time_subframes (nframes_t when, SMPTE::Time&);
- void smpte_duration (jack_nframes_t, SMPTE::Time&) const;
- void smpte_duration_string (char *, jack_nframes_t) const;
+ void smpte_duration (nframes_t, SMPTE::Time&) const;
+ void smpte_duration_string (char *, nframes_t) const;
- void set_smpte_offset (jack_nframes_t);
- jack_nframes_t smpte_offset () const { return _smpte_offset; }
+ void set_smpte_offset (nframes_t);
+ nframes_t smpte_offset () const { return _smpte_offset; }
void set_smpte_offset_negative (bool);
bool smpte_offset_negative () const { return _smpte_offset_negative; }
- jack_nframes_t convert_to_frames_at (jack_nframes_t position, AnyTime&);
+ nframes_t convert_to_frames_at (nframes_t position, AnyTime&);
static sigc::signal<void> StartTimeChanged;
static sigc::signal<void> EndTimeChanged;
@@ -533,7 +533,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
bool transport_stopped() const { return _transport_speed == 0.0f; }
bool transport_rolling() const { return _transport_speed != 0.0f; }
- int jack_slave_sync (jack_nframes_t);
+ int jack_slave_sync (nframes_t);
TempoMap& tempo_map() { return *_tempo_map; }
@@ -574,7 +574,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
string build_tmp_convert_name (string file);
SlaveSource post_export_slave;
- jack_nframes_t post_export_position;
+ nframes_t post_export_position;
int start_audio_export (ARDOUR::AudioExportSpecification&);
int stop_audio_export (ARDOUR::AudioExportSpecification&);
@@ -660,7 +660,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
/* flattening stuff */
- int write_one_audio_track (AudioTrack&, jack_nframes_t start, jack_nframes_t cnt, bool overwrite, vector<boost::shared_ptr<AudioSource> >&,
+ int write_one_audio_track (AudioTrack&, nframes_t start, nframes_t cnt, bool overwrite, vector<boost::shared_ptr<AudioSource> >&,
InterThreadInfo& wot);
int freeze (InterThreadInfo&);
@@ -692,7 +692,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
/* s/w "RAID" management */
- jack_nframes_t available_capture_duration();
+ nframes_t available_capture_duration();
/* I/O Connections */
@@ -729,10 +729,10 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
/* Scrubbing */
- void start_scrub (jack_nframes_t where);
+ void start_scrub (nframes_t where);
void stop_scrub ();
void set_scrub_speed (float);
- jack_nframes_t scrub_buffer_size() const;
+ nframes_t scrub_buffer_size() const;
sigc::signal<void> ScrubReady;
/* History (for editors, mixers, UIs etc.) */
@@ -892,10 +892,10 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
void* ptr,
float opt);
- typedef float (*compute_peak_t) (Sample *, jack_nframes_t, float);
- typedef void (*apply_gain_to_buffer_t) (Sample *, jack_nframes_t, float);
- typedef void (*mix_buffers_with_gain_t) (Sample *, Sample *, jack_nframes_t, float);
- typedef void (*mix_buffers_no_gain_t) (Sample *, Sample *, jack_nframes_t);
+ typedef float (*compute_peak_t) (Sample *, nframes_t, float);
+ typedef void (*apply_gain_to_buffer_t) (Sample *, nframes_t, float);
+ typedef void (*mix_buffers_with_gain_t) (Sample *, Sample *, nframes_t, float);
+ typedef void (*mix_buffers_no_gain_t) (Sample *, Sample *, nframes_t);
static compute_peak_t compute_peak;
static apply_gain_to_buffer_t apply_gain_to_buffer;
@@ -910,8 +910,8 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
protected:
friend class AudioEngine;
- void set_block_size (jack_nframes_t nframes);
- void set_frame_rate (jack_nframes_t nframes);
+ void set_block_size (nframes_t nframes);
+ void set_frame_rate (nframes_t nframes);
protected:
friend class Diskstream;
@@ -924,7 +924,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
void update_latency_compensation (bool, bool);
private:
- int create (bool& new_session, string* mix_template, jack_nframes_t initial_length);
+ int create (bool& new_session, string* mix_template, nframes_t initial_length);
static const char* _template_suffix;
static const char* _statefile_suffix;
@@ -943,34 +943,34 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
maximise cache hits
*/
- typedef void (Session::*process_function_type)(jack_nframes_t);
+ typedef void (Session::*process_function_type)(nframes_t);
AudioEngine &_engine;
mutable gint processing_prohibited;
process_function_type process_function;
process_function_type last_process_function;
bool waiting_for_sync_offset;
- jack_nframes_t _base_frame_rate;
- jack_nframes_t _current_frame_rate; //this includes video pullup offset
+ nframes_t _base_frame_rate;
+ nframes_t _current_frame_rate; //this includes video pullup offset
int transport_sub_state;
mutable gint _record_status;
- jack_nframes_t _transport_frame;
+ nframes_t _transport_frame;
Location* end_location;
Location* start_location;
Slave *_slave;
volatile float _transport_speed;
volatile float _desired_transport_speed;
float _last_transport_speed;
- jack_nframes_t _last_slave_transport_frame;
- jack_nframes_t maximum_output_latency;
- jack_nframes_t last_stop_frame;
+ nframes_t _last_slave_transport_frame;
+ nframes_t maximum_output_latency;
+ nframes_t last_stop_frame;
vector<Sample *> _passthru_buffers;
vector<Sample *> _silent_buffers;
vector<Sample *> _send_buffers;
- jack_nframes_t current_block_size;
- jack_nframes_t _worst_output_latency;
- jack_nframes_t _worst_input_latency;
- jack_nframes_t _worst_track_latency;
+ nframes_t current_block_size;
+ nframes_t _worst_output_latency;
+ nframes_t _worst_input_latency;
+ nframes_t _worst_track_latency;
bool _have_captured;
float _meter_hold;
float _meter_falloff;
@@ -985,11 +985,11 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
void ensure_passthru_buffers (uint32_t howmany);
- void process_scrub (jack_nframes_t);
- void process_without_events (jack_nframes_t);
- void process_with_events (jack_nframes_t);
- void process_audition (jack_nframes_t);
- int process_export (jack_nframes_t, ARDOUR::AudioExportSpecification*);
+ void process_scrub (nframes_t);
+ void process_without_events (nframes_t);
+ void process_with_events (nframes_t);
+ void process_audition (nframes_t);
+ int process_export (nframes_t, ARDOUR::AudioExportSpecification*);
/* slave tracking */
@@ -1007,19 +1007,19 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
};
SlaveState slave_state;
- jack_nframes_t slave_wait_end;
+ nframes_t slave_wait_end;
void reset_slave_state ();
- bool follow_slave (jack_nframes_t, jack_nframes_t);
+ bool follow_slave (nframes_t, nframes_t);
void set_slave_source (SlaveSource);
bool _exporting;
int prepare_to_export (ARDOUR::AudioExportSpecification&);
void prepare_diskstreams ();
- void commit_diskstreams (jack_nframes_t, bool& session_requires_butler);
- int process_routes (jack_nframes_t, jack_nframes_t);
- int silent_process_routes (jack_nframes_t, jack_nframes_t);
+ void commit_diskstreams (nframes_t, bool& session_requires_butler);
+ int process_routes (nframes_t, nframes_t);
+ int silent_process_routes (nframes_t, nframes_t);
bool get_rec_monitors_input () {
if (actively_recording()) {
@@ -1045,7 +1045,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
}
}
- bool maybe_stop (jack_nframes_t limit) {
+ bool maybe_stop (nframes_t limit) {
if ((_transport_speed > 0.0f && _transport_frame >= limit) || (_transport_speed < 0.0f && _transport_frame == 0)) {
stop_transport ();
return true;
@@ -1053,7 +1053,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
return false;
}
- bool maybe_sync_start (jack_nframes_t&, jack_nframes_t&);
+ bool maybe_sync_start (nframes_t&, nframes_t&);
void check_declick_out ();
@@ -1068,7 +1068,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
bool session_midi_feedback;
bool play_loop;
bool loop_changing;
- jack_nframes_t last_loopend;
+ nframes_t last_loopend;
RingBuffer<Event*> pending_events;
@@ -1088,10 +1088,10 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
XMLNode& get_options () const;
int load_state (string snapshot_name);
- jack_nframes_t _last_roll_location;
- jack_nframes_t _last_record_location;
+ nframes_t _last_roll_location;
+ nframes_t _last_record_location;
bool pending_locate_roll;
- jack_nframes_t pending_locate_frame;
+ nframes_t pending_locate_frame;
bool pending_locate_flush;
bool pending_abort;
@@ -1156,7 +1156,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
uint32_t rf_scale;
void set_rf_speed (float speed);
- void reset_rf_scale (jack_nframes_t frames_moved);
+ void reset_rf_scale (nframes_t frames_moved);
Locations _locations;
void locations_changed ();
@@ -1191,7 +1191,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
void dump_events () const;
void queue_event (Event *ev);
void merge_event (Event*);
- void replace_event (Event::Type, jack_nframes_t action_frame, jack_nframes_t target = 0);
+ void replace_event (Event::Type, nframes_t action_frame, nframes_t target = 0);
bool _replace_event (Event*);
bool _remove_event (Event *);
void _clear_event_type (Event::Type);
@@ -1232,7 +1232,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
/* MIDI Machine Control */
- void deliver_mmc (MIDI::MachineControl::Command, jack_nframes_t);
+ void deliver_mmc (MIDI::MachineControl::Command, nframes_t);
void deliver_midi_message (MIDI::Port * port, MIDI::eventType ev, MIDI::channel_t, MIDI::EventTwoBytes);
void deliver_data (MIDI::Port* port, MIDI::byte*, int32_t size);
@@ -1268,14 +1268,14 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
MIDI::byte mtc_msg[16];
MIDI::byte mtc_smpte_bits; /* encoding of SMTPE type for MTC */
MIDI::byte midi_msg[16];
- jack_nframes_t outbound_mtc_smpte_frame;
+ nframes_t outbound_mtc_smpte_frame;
SMPTE::Time transmitting_smpte_time;
int next_quarter_frame_to_send;
double _frames_per_smpte_frame; /* has to be floating point because of drop frame */
- jack_nframes_t _frames_per_hour;
- jack_nframes_t _smpte_frames_per_hour;
- jack_nframes_t _smpte_offset;
+ nframes_t _frames_per_hour;
+ nframes_t _smpte_frames_per_hour;
+ nframes_t _smpte_offset;
bool _smpte_offset_negative;
/* cache the most-recently requested time conversions.
@@ -1284,7 +1284,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
*/
bool last_smpte_valid;
- jack_nframes_t last_smpte_when;
+ nframes_t last_smpte_when;
SMPTE::Time last_smpte;
int send_full_time_code ();
@@ -1293,13 +1293,13 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
void send_full_time_code_in_another_thread ();
void send_midi_time_code_in_another_thread ();
void send_time_code_in_another_thread (bool full);
- void send_mmc_in_another_thread (MIDI::MachineControl::Command, jack_nframes_t frame = 0);
+ void send_mmc_in_another_thread (MIDI::MachineControl::Command, nframes_t frame = 0);
- jack_nframes_t adjust_apparent_position (jack_nframes_t frames);
+ nframes_t adjust_apparent_position (nframes_t frames);
void reset_record_status ();
- int no_roll (jack_nframes_t nframes, jack_nframes_t offset);
+ int no_roll (nframes_t nframes, nframes_t offset);
bool non_realtime_work_pending() const { return static_cast<bool>(post_transport_work); }
bool process_can_proceed() const { return !(post_transport_work & ProcessCannotProceedMask); }
@@ -1318,7 +1318,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
Type type;
MIDI::MachineControl::Command mmc_cmd;
- jack_nframes_t locate_frame;
+ nframes_t locate_frame;
// for SendMessage type
@@ -1367,9 +1367,9 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
void set_play_loop (bool yn);
void overwrite_some_buffers (Diskstream*);
void flush_all_redirects ();
- void locate (jack_nframes_t, bool with_roll, bool with_flush, bool with_loop=false);
- void start_locate (jack_nframes_t, bool with_roll, bool with_flush, bool with_loop=false);
- void force_locate (jack_nframes_t frame, bool with_roll = false);
+ void locate (nframes_t, bool with_roll, bool with_flush, bool with_loop=false);
+ void start_locate (nframes_t, bool with_roll, bool with_flush, bool with_loop=false);
+ void force_locate (nframes_t frame, bool with_roll = false);
void set_diskstream_speed (Diskstream*, float speed);
void set_transport_speed (float speed, bool abort = false);
void stop_transport (bool abort = false);
@@ -1502,7 +1502,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
/* FLATTEN */
- int flatten_one_track (AudioTrack&, jack_nframes_t start, jack_nframes_t cnt);
+ int flatten_one_track (AudioTrack&, nframes_t start, nframes_t cnt);
/* INSERT AND SEND MANAGEMENT */
@@ -1576,7 +1576,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
void set_global_solo (GlobalRouteBooleanState s, void *src);
void set_global_record_enable (GlobalRouteBooleanState s, void *src);
- void jack_timebase_callback (jack_transport_state_t, jack_nframes_t, jack_position_t*, int);
+ void jack_timebase_callback (jack_transport_state_t, nframes_t, jack_position_t*, int);
int jack_sync_callback (jack_transport_state_t, jack_position_t*);
void record_enable_change_all (bool yn);
@@ -1585,12 +1585,12 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
/* click track */
struct Click {
- jack_nframes_t start;
- jack_nframes_t duration;
- jack_nframes_t offset;
+ nframes_t start;
+ nframes_t duration;
+ nframes_t offset;
const Sample *data;
- Click (jack_nframes_t s, jack_nframes_t d, const Sample *b)
+ Click (nframes_t s, nframes_t d, const Sample *b)
: start (s), duration (d), data (b) { offset = 0; }
void *operator new(size_t ignored) {
@@ -1612,19 +1612,19 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
boost::shared_ptr<IO> _click_io;
Sample* click_data;
Sample* click_emphasis_data;
- jack_nframes_t click_length;
- jack_nframes_t click_emphasis_length;
+ nframes_t click_length;
+ nframes_t click_emphasis_length;
mutable Glib::RWLock click_lock;
static const Sample default_click[];
- static const jack_nframes_t default_click_length;
+ static const nframes_t default_click_length;
static const Sample default_click_emphasis[];
- static const jack_nframes_t default_click_emphasis_length;
+ static const nframes_t default_click_emphasis_length;
Click *get_click();
void setup_click_sounds (int which);
void clear_clicks ();
- void click (jack_nframes_t start, jack_nframes_t nframes, jack_nframes_t offset);
+ void click (nframes_t start, nframes_t nframes, nframes_t offset);
vector<Route*> master_outs;
@@ -1646,7 +1646,7 @@ class Session : public sigc::trackable, public PBD::StatefulDestructible
gain_t* _gain_automation_buffer;
pan_t** _pan_automation_buffer;
- void allocate_pan_automation_buffers (jack_nframes_t nframes, uint32_t howmany, bool force);
+ void allocate_pan_automation_buffers (nframes_t nframes, uint32_t howmany, bool force);
uint32_t _npan_buffers;
/* VST support */
diff --git a/libs/ardour/ardour/slave.h b/libs/ardour/ardour/slave.h
index 0079c10e0a..d4a7e2f22a 100644
--- a/libs/ardour/ardour/slave.h
+++ b/libs/ardour/ardour/slave.h
@@ -42,11 +42,11 @@ class Slave {
Slave() { }
virtual ~Slave() {}
- virtual bool speed_and_position (float&, jack_nframes_t&) = 0;
+ virtual bool speed_and_position (float&, nframes_t&) = 0;
virtual bool locked() const = 0;
virtual bool ok() const = 0;
virtual bool starting() const { return false; }
- virtual jack_nframes_t resolution() const = 0;
+ virtual nframes_t resolution() const = 0;
virtual bool requires_seekahead () const = 0;
};
@@ -57,13 +57,13 @@ class MTC_Slave : public Slave, public sigc::trackable {
~MTC_Slave ();
void rebind (MIDI::Port&);
- bool speed_and_position (float&, jack_nframes_t&);
+ bool speed_and_position (float&, nframes_t&);
bool locked() const;
bool ok() const;
void handle_locate (const MIDI::byte*);
- jack_nframes_t resolution() const;
+ nframes_t resolution() const;
bool requires_seekahead () const { return true; }
private:
@@ -76,8 +76,8 @@ class MTC_Slave : public Slave, public sigc::trackable {
int guard1;
//SMPTE_Time mtc;
- jack_nframes_t position;
- jack_nframes_t timestamp;
+ nframes_t position;
+ nframes_t timestamp;
int guard2;
SafeTime() {
@@ -88,12 +88,12 @@ class MTC_Slave : public Slave, public sigc::trackable {
};
SafeTime current;
- jack_nframes_t mtc_frame; /* current time */
- jack_nframes_t last_inbound_frame; /* when we got it; audio clocked */
+ nframes_t mtc_frame; /* current time */
+ nframes_t last_inbound_frame; /* when we got it; audio clocked */
float mtc_speed;
- jack_nframes_t first_mtc_frame;
- jack_nframes_t first_mtc_time;
+ nframes_t first_mtc_frame;
+ nframes_t first_mtc_time;
static const int32_t accumulator_size = 128;
float accumulator[accumulator_size];
@@ -113,7 +113,7 @@ class ADAT_Slave : public Slave
ADAT_Slave () {}
~ADAT_Slave () {}
- bool speed_and_position (float& speed, jack_nframes_t& pos) {
+ bool speed_and_position (float& speed, nframes_t& pos) {
speed = 0;
pos = 0;
return false;
@@ -121,7 +121,7 @@ class ADAT_Slave : public Slave
bool locked() const { return false; }
bool ok() const { return false; }
- jack_nframes_t resolution() const { return 1; }
+ nframes_t resolution() const { return 1; }
bool requires_seekahead () const { return true; }
};
@@ -131,12 +131,12 @@ class JACK_Slave : public Slave
JACK_Slave (jack_client_t*);
~JACK_Slave ();
- bool speed_and_position (float& speed, jack_nframes_t& pos);
+ bool speed_and_position (float& speed, nframes_t& pos);
bool starting() const { return _starting; }
bool locked() const;
bool ok() const;
- jack_nframes_t resolution() const { return 1; }
+ nframes_t resolution() const { return 1; }
bool requires_seekahead () const { return false; }
private:
diff --git a/libs/ardour/ardour/sndfilesource.h b/libs/ardour/ardour/sndfilesource.h
index cb6bd2e920..50fd5e6839 100644
--- a/libs/ardour/ardour/sndfilesource.h
+++ b/libs/ardour/ardour/sndfilesource.h
@@ -35,7 +35,7 @@ class SndFileSource : public AudioFileSource {
/* constructor to be called for new in-session files */
- SndFileSource (Session&, std::string path, SampleFormat samp_format, HeaderFormat hdr_format, jack_nframes_t rate,
+ SndFileSource (Session&, std::string path, SampleFormat samp_format, HeaderFormat hdr_format, nframes_t rate,
Flag flags = AudioFileSource::Flag (AudioFileSource::Writable|
AudioFileSource::Removable|
AudioFileSource::RemovableIfEmpty|
@@ -48,18 +48,18 @@ class SndFileSource : public AudioFileSource {
~SndFileSource ();
float sample_rate () const;
- int update_header (jack_nframes_t when, struct tm&, time_t);
+ int update_header (nframes_t when, struct tm&, time_t);
int flush_header ();
- jack_nframes_t natural_position () const;
+ nframes_t natural_position () const;
protected:
void set_header_timeline_position ();
- jack_nframes_t read_unlocked (Sample *dst, jack_nframes_t start, jack_nframes_t cnt) const;
- jack_nframes_t write_unlocked (Sample *dst, jack_nframes_t cnt);
+ nframes_t read_unlocked (Sample *dst, nframes_t start, nframes_t cnt) const;
+ nframes_t write_unlocked (Sample *dst, nframes_t cnt);
- jack_nframes_t write_float (Sample* data, jack_nframes_t pos, jack_nframes_t cnt);
+ nframes_t write_float (Sample* data, nframes_t pos, nframes_t cnt);
private:
SNDFILE *sf;
@@ -67,12 +67,12 @@ class SndFileSource : public AudioFileSource {
SF_BROADCAST_INFO *_broadcast_info;
mutable float *interleave_buf;
- mutable jack_nframes_t interleave_bufsize;
+ mutable nframes_t interleave_bufsize;
void init (const string &str);
int open();
void close();
- int setup_broadcast_info (jack_nframes_t when, struct tm&, time_t);
+ int setup_broadcast_info (nframes_t when, struct tm&, time_t);
};
} // namespace ARDOUR
diff --git a/libs/ardour/ardour/source_factory.h b/libs/ardour/ardour/source_factory.h
index 9b2a7d98f0..815b825b8d 100644
--- a/libs/ardour/ardour/source_factory.h
+++ b/libs/ardour/ardour/source_factory.h
@@ -23,7 +23,7 @@ class SourceFactory {
// MIDI sources will have to be hacked in here somehow
static boost::shared_ptr<Source> createReadable (Session&, std::string idstr, AudioFileSource::Flag flags, bool announce = true);
- static boost::shared_ptr<Source> createWritable (Session&, std::string name, bool destructive, jack_nframes_t rate, bool announce = true);
+ static boost::shared_ptr<Source> createWritable (Session&, std::string name, bool destructive, nframes_t rate, bool announce = true);
};
}
diff --git a/libs/ardour/ardour/tempo.h b/libs/ardour/ardour/tempo.h
index 0b37579ecb..7cdbe56cf2 100644
--- a/libs/ardour/ardour/tempo.h
+++ b/libs/ardour/ardour/tempo.h
@@ -57,7 +57,7 @@ class Tempo {
}
double beats_per_minute () const { return _beats_per_minute; }
- double frames_per_beat (jack_nframes_t sr) const {
+ double frames_per_beat (nframes_t sr) const {
return ((60.0 * sr) / _beats_per_minute);
}
@@ -85,7 +85,7 @@ class Meter {
double beats_per_bar () const { return _beats_per_bar; }
double note_divisor() const { return _note_type; }
- double frames_per_bar (const Tempo&, jack_nframes_t sr) const;
+ double frames_per_bar (const Tempo&, nframes_t sr) const;
protected:
@@ -112,12 +112,12 @@ class MetricSection {
virtual ~MetricSection() {}
const BBT_Time& start() const { return _start; }
- const jack_nframes_t frame() const { return _frame; }
+ const nframes_t frame() const { return _frame; }
void set_movable (bool yn) { _movable = yn; }
bool movable() const { return _movable; }
- virtual void set_frame (jack_nframes_t f) {
+ virtual void set_frame (nframes_t f) {
_frame = f;
};
@@ -134,7 +134,7 @@ class MetricSection {
private:
BBT_Time _start;
- jack_nframes_t _frame;
+ nframes_t _frame;
bool _movable;
};
@@ -176,7 +176,7 @@ class TempoMap : public StateManager, public PBD::StatefulDestructible
{
public:
- TempoMap (jack_nframes_t frame_rate);
+ TempoMap (nframes_t frame_rate);
~TempoMap();
/* measure-based stuff */
@@ -188,13 +188,13 @@ class TempoMap : public StateManager, public PBD::StatefulDestructible
struct BBTPoint {
BBTPointType type;
- jack_nframes_t frame;
+ nframes_t frame;
const Meter* meter;
const Tempo* tempo;
uint32_t bar;
uint32_t beat;
- BBTPoint (const Meter& m, const Tempo& t, jack_nframes_t f, BBTPointType ty, uint32_t b, uint32_t e)
+ BBTPoint (const Meter& m, const Tempo& t, nframes_t f, BBTPointType ty, uint32_t b, uint32_t e)
: type (ty), frame (f), meter (&m), tempo (&t), bar (b), beat (e) {}
};
@@ -205,17 +205,17 @@ class TempoMap : public StateManager, public PBD::StatefulDestructible
(obj.*method)(*metrics);
}
- BBTPointList *get_points (jack_nframes_t start, jack_nframes_t end) const;
+ BBTPointList *get_points (nframes_t start, nframes_t end) const;
- void bbt_time (jack_nframes_t when, BBT_Time&) const;
- jack_nframes_t frame_time (const BBT_Time&) const;
- jack_nframes_t bbt_duration_at (jack_nframes_t, const BBT_Time&, int dir) const;
+ void bbt_time (nframes_t when, BBT_Time&) const;
+ nframes_t frame_time (const BBT_Time&) const;
+ nframes_t bbt_duration_at (nframes_t, const BBT_Time&, int dir) const;
static const Tempo& default_tempo() { return _default_tempo; }
static const Meter& default_meter() { return _default_meter; }
- const Tempo& tempo_at (jack_nframes_t);
- const Meter& meter_at (jack_nframes_t);
+ const Tempo& tempo_at (nframes_t);
+ const Meter& meter_at (nframes_t);
void add_tempo(const Tempo&, BBT_Time where);
void add_meter(const Meter&, BBT_Time where);
@@ -230,15 +230,15 @@ class TempoMap : public StateManager, public PBD::StatefulDestructible
void replace_meter (MeterSection& existing, const Meter& replacement);
- jack_nframes_t round_to_bar (jack_nframes_t frame, int dir);
+ nframes_t round_to_bar (nframes_t frame, int dir);
- jack_nframes_t round_to_beat (jack_nframes_t frame, int dir);
+ nframes_t round_to_beat (nframes_t frame, int dir);
- jack_nframes_t round_to_beat_subdivision (jack_nframes_t fr, int sub_num);
+ nframes_t round_to_beat_subdivision (nframes_t fr, int sub_num);
- jack_nframes_t round_to_tick (jack_nframes_t frame, int dir);
+ nframes_t round_to_tick (nframes_t frame, int dir);
- void set_length (jack_nframes_t frames);
+ void set_length (nframes_t frames);
XMLNode& get_state (void);
int set_state (const XMLNode&);
@@ -259,33 +259,33 @@ class TempoMap : public StateManager, public PBD::StatefulDestructible
void set_tempo (const Tempo& t) { _tempo = &t; }
void set_meter (const Meter& m) { _meter = &m; }
- void set_frame (jack_nframes_t f) { _frame = f; }
+ void set_frame (nframes_t f) { _frame = f; }
void set_start (const BBT_Time& t) { _start = t; }
const Meter& meter() const { return *_meter; }
const Tempo& tempo() const { return *_tempo; }
- jack_nframes_t frame() const { return _frame; }
+ nframes_t frame() const { return _frame; }
const BBT_Time& start() const { return _start; }
private:
const Meter* _meter;
const Tempo* _tempo;
- jack_nframes_t _frame;
+ nframes_t _frame;
BBT_Time _start;
};
Metric metric_at (BBT_Time bbt) const;
- Metric metric_at (jack_nframes_t) const;
- void bbt_time_with_metric (jack_nframes_t, BBT_Time&, const Metric&) const;
+ Metric metric_at (nframes_t) const;
+ void bbt_time_with_metric (nframes_t, BBT_Time&, const Metric&) const;
private:
static Tempo _default_tempo;
static Meter _default_meter;
Metrics *metrics;
- jack_nframes_t _frame_rate;
- jack_nframes_t last_bbt_when;
+ nframes_t _frame_rate;
+ nframes_t last_bbt_when;
bool last_bbt_valid;
BBT_Time last_bbt;
mutable Glib::RWLock lock;
@@ -293,19 +293,19 @@ class TempoMap : public StateManager, public PBD::StatefulDestructible
void timestamp_metrics ();
- jack_nframes_t round_to_type (jack_nframes_t fr, int dir, BBTPointType);
+ nframes_t round_to_type (nframes_t fr, int dir, BBTPointType);
- jack_nframes_t frame_time_unlocked (const BBT_Time&) const;
+ nframes_t frame_time_unlocked (const BBT_Time&) const;
- void bbt_time_unlocked (jack_nframes_t, BBT_Time&) const;
+ void bbt_time_unlocked (nframes_t, BBT_Time&) const;
- jack_nframes_t bbt_duration_at_unlocked (const BBT_Time& when, const BBT_Time& bbt, int dir) const;
+ nframes_t bbt_duration_at_unlocked (const BBT_Time& when, const BBT_Time& bbt, int dir) const;
const MeterSection& first_meter() const;
const TempoSection& first_tempo() const;
- jack_nframes_t count_frames_between (const BBT_Time&, const BBT_Time&) const;
- jack_nframes_t count_frames_between_metrics (const Meter&, const Tempo&, const BBT_Time&, const BBT_Time&) const;
+ nframes_t count_frames_between (const BBT_Time&, const BBT_Time&) const;
+ nframes_t count_frames_between_metrics (const Meter&, const Tempo&, const BBT_Time&, const BBT_Time&) const;
int move_metric_section (MetricSection&, const BBT_Time& to);
void do_insert (MetricSection* section);
diff --git a/libs/ardour/ardour/track.h b/libs/ardour/ardour/track.h
index ec444e78dc..cf380de153 100644
--- a/libs/ardour/ardour/track.h
+++ b/libs/ardour/ardour/track.h
@@ -39,14 +39,14 @@ class Track : public Route
int set_name (string str, void *src);
- virtual int roll (jack_nframes_t nframes, jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t offset, int declick, bool can_record, bool rec_monitors_input) = 0;
+ virtual int roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame,
+ nframes_t offset, int declick, bool can_record, bool rec_monitors_input) = 0;
- virtual int no_roll (jack_nframes_t nframes, jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t offset, bool state_changing, bool can_record, bool rec_monitors_input) = 0;
+ virtual int no_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame,
+ nframes_t offset, bool state_changing, bool can_record, bool rec_monitors_input) = 0;
- virtual int silent_roll (jack_nframes_t nframes, jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t offset, bool can_record, bool rec_monitors_input) = 0;
+ virtual int silent_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame,
+ nframes_t offset, bool can_record, bool rec_monitors_input) = 0;
void toggle_monitor_input ();
@@ -60,8 +60,8 @@ class Track : public Route
TrackMode mode() const { return _mode; }
void set_mode (TrackMode m);
- jack_nframes_t update_total_latency();
- void set_latency_delay (jack_nframes_t);
+ nframes_t update_total_latency();
+ void set_latency_delay (nframes_t);
enum FreezeState {
NoFreeze,
@@ -75,7 +75,7 @@ class Track : public Route
virtual void unfreeze () = 0;
virtual void bounce (InterThreadInfo&) = 0;
- virtual void bounce_range (jack_nframes_t start, jack_nframes_t end, InterThreadInfo&) = 0;
+ virtual void bounce_range (nframes_t start, nframes_t end, InterThreadInfo&) = 0;
XMLNode& get_state();
XMLNode& get_template();
@@ -97,8 +97,8 @@ class Track : public Route
virtual XMLNode& state (bool full) = 0;
- virtual void passthru_silence (jack_nframes_t start_frame, jack_nframes_t end_frame,
- jack_nframes_t nframes, jack_nframes_t offset, int declick, bool meter) = 0;
+ virtual void passthru_silence (nframes_t start_frame, nframes_t end_frame,
+ nframes_t nframes, nframes_t offset, int declick, bool meter) = 0;
virtual uint32_t n_process_buffers () = 0;
diff --git a/libs/ardour/ardour/types.h b/libs/ardour/ardour/types.h
index b70448e8a5..d4e49bc624 100644
--- a/libs/ardour/ardour/types.h
+++ b/libs/ardour/ardour/types.h
@@ -41,6 +41,13 @@
typedef int intptr_t;
#endif
+/* at some point move this into the ARDOUR namespace,
+ but for now its outside because it replaces the
+ old global "jack_nframes_t"
+*/
+
+typedef uint32_t nframes_t;
+
namespace ARDOUR {
class Source;
@@ -66,8 +73,8 @@ namespace ARDOUR {
OverlapExternal // overlap extends to (at least) begin+end
};
- OverlapType coverage (jack_nframes_t start_a, jack_nframes_t end_a,
- jack_nframes_t start_b, jack_nframes_t end_b);
+ OverlapType coverage (nframes_t start_a, nframes_t end_a,
+ nframes_t start_b, nframes_t end_b);
enum AutomationType {
GainAutomation = 0x1,
@@ -147,7 +154,7 @@ namespace ARDOUR {
BBT_Time bbt;
union {
- jack_nframes_t frames;
+ nframes_t frames;
double seconds;
};
@@ -155,13 +162,13 @@ namespace ARDOUR {
};
struct AudioRange {
- jack_nframes_t start;
- jack_nframes_t end;
+ nframes_t start;
+ nframes_t end;
uint32_t id;
- AudioRange (jack_nframes_t s, jack_nframes_t e, uint32_t i) : start (s), end (e) , id (i) {}
+ AudioRange (nframes_t s, nframes_t e, uint32_t i) : start (s), end (e) , id (i) {}
- jack_nframes_t length() { return end - start + 1; }
+ nframes_t length() { return end - start + 1; }
bool operator== (const AudioRange& other) const {
return start == other.start && end == other.end && id == other.id;
@@ -171,7 +178,7 @@ namespace ARDOUR {
return start == other.start && end == other.end;
}
- OverlapType coverage (jack_nframes_t s, jack_nframes_t e) const {
+ OverlapType coverage (nframes_t s, nframes_t e) const {
return ARDOUR::coverage (start, end, s, e);
}
};
@@ -302,16 +309,16 @@ std::istream& operator>>(std::istream& o, ARDOUR::SlaveSource& sf);
std::istream& operator>>(std::istream& o, ARDOUR::ShuttleBehaviour& sf);
std::istream& operator>>(std::istream& o, ARDOUR::ShuttleUnits& sf);
-static inline jack_nframes_t
-session_frame_to_track_frame (jack_nframes_t session_frame, double speed)
+static inline nframes_t
+session_frame_to_track_frame (nframes_t session_frame, double speed)
{
- return (jack_nframes_t)( (double)session_frame * speed );
+ return (nframes_t)( (double)session_frame * speed );
}
-static inline jack_nframes_t
-track_frame_to_session_frame (jack_nframes_t track_frame, double speed)
+static inline nframes_t
+track_frame_to_session_frame (nframes_t track_frame, double speed)
{
- return (jack_nframes_t)( (double)track_frame / speed );
+ return (nframes_t)( (double)track_frame / speed );
}
diff --git a/libs/ardour/ardour/utils.h b/libs/ardour/ardour/utils.h
index ab9f2ad952..1764885366 100644
--- a/libs/ardour/ardour/utils.h
+++ b/libs/ardour/ardour/utils.h
@@ -57,7 +57,7 @@ int touch_file(std::string path);
std::string region_name_from_path (std::string path);
std::string path_expand (std::string);
-void compute_equal_power_fades (jack_nframes_t nframes, float* in, float* out);
+void compute_equal_power_fades (nframes_t nframes, float* in, float* out);
const char* slave_source_to_string (ARDOUR::SlaveSource src);
ARDOUR::SlaveSource string_to_slave_source (std::string str);
diff --git a/libs/ardour/ardour/vst_plugin.h b/libs/ardour/ardour/vst_plugin.h
index 4fb5b0babb..7b8246868c 100644
--- a/libs/ardour/ardour/vst_plugin.h
+++ b/libs/ardour/ardour/vst_plugin.h
@@ -64,7 +64,7 @@ class VSTPlugin : public ARDOUR::Plugin
const char * maker() const;
uint32_t parameter_count() const;
float default_value (uint32_t port);
- jack_nframes_t latency() const;
+ nframes_t 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;
@@ -72,8 +72,8 @@ class VSTPlugin : public ARDOUR::Plugin
uint32_t nth_parameter (uint32_t port, bool& ok) const;
void activate ();
void deactivate ();
- void set_block_size (jack_nframes_t nframes);
- int connect_and_run (vector<Sample*>& bufs, uint32_t maxbuf, int32_t& in, int32_t& out, jack_nframes_t nframes, jack_nframes_t offset);
+ void set_block_size (nframes_t nframes);
+ int connect_and_run (vector<Sample*>& bufs, uint32_t maxbuf, int32_t& in, int32_t& out, nframes_t nframes, nframes_t offset);
void store_state (ARDOUR::PluginState&);
void restore_state (ARDOUR::PluginState&);
string describe_parameter (uint32_t);