diff options
| -rw-r--r-- | src/audio_core/codec.cpp | 4 | ||||
| -rw-r--r-- | src/audio_core/cubeb_sink.cpp | 8 | ||||
| -rw-r--r-- | src/video_core/shader/track.cpp | 10 |
3 files changed, 11 insertions, 11 deletions
diff --git a/src/audio_core/codec.cpp b/src/audio_core/codec.cpp index 454de798b..c5a0d98ce 100644 --- a/src/audio_core/codec.cpp +++ b/src/audio_core/codec.cpp | |||
| @@ -68,8 +68,8 @@ std::vector<s16> DecodeADPCM(const u8* const data, std::size_t size, const ADPCM | |||
| 68 | } | 68 | } |
| 69 | } | 69 | } |
| 70 | 70 | ||
| 71 | state.yn1 = yn1; | 71 | state.yn1 = static_cast<s16>(yn1); |
| 72 | state.yn2 = yn2; | 72 | state.yn2 = static_cast<s16>(yn2); |
| 73 | 73 | ||
| 74 | return ret; | 74 | return ret; |
| 75 | } | 75 | } |
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: | |||
| 46 | } | 46 | } |
| 47 | } | 47 | } |
| 48 | 48 | ||
| 49 | ~CubebSinkStream() { | 49 | ~CubebSinkStream() override { |
| 50 | if (!ctx) { | 50 | if (!ctx) { |
| 51 | return; | 51 | return; |
| 52 | } | 52 | } |
| @@ -75,11 +75,11 @@ public: | |||
| 75 | queue.Push(samples); | 75 | queue.Push(samples); |
| 76 | } | 76 | } |
| 77 | 77 | ||
| 78 | std::size_t SamplesInQueue(u32 num_channels) const override { | 78 | std::size_t SamplesInQueue(u32 channel_count) const override { |
| 79 | if (!ctx) | 79 | if (!ctx) |
| 80 | return 0; | 80 | return 0; |
| 81 | 81 | ||
| 82 | return queue.Size() / num_channels; | 82 | return queue.Size() / channel_count; |
| 83 | } | 83 | } |
| 84 | 84 | ||
| 85 | void Flush() override { | 85 | void Flush() override { |
| @@ -98,7 +98,7 @@ private: | |||
| 98 | u32 num_channels{}; | 98 | u32 num_channels{}; |
| 99 | 99 | ||
| 100 | Common::RingBuffer<s16, 0x10000> queue; | 100 | Common::RingBuffer<s16, 0x10000> queue; |
| 101 | std::array<s16, 2> last_frame; | 101 | std::array<s16, 2> last_frame{}; |
| 102 | std::atomic<bool> should_flush{}; | 102 | std::atomic<bool> should_flush{}; |
| 103 | TimeStretcher time_stretch; | 103 | TimeStretcher time_stretch; |
| 104 | 104 | ||
diff --git a/src/video_core/shader/track.cpp b/src/video_core/shader/track.cpp index be4635342..33b071747 100644 --- a/src/video_core/shader/track.cpp +++ b/src/video_core/shader/track.cpp | |||
| @@ -20,9 +20,9 @@ std::pair<Node, s64> FindOperation(const NodeBlock& code, s64 cursor, | |||
| 20 | return {node, cursor}; | 20 | return {node, cursor}; |
| 21 | } | 21 | } |
| 22 | if (const auto conditional = std::get_if<ConditionalNode>(node)) { | 22 | if (const auto conditional = std::get_if<ConditionalNode>(node)) { |
| 23 | const auto& code = conditional->GetCode(); | 23 | const auto& conditional_code = conditional->GetCode(); |
| 24 | const auto [found, internal_cursor] = | 24 | const auto [found, internal_cursor] = FindOperation( |
| 25 | FindOperation(code, static_cast<s64>(code.size() - 1), operation_code); | 25 | conditional_code, static_cast<s64>(conditional_code.size() - 1), operation_code); |
| 26 | if (found) | 26 | if (found) |
| 27 | return {found, cursor}; | 27 | return {found, cursor}; |
| 28 | } | 28 | } |
| @@ -58,8 +58,8 @@ Node ShaderIR::TrackCbuf(Node tracked, const NodeBlock& code, s64 cursor) { | |||
| 58 | return nullptr; | 58 | return nullptr; |
| 59 | } | 59 | } |
| 60 | if (const auto conditional = std::get_if<ConditionalNode>(tracked)) { | 60 | if (const auto conditional = std::get_if<ConditionalNode>(tracked)) { |
| 61 | const auto& code = conditional->GetCode(); | 61 | const auto& conditional_code = conditional->GetCode(); |
| 62 | return TrackCbuf(tracked, code, static_cast<s64>(code.size())); | 62 | return TrackCbuf(tracked, conditional_code, static_cast<s64>(conditional_code.size())); |
| 63 | } | 63 | } |
| 64 | return nullptr; | 64 | return nullptr; |
| 65 | } | 65 | } |