45 #include <boost/optional.hpp>
57 extern bool operator== (Time
const & a, Time
const & b);
58 extern bool operator!= (Time
const & a, Time
const & b);
59 extern bool operator<= (Time
const & a, Time
const & b);
60 extern bool operator< (Time
const & a, Time
const & b);
61 extern bool operator> (Time
const & a, Time
const & b);
62 extern bool operator>= (Time
const & a, Time
const & b);
63 extern std::ostream & operator<< (std::ostream & s, Time
const & t);
64 extern Time operator+ (Time a, Time b);
65 extern Time operator- (Time a, Time b);
66 extern float operator/ (Time a, Time
const & b);
83 Time (
int frame,
double frames_per_second,
int tcr);
92 Time (
int h_,
int m_,
int s_,
int e_,
int tcr_)
105 Time (
double seconds,
int tcr);
115 Time (std::string time, boost::optional<int>
tcr);
124 std::string
as_string (Standard standard)
const;
157 void set (
double seconds,
int tcr);
A representation of time within a DCP.
int e
editable units (where 1 editable unit is 1 / tcr_ seconds)
int64_t as_editable_units_ceil(int tcr_) const
int64_t as_editable_units_floor(int tcr_) const
Time(std::string time, boost::optional< int > tcr)
double as_seconds() const
Time rebase(int tcr_) const
int tcr
timecode rate: the number of editable units per second.
void set(double seconds, int tcr)
std::string as_string(Standard standard) const
Time(int h_, int m_, int s_, int e_, int tcr_)
Namespace for everything in libdcp.