aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/Chrono.hxx16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/Chrono.hxx b/src/Chrono.hxx
index db7605726..e72975ea8 100644
--- a/src/Chrono.hxx
+++ b/src/Chrono.hxx
@@ -58,6 +58,14 @@ public:
return SongTime(ms);
}
+ constexpr rep ToS() const {
+ return count() / rep(1000);
+ }
+
+ constexpr rep RoundS() const {
+ return (count() + 500) / rep(1000);
+ }
+
constexpr rep ToMS() const {
return count();
}
@@ -129,6 +137,14 @@ public:
return SignedSongTime(ms);
}
+ constexpr rep ToS() const {
+ return count() / rep(1000);
+ }
+
+ constexpr rep RoundS() const {
+ return (count() + 500) / rep(1000);
+ }
+
constexpr rep ToMS() const {
return count();
}