diff --git a/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/audio/IAudioStream.hpp b/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/audio/IAudioStream.hpp index 2c922398..ac822e05 100644 --- a/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/audio/IAudioStream.hpp +++ b/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/audio/IAudioStream.hpp @@ -23,6 +23,5 @@ namespace HyperSonicDrivers::audio virtual uint32_t getRate() const = 0; virtual bool endOfData() const = 0; virtual bool isEnded() const { return endOfData(); } - //virtual void forward(const uint32_t ms) = 0; }; } diff --git a/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/audio/streams/PCMStream.hpp b/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/audio/streams/PCMStream.hpp index fe22db6a..905dc6a6 100644 --- a/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/audio/streams/PCMStream.hpp +++ b/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/audio/streams/PCMStream.hpp @@ -19,6 +19,7 @@ namespace HyperSonicDrivers::audio::streams bool endOfData() const override; void forward(const uint32_t bytes) noexcept; + std::shared_ptr getSound() const noexcept; private: std::shared_ptr m_sound; diff --git a/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/drivers/PCMDriver.cpp b/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/drivers/PCMDriver.cpp index 6fb2f13d..811b6922 100644 --- a/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/drivers/PCMDriver.cpp +++ b/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/drivers/PCMDriver.cpp @@ -99,7 +99,7 @@ namespace HyperSonicDrivers::drivers releaseStreams_(); } - void PCMDriver::forward(const uint32_t ms) noexcept + void PCMDriver::forward(const uint32_t ms) const noexcept { for (const auto& [stream, _] : m_PCMStreams_channels) stream->forward(utils::ms_toPos(ms, stream->getSound())); diff --git a/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/drivers/PCMDriver.hpp b/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/drivers/PCMDriver.hpp index 0d4fe1ec..4d6f223a 100644 --- a/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/drivers/PCMDriver.hpp +++ b/sdl2-hyper-sonic-drivers/src/HyperSonicDrivers/drivers/PCMDriver.hpp @@ -34,7 +34,7 @@ namespace HyperSonicDrivers::drivers void stop(const std::shared_ptr& sound, const bool releaseEndedStreams = true); void stop() noexcept; - void forward(const uint32_t ms) noexcept; + void forward(const uint32_t ms) const noexcept; const uint8_t max_streams; private: