diff options
author | german77 <juangerman-13@hotmail.com> | 2022-06-26 05:44:19 +0200 |
---|---|---|
committer | german77 <juangerman-13@hotmail.com> | 2022-06-27 03:21:37 +0200 |
commit | a7d9be13840acd65d0d684666390758ede72c826 (patch) | |
tree | 37485f63b09576444173d6a765abe0bb95dd45db /src/audio_core | |
parent | Merge pull request #8475 from liamwhite/x18 (diff) | |
download | yuzu-a7d9be13840acd65d0d684666390758ede72c826.tar yuzu-a7d9be13840acd65d0d684666390758ede72c826.tar.gz yuzu-a7d9be13840acd65d0d684666390758ede72c826.tar.bz2 yuzu-a7d9be13840acd65d0d684666390758ede72c826.tar.lz yuzu-a7d9be13840acd65d0d684666390758ede72c826.tar.xz yuzu-a7d9be13840acd65d0d684666390758ede72c826.tar.zst yuzu-a7d9be13840acd65d0d684666390758ede72c826.zip |
Diffstat (limited to 'src/audio_core')
-rw-r--r-- | src/audio_core/audio_renderer.cpp | 8 | ||||
-rw-r--r-- | src/audio_core/audio_renderer.h | 8 | ||||
-rw-r--r-- | src/audio_core/common.h | 4 | ||||
-rw-r--r-- | src/audio_core/info_updater.cpp | 5 | ||||
-rw-r--r-- | src/audio_core/info_updater.h | 4 |
5 files changed, 14 insertions, 15 deletions
diff --git a/src/audio_core/audio_renderer.cpp b/src/audio_core/audio_renderer.cpp index e40ab16d2..2ee0a96ed 100644 --- a/src/audio_core/audio_renderer.cpp +++ b/src/audio_core/audio_renderer.cpp @@ -98,13 +98,13 @@ AudioRenderer::AudioRenderer(Core::Timing::CoreTiming& core_timing_, Core::Memor AudioRenderer::~AudioRenderer() = default; -ResultCode AudioRenderer::Start() { +Result AudioRenderer::Start() { audio_out->StartStream(stream); ReleaseAndQueueBuffers(); return ResultSuccess; } -ResultCode AudioRenderer::Stop() { +Result AudioRenderer::Stop() { audio_out->StopStream(stream); return ResultSuccess; } @@ -125,8 +125,8 @@ Stream::State AudioRenderer::GetStreamState() const { return stream->GetState(); } -ResultCode AudioRenderer::UpdateAudioRenderer(const std::vector<u8>& input_params, - std::vector<u8>& output_params) { +Result AudioRenderer::UpdateAudioRenderer(const std::vector<u8>& input_params, + std::vector<u8>& output_params) { std::scoped_lock lock{mutex}; InfoUpdater info_updater{input_params, output_params, behavior_info}; diff --git a/src/audio_core/audio_renderer.h b/src/audio_core/audio_renderer.h index 1f9f55ae2..a67ffd592 100644 --- a/src/audio_core/audio_renderer.h +++ b/src/audio_core/audio_renderer.h @@ -43,10 +43,10 @@ public: Stream::ReleaseCallback&& release_callback, std::size_t instance_number); ~AudioRenderer(); - [[nodiscard]] ResultCode UpdateAudioRenderer(const std::vector<u8>& input_params, - std::vector<u8>& output_params); - [[nodiscard]] ResultCode Start(); - [[nodiscard]] ResultCode Stop(); + [[nodiscard]] Result UpdateAudioRenderer(const std::vector<u8>& input_params, + std::vector<u8>& output_params); + [[nodiscard]] Result Start(); + [[nodiscard]] Result Stop(); void QueueMixedBuffer(Buffer::Tag tag); void ReleaseAndQueueBuffers(); [[nodiscard]] u32 GetSampleRate() const; diff --git a/src/audio_core/common.h b/src/audio_core/common.h index 46ef83113..056a0ac70 100644 --- a/src/audio_core/common.h +++ b/src/audio_core/common.h @@ -10,8 +10,8 @@ namespace AudioCommon { namespace Audren { -constexpr ResultCode ERR_INVALID_PARAMETERS{ErrorModule::Audio, 41}; -constexpr ResultCode ERR_SPLITTER_SORT_FAILED{ErrorModule::Audio, 43}; +constexpr Result ERR_INVALID_PARAMETERS{ErrorModule::Audio, 41}; +constexpr Result ERR_SPLITTER_SORT_FAILED{ErrorModule::Audio, 43}; } // namespace Audren constexpr u8 BASE_REVISION = '0'; diff --git a/src/audio_core/info_updater.cpp b/src/audio_core/info_updater.cpp index 313a2eb6d..0065e6e53 100644 --- a/src/audio_core/info_updater.cpp +++ b/src/audio_core/info_updater.cpp @@ -285,9 +285,8 @@ bool InfoUpdater::UpdateSplitterInfo(SplitterContext& splitter_context) { return true; } -ResultCode InfoUpdater::UpdateMixes(MixContext& mix_context, std::size_t mix_buffer_count, - SplitterContext& splitter_context, - EffectContext& effect_context) { +Result InfoUpdater::UpdateMixes(MixContext& mix_context, std::size_t mix_buffer_count, + SplitterContext& splitter_context, EffectContext& effect_context) { std::vector<MixInfo::InParams> mix_in_params; if (!behavior_info.IsMixInParameterDirtyOnlyUpdateSupported()) { diff --git a/src/audio_core/info_updater.h b/src/audio_core/info_updater.h index 6aab5beaf..17e66b036 100644 --- a/src/audio_core/info_updater.h +++ b/src/audio_core/info_updater.h @@ -32,8 +32,8 @@ public: VAddr audio_codec_dsp_addr); bool UpdateEffects(EffectContext& effect_context, bool is_active); bool UpdateSplitterInfo(SplitterContext& splitter_context); - ResultCode UpdateMixes(MixContext& mix_context, std::size_t mix_buffer_count, - SplitterContext& splitter_context, EffectContext& effect_context); + Result UpdateMixes(MixContext& mix_context, std::size_t mix_buffer_count, + SplitterContext& splitter_context, EffectContext& effect_context); bool UpdateSinks(SinkContext& sink_context); bool UpdatePerformanceBuffer(); bool UpdateErrorInfo(BehaviorInfo& in_behavior_info); |