diff options
Diffstat (limited to 'libs/ardour/ardour')
-rw-r--r-- | libs/ardour/ardour/element_importer.h | 4 | ||||
-rw-r--r-- | libs/ardour/ardour/export_profile_manager.h | 4 | ||||
-rw-r--r-- | libs/ardour/ardour/session.h | 64 | ||||
-rw-r--r-- | libs/ardour/ardour/session_configuration_vars.h | 2 | ||||
-rw-r--r-- | libs/ardour/ardour/ticker.h | 4 | ||||
-rw-r--r-- | libs/ardour/ardour/timecode.h (renamed from libs/ardour/ardour/smpte.h) | 36 | ||||
-rw-r--r-- | libs/ardour/ardour/types.h | 26 |
7 files changed, 70 insertions, 70 deletions
diff --git a/libs/ardour/ardour/element_importer.h b/libs/ardour/ardour/element_importer.h index 9d2d9cc0de..396ac8358d 100644 --- a/libs/ardour/ardour/element_importer.h +++ b/libs/ardour/ardour/element_importer.h @@ -110,8 +110,8 @@ class ElementImporter /// The sample rate of the session from which we are importing nframes_t sample_rate; - /// Converts smpte time to a string - std::string smpte_to_string (SMPTE::Time & time) const; + /// Converts timecode time to a string + std::string timecode_to_string (Timecode::Time & time) const; /// Converts samples so that times match the sessions sample rate nframes_t rate_convert_samples (nframes_t samples) const; diff --git a/libs/ardour/ardour/export_profile_manager.h b/libs/ardour/ardour/export_profile_manager.h index b402550a64..47acacd387 100644 --- a/libs/ardour/ardour/export_profile_manager.h +++ b/libs/ardour/ardour/export_profile_manager.h @@ -108,7 +108,7 @@ class ExportProfileManager typedef std::list<Location *> LocationList; enum TimeFormat { - SMPTE, + Timecode, BBT, MinSec, Frames, @@ -127,7 +127,7 @@ class ExportProfileManager boost::shared_ptr<Location> selection_range, boost::shared_ptr<LocationList> ranges) : timespans (new TimespanList ()), - time_format (SMPTE), + time_format (Timecode), session_range (session_range), selection_range (selection_range), diff --git a/libs/ardour/ardour/session.h b/libs/ardour/ardour/session.h index baf7343496..024b866730 100644 --- a/libs/ardour/ardour/session.h +++ b/libs/ardour/ardour/session.h @@ -54,7 +54,7 @@ #include "ardour/rc_configuration.h" #include "ardour/session_configuration.h" #include "ardour/location.h" -#include "ardour/smpte.h" +#include "ardour/timecode.h" #include "ardour/interpolation.h" class XMLTree; @@ -421,15 +421,15 @@ class Session : public PBD::StatefulDestructible, public boost::noncopyable nframes_t nominal_frame_rate() const { return _nominal_frame_rate; } nframes_t frames_per_hour() const { return _frames_per_hour; } - double frames_per_smpte_frame() const { return _frames_per_smpte_frame; } - nframes_t smpte_frames_per_hour() const { return _smpte_frames_per_hour; } + double frames_per_timecode_frame() const { return _frames_per_timecode_frame; } + nframes_t timecode_frames_per_hour() const { return _timecode_frames_per_hour; } - MIDI::byte get_mtc_smpte_bits() const { - return mtc_smpte_bits; /* encoding of SMTPE type for MTC */ + MIDI::byte get_mtc_timecode_bits() const { + return mtc_timecode_bits; /* encoding of SMTPE type for MTC */ } - float smpte_frames_per_second() const; - bool smpte_drop_frames() const; + float timecode_frames_per_second() const; + bool timecode_drop_frames() const; /* Locations */ @@ -551,25 +551,25 @@ class Session : public PBD::StatefulDestructible, public boost::noncopyable void sync_time_vars(); 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 (nframes_t when, SMPTE::Time&); - void smpte_time_subframes (nframes_t when, SMPTE::Time&); + void timecode_to_sample(Timecode::Time& timecode, nframes_t& sample, bool use_offset, bool use_subframes) const; + void sample_to_timecode(nframes_t sample, Timecode::Time& timecode, bool use_offset, bool use_subframes) const; + void timecode_time (Timecode::Time &); + void timecode_time (nframes_t when, Timecode::Time&); + void timecode_time_subframes (nframes_t when, Timecode::Time&); - void smpte_duration (nframes_t, SMPTE::Time&) const; - void smpte_duration_string (char *, nframes_t) const; + void timecode_duration (nframes_t, Timecode::Time&) const; + void timecode_duration_string (char *, nframes_t) const; - 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; } + void set_timecode_offset (nframes_t); + nframes_t timecode_offset () const { return _timecode_offset; } + void set_timecode_offset_negative (bool); + bool timecode_offset_negative () const { return _timecode_offset_negative; } nframes_t convert_to_frames_at (nframes_t position, AnyTime const &); static sigc::signal<void> StartTimeChanged; static sigc::signal<void> EndTimeChanged; - static sigc::signal<void> SMPTEOffsetChanged; + static sigc::signal<void> TimecodeOffsetChanged; void request_slave_source (SlaveSource); bool synced_to_jack() const { return Config->get_slave_source() == JACK; } @@ -585,8 +585,8 @@ class Session : public PBD::StatefulDestructible, public boost::noncopyable TempoMap& tempo_map() { return *_tempo_map; } - /// signals the current transport position in frames, bbt and smpte time (in that order) - sigc::signal<void, const nframes_t&, const BBT_Time&, const SMPTE::Time&> tick; + /// signals the current transport position in frames, bbt and timecode time (in that order) + sigc::signal<void, const nframes_t&, const BBT_Time&, const Timecode::Time&> tick; /* region info */ @@ -1331,25 +1331,25 @@ class Session : public PBD::StatefulDestructible, public boost::noncopyable MIDI::byte mmc_buffer[32]; MIDI::byte mtc_msg[16]; - MIDI::byte mtc_smpte_bits; /* encoding of SMTPE type for MTC */ + MIDI::byte mtc_timecode_bits; /* encoding of SMTPE type for MTC */ MIDI::byte midi_msg[16]; - nframes_t outbound_mtc_smpte_frame; - SMPTE::Time transmitting_smpte_time; + nframes_t outbound_mtc_timecode_frame; + Timecode::Time transmitting_timecode_time; int next_quarter_frame_to_send; - double _frames_per_smpte_frame; /* has to be floating point because of drop frame */ + double _frames_per_timecode_frame; /* has to be floating point because of drop frame */ nframes_t _frames_per_hour; - nframes_t _smpte_frames_per_hour; - nframes_t _smpte_offset; - bool _smpte_offset_negative; + nframes_t _timecode_frames_per_hour; + nframes_t _timecode_offset; + bool _timecode_offset_negative; /* cache the most-recently requested time conversions. This helps when we * have multiple clocks showing the same time (e.g. the transport frame) */ - bool last_smpte_valid; - nframes_t last_smpte_when; - SMPTE::Time last_smpte; + bool last_timecode_valid; + nframes_t last_timecode_when; + Timecode::Time last_timecode; - bool _send_smpte_update; ///< Flag to send a full frame (SMPTE) MTC message this cycle + bool _send_timecode_update; ///< Flag to send a full frame (Timecode) MTC message this cycle int send_full_time_code(nframes_t nframes); int send_midi_time_code_for_cycle(nframes_t nframes); diff --git a/libs/ardour/ardour/session_configuration_vars.h b/libs/ardour/ardour/session_configuration_vars.h index 5330932b26..8c1dffc884 100644 --- a/libs/ardour/ardour/session_configuration_vars.h +++ b/libs/ardour/ardour/session_configuration_vars.h @@ -33,7 +33,7 @@ CONFIG_VARIABLE (bool, auto_input, "auto-input", true) CONFIG_VARIABLE (bool, punch_in, "punch-in", false) CONFIG_VARIABLE (bool, punch_out, "punch-out", false) CONFIG_VARIABLE (uint32_t, subframes_per_frame, "subframes-per-frame", 100) -CONFIG_VARIABLE (SmpteFormat, smpte_format, "smpte-format", smpte_30) +CONFIG_VARIABLE (SmpteFormat, timecode_format, "timecode-format", timecode_30) CONFIG_VARIABLE_SPECIAL(Glib::ustring, raid_path, "raid-path", "", path_expand) CONFIG_VARIABLE (std::string, bwf_country_code, "bwf-country-code", "US") CONFIG_VARIABLE (std::string, bwf_organization_code, "bwf-organization-code", "US") diff --git a/libs/ardour/ardour/ticker.h b/libs/ardour/ardour/ticker.h index f87bca665d..3e0f1844a6 100644 --- a/libs/ardour/ardour/ticker.h +++ b/libs/ardour/ardour/ticker.h @@ -40,7 +40,7 @@ public: virtual void tick( const nframes_t& transport_frames, const BBT_Time& transport_bbt, - const SMPTE::Time& transport_smpte) = 0; + const Timecode::Time& transport_timecode) = 0; virtual void set_session(Session& s); virtual void going_away() { _session = 0; } @@ -68,7 +68,7 @@ public: void tick( const nframes_t& transport_frames, const BBT_Time& transport_bbt, - const SMPTE::Time& transport_smpte); + const Timecode::Time& transport_timecode); void set_session(Session& s); void going_away() { _midi_port = 0; Ticker::going_away(); } diff --git a/libs/ardour/ardour/smpte.h b/libs/ardour/ardour/timecode.h index fa18a1eec4..dd357ea33c 100644 --- a/libs/ardour/ardour/smpte.h +++ b/libs/ardour/ardour/timecode.h @@ -15,12 +15,12 @@ 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. */ -#ifndef __ardour_smpte_h__ -#define __ardour_smpte_h__ +#ifndef __ardour_timecode_h__ +#define __ardour_timecode_h__ #include <inttypes.h> -namespace SMPTE { +namespace Timecode { enum Wrap { NONE = 0, @@ -30,7 +30,7 @@ enum Wrap { HOURS }; -/** SMPTE frame rate (in frames per second). +/** Timecode frame rate (in frames per second). * * This should be eliminated in favour of a float to support arbitrary rates. */ @@ -46,7 +46,7 @@ struct Time { uint32_t hours; uint32_t minutes; uint32_t seconds; - uint32_t frames; ///< SMPTE frames (not audio samples) + uint32_t frames; ///< Timecode frames (not audio samples) uint32_t subframes; ///< Typically unused FPS rate; ///< Frame rate of this Time static FPS default_rate; ///< Rate to use for default constructor @@ -62,18 +62,18 @@ struct Time { } }; -Wrap increment( Time& smpte ); -Wrap decrement( Time& smpte ); -Wrap increment_subframes( Time& smpte ); -Wrap decrement_subframes( Time& smpte ); -Wrap increment_seconds( Time& smpte ); -Wrap increment_minutes( Time& smpte ); -Wrap increment_hours( Time& smpte ); -void frames_floor( Time& smpte ); -void seconds_floor( Time& smpte ); -void minutes_floor( Time& smpte ); -void hours_floor( Time& smpte ); +Wrap increment( Time& timecode ); +Wrap decrement( Time& timecode ); +Wrap increment_subframes( Time& timecode ); +Wrap decrement_subframes( Time& timecode ); +Wrap increment_seconds( Time& timecode ); +Wrap increment_minutes( Time& timecode ); +Wrap increment_hours( Time& timecode ); +void frames_floor( Time& timecode ); +void seconds_floor( Time& timecode ); +void minutes_floor( Time& timecode ); +void hours_floor( Time& timecode ); -} // namespace SMPTE +} // namespace Timecode -#endif // __ardour_smpte_h__ +#endif // __ardour_timecode_h__ diff --git a/libs/ardour/ardour/types.h b/libs/ardour/ardour/types.h index 38a0e6d625..1cc619424e 100644 --- a/libs/ardour/ardour/types.h +++ b/libs/ardour/ardour/types.h @@ -31,7 +31,7 @@ #include <inttypes.h> #include <jack/types.h> #include <jack/midiport.h> -#include "control_protocol/smpte.h" +#include "control_protocol/timecode.h" #include "pbd/id.h" #include <map> @@ -184,21 +184,21 @@ namespace ARDOUR { }; enum SmpteFormat { - smpte_23976, - smpte_24, - smpte_24976, - smpte_25, - smpte_2997, - smpte_2997drop, - smpte_30, - smpte_30drop, - smpte_5994, - smpte_60 + timecode_23976, + timecode_24, + timecode_24976, + timecode_25, + timecode_2997, + timecode_2997drop, + timecode_30, + timecode_30drop, + timecode_5994, + timecode_60 }; struct AnyTime { enum Type { - SMPTE, + Timecode, BBT, Frames, Seconds @@ -206,7 +206,7 @@ namespace ARDOUR { Type type; - SMPTE::Time smpte; + Timecode::Time timecode; BBT_Time bbt; union { |