summaryrefslogtreecommitdiffhomepage
path: root/opentrack-compat/timer.hpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2016-05-16 12:33:44 +0200
committerStanislaw Halik <sthalik@misaki.pl>2016-05-16 12:33:44 +0200
commit3e4c6f2977d8a5515229c79d969392de3cafbb4b (patch)
treea11ea66604b2f6f0d8d4513e3fff714abd0dd6e8 /opentrack-compat/timer.hpp
parentb03373863a84eeb3437950d55384db8aece7fb15 (diff)
compat/timer: add elapsed_seconds method
Diffstat (limited to 'opentrack-compat/timer.hpp')
-rw-r--r--opentrack-compat/timer.hpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/opentrack-compat/timer.hpp b/opentrack-compat/timer.hpp
index f0741295..0bcb88a6 100644
--- a/opentrack-compat/timer.hpp
+++ b/opentrack-compat/timer.hpp
@@ -71,4 +71,8 @@ public:
long elapsed_ms() const {
return elapsed() / 1000000L;
}
+ double elapsed_seconds() const
+ {
+ return elapsed() * 1e-9;
+ }
};