summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibDSP/Transport.h
diff options
context:
space:
mode:
authorkleines Filmröllchen <filmroellchen@serenityos.org>2022-05-11 21:49:41 +0200
committerLinus Groh <mail@linusgroh.de>2022-05-13 00:47:26 +0200
commitbcb331b8620509aca8894e6bc033fbfcb777eec0 (patch)
tree974bfe16a9f3262a288ae472cf2a9e495dee3791 /Userland/Libraries/LibDSP/Transport.h
parent4a6ebb8bebf73ee14aea873396bfc26a388bb762 (diff)
downloadserenity-bcb331b8620509aca8894e6bc033fbfcb777eec0.zip
LibDSP: Improve const correctness
Diffstat (limited to 'Userland/Libraries/LibDSP/Transport.h')
-rw-r--r--Userland/Libraries/LibDSP/Transport.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/Userland/Libraries/LibDSP/Transport.h b/Userland/Libraries/LibDSP/Transport.h
index 45f1b8af61..0acd8d725f 100644
--- a/Userland/Libraries/LibDSP/Transport.h
+++ b/Userland/Libraries/LibDSP/Transport.h
@@ -16,6 +16,7 @@ namespace LibDSP {
class Transport final : public RefCounted<Transport> {
public:
constexpr u32& time() { return m_time; }
+ constexpr u32 time() const { return m_time; }
constexpr u16 beats_per_minute() const { return m_beats_per_minute; }
constexpr double current_second() const { return static_cast<double>(m_time) / m_sample_rate; }
constexpr double samples_per_measure() const { return (1.0 / m_beats_per_minute) * 60.0 * m_sample_rate; }