summaryrefslogtreecommitdiffstats
path: root/src/audio_core/cubeb_sink.cpp
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2019-02-26 00:25:36 +0100
committerGitHub <noreply@github.com>2019-02-26 00:25:36 +0100
commit1cffd3848b15f86da3ba6b7a371602ecffb8cac2 (patch)
treee39ba2ad2d35a84312dc06e1abc2f1def3c556b1 /src/audio_core/cubeb_sink.cpp
parentMerge pull request #2159 from lioncash/warn (diff)
parentaudio_core/cubeb_sink: Initialize CubebSinkStream's last_frame data member (diff)
downloadyuzu-1cffd3848b15f86da3ba6b7a371602ecffb8cac2.tar
yuzu-1cffd3848b15f86da3ba6b7a371602ecffb8cac2.tar.gz
yuzu-1cffd3848b15f86da3ba6b7a371602ecffb8cac2.tar.bz2
yuzu-1cffd3848b15f86da3ba6b7a371602ecffb8cac2.tar.lz
yuzu-1cffd3848b15f86da3ba6b7a371602ecffb8cac2.tar.xz
yuzu-1cffd3848b15f86da3ba6b7a371602ecffb8cac2.tar.zst
yuzu-1cffd3848b15f86da3ba6b7a371602ecffb8cac2.zip
Diffstat (limited to 'src/audio_core/cubeb_sink.cpp')
-rw-r--r--src/audio_core/cubeb_sink.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/audio_core/cubeb_sink.cpp b/src/audio_core/cubeb_sink.cpp
index 097328901..dc45dedd3 100644
--- a/src/audio_core/cubeb_sink.cpp
+++ b/src/audio_core/cubeb_sink.cpp
@@ -46,7 +46,7 @@ public:
}
}
- ~CubebSinkStream() {
+ ~CubebSinkStream() override {
if (!ctx) {
return;
}
@@ -75,11 +75,11 @@ public:
queue.Push(samples);
}
- std::size_t SamplesInQueue(u32 num_channels) const override {
+ std::size_t SamplesInQueue(u32 channel_count) const override {
if (!ctx)
return 0;
- return queue.Size() / num_channels;
+ return queue.Size() / channel_count;
}
void Flush() override {
@@ -98,7 +98,7 @@ private:
u32 num_channels{};
Common::RingBuffer<s16, 0x10000> queue;
- std::array<s16, 2> last_frame;
+ std::array<s16, 2> last_frame{};
std::atomic<bool> should_flush{};
TimeStretcher time_stretch;