diff options
Diffstat (limited to 'libs/ardour/ardour')
-rw-r--r-- | libs/ardour/ardour/bbt_time.h | 12 | ||||
-rw-r--r-- | libs/ardour/ardour/session.h | 2 |
2 files changed, 13 insertions, 1 deletions
diff --git a/libs/ardour/ardour/bbt_time.h b/libs/ardour/ardour/bbt_time.h index 76e91d5752..2157e794a2 100644 --- a/libs/ardour/ardour/bbt_time.h +++ b/libs/ardour/ardour/bbt_time.h @@ -22,6 +22,7 @@ #include <ostream> #include <stdint.h> +#include <iomanip> namespace ARDOUR { @@ -59,4 +60,15 @@ operator<< (std::ostream& o, const ARDOUR::BBT_Time& bbt) return o; } +inline std::ostream& +print_padded (std::ostream& o, const ARDOUR::BBT_Time& bbt) +{ + o << std::setfill ('0') << std::right + << std::setw (3) << bbt.bars << "|" + << std::setw (2) << bbt.beats << "|" + << std::setw (4) << bbt.ticks; + + return o; +} + #endif /* __ardour_bbt_time_h__ */ diff --git a/libs/ardour/ardour/session.h b/libs/ardour/ardour/session.h index 82b5d1360d..7c7ff820e9 100644 --- a/libs/ardour/ardour/session.h +++ b/libs/ardour/ardour/session.h @@ -453,7 +453,7 @@ class Session : public PBD::StatefulDestructible, public PBD::ScopedConnectionLi void timecode_time (nframes_t when, Timecode::Time&); void timecode_time_subframes (nframes_t when, Timecode::Time&); - void timecode_duration (nframes_t, Timecode::Time&) const; + void timecode_duration (framecnt_t, Timecode::Time&) const; void timecode_duration_string (char *, framecnt_t) const; void set_timecode_offset (nframes_t); |