aboutsummaryrefslogtreecommitdiff
path: root/sound
diff options
context:
space:
mode:
Diffstat (limited to 'sound')
-rw-r--r--sound/timestamp.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/sound/timestamp.h b/sound/timestamp.h
index 2d4f3db693..a027570469 100644
--- a/sound/timestamp.h
+++ b/sound/timestamp.h
@@ -129,6 +129,17 @@ public:
/** Return the framerate used by this timestamp. */
int getFramerate() const { return _framerate / _framerateFactor; }
+ /**
+ * Determines the time in seconds described by this timestamp,
+ * rounded down.
+ */
+ uint32 secs() const { return _secs; }
+
+ /**
+ * Determines the frames described by this timestamp.
+ */
+ int getNumberOfFrames() const { return _numberOfFrames / _framerateFactor; }
+
protected:
int cmp(const Timestamp &ts) const;