summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Marcec <dmarcecguzman@gmail.com>2018-10-07 05:25:39 +0200
committerDavid Marcec <dmarcecguzman@gmail.com>2018-10-07 05:25:39 +0200
commitceef334c1cc2c55def468a1f83474ba8d4a3884d (patch)
treed95bb7d56011e567d423a9ab14c1011091379744
parentFixed missing return (diff)
downloadyuzu-ceef334c1cc2c55def468a1f83474ba8d4a3884d.tar
yuzu-ceef334c1cc2c55def468a1f83474ba8d4a3884d.tar.gz
yuzu-ceef334c1cc2c55def468a1f83474ba8d4a3884d.tar.bz2
yuzu-ceef334c1cc2c55def468a1f83474ba8d4a3884d.tar.lz
yuzu-ceef334c1cc2c55def468a1f83474ba8d4a3884d.tar.xz
yuzu-ceef334c1cc2c55def468a1f83474ba8d4a3884d.tar.zst
yuzu-ceef334c1cc2c55def468a1f83474ba8d4a3884d.zip
-rw-r--r--src/audio_core/audio_renderer.cpp11
-rw-r--r--src/audio_core/audio_renderer.h2
2 files changed, 7 insertions, 6 deletions
diff --git a/src/audio_core/audio_renderer.cpp b/src/audio_core/audio_renderer.cpp
index 5d2feb1b9..23e5d3f10 100644
--- a/src/audio_core/audio_renderer.cpp
+++ b/src/audio_core/audio_renderer.cpp
@@ -30,7 +30,7 @@ public:
return info;
}
- VoiceInfo& Info() {
+ VoiceInfo& GetInfo() {
return info;
}
@@ -61,7 +61,7 @@ public:
return info;
}
- EffectInStatus& Info() {
+ EffectInStatus& GetInfo() {
return info;
}
@@ -120,7 +120,7 @@ std::vector<u8> AudioRenderer::UpdateAudioRenderer(const std::vector<u8>& input_
std::size_t voice_offset{sizeof(UpdateDataHeader) + config.behavior_size +
config.memory_pools_size + config.voice_resource_size};
for (auto& voice : voices) {
- std::memcpy(&voice.Info(), input_params.data() + voice_offset, sizeof(VoiceInfo));
+ std::memcpy(&voice.GetInfo(), input_params.data() + voice_offset, sizeof(VoiceInfo));
voice_offset += sizeof(VoiceInfo);
}
@@ -128,7 +128,7 @@ std::vector<u8> AudioRenderer::UpdateAudioRenderer(const std::vector<u8>& input_
config.memory_pools_size + config.voice_resource_size +
config.voices_size};
for (auto& effect : effects) {
- std::memcpy(&effect.Info(), input_params.data() + effect_offset, sizeof(EffectInStatus));
+ std::memcpy(&effect.GetInfo(), input_params.data() + effect_offset, sizeof(EffectInStatus));
effect_offset += sizeof(EffectInStatus);
}
@@ -285,7 +285,8 @@ void AudioRenderer::VoiceState::RefreshBuffer() {
break;
}
- samples = Interpolate(interp_state, std::move(samples), Info().sample_rate, STREAM_SAMPLE_RATE);
+ samples =
+ Interpolate(interp_state, std::move(samples), GetInfo().sample_rate, STREAM_SAMPLE_RATE);
is_refresh_pending = false;
}
diff --git a/src/audio_core/audio_renderer.h b/src/audio_core/audio_renderer.h
index a2caeb118..4662c8722 100644
--- a/src/audio_core/audio_renderer.h
+++ b/src/audio_core/audio_renderer.h
@@ -220,8 +220,8 @@ public:
Stream::State GetStreamState() const;
private:
- class VoiceState;
class EffectState;
+ class VoiceState;
AudioRendererParameter worker_params;
Kernel::SharedPtr<Kernel::Event> buffer_event;