Mercurial > hg > svcore
comparison base/RealTime.h @ 1542:6415ac3becb6 zoom
Use proper decimal delimiter
author | Chris Cannam |
---|---|
date | Fri, 28 Sep 2018 18:06:05 +0100 |
parents | 71207822a7e0 |
children |
comparison
equal
deleted
inserted
replaced
1541:71207822a7e0 | 1542:6415ac3becb6 |
---|---|
55 | 55 |
56 RealTime(const Vamp::RealTime &r) : | 56 RealTime(const Vamp::RealTime &r) : |
57 sec(r.sec), nsec(r.nsec) { } | 57 sec(r.sec), nsec(r.nsec) { } |
58 | 58 |
59 static RealTime fromSeconds(double sec); | 59 static RealTime fromSeconds(double sec); |
60 static RealTime fromMilliseconds(int msec); | 60 static RealTime fromMilliseconds(int64_t msec); |
61 static RealTime fromMicroseconds(int usec); | 61 static RealTime fromMicroseconds(int64_t usec); |
62 static RealTime fromTimeval(const struct timeval &); | 62 static RealTime fromTimeval(const struct timeval &); |
63 static RealTime fromXsdDuration(std::string xsdd); | 63 static RealTime fromXsdDuration(std::string xsdd); |
64 | 64 |
65 double toDouble() const; | 65 double toDouble() const; |
66 Vamp::RealTime toVampRealTime() const { return Vamp::RealTime(sec, nsec); } | 66 Vamp::RealTime toVampRealTime() const { return Vamp::RealTime(sec, nsec); } |
170 * (29.97 not supported). | 170 * (29.97 not supported). |
171 * | 171 * |
172 * Unlike toText, this function does not depend on the application | 172 * Unlike toText, this function does not depend on the application |
173 * preferences. | 173 * preferences. |
174 */ | 174 */ |
175 std::string toFrameText(int fps, bool hms) const; | 175 std::string toFrameText(int fps, bool hms, |
176 std::string frameDelimiter = ":") const; | |
176 | 177 |
177 /** | 178 /** |
178 * Return a user-readable string to the nearest second, in H:M:S | 179 * Return a user-readable string to the nearest second, in H:M:S |
179 * form. Does not include milliseconds or frames. The result will | 180 * form. Does not include milliseconds or frames. The result will |
180 * be suffixed "s" if it contains only seconds (no hours or | 181 * be suffixed "s" if it contains only seconds (no hours or |