diff options
author | bunnei <bunneidev@gmail.com> | 2023-06-23 06:53:07 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-06-23 06:53:07 +0200 |
commit | 2fc5dedf6996d4a5c93ddf1ccd67a6963e4827e8 (patch) | |
tree | d82f2cf4f7a5e9773616846c095a941b282a84f6 /src/audio_core/device/device_session.h | |
parent | Merge pull request #10806 from liamwhite/worst-fs-implementation-ever (diff) | |
parent | Remove memory allocations in some hot paths (diff) | |
download | yuzu-2fc5dedf6996d4a5c93ddf1ccd67a6963e4827e8.tar yuzu-2fc5dedf6996d4a5c93ddf1ccd67a6963e4827e8.tar.gz yuzu-2fc5dedf6996d4a5c93ddf1ccd67a6963e4827e8.tar.bz2 yuzu-2fc5dedf6996d4a5c93ddf1ccd67a6963e4827e8.tar.lz yuzu-2fc5dedf6996d4a5c93ddf1ccd67a6963e4827e8.tar.xz yuzu-2fc5dedf6996d4a5c93ddf1ccd67a6963e4827e8.tar.zst yuzu-2fc5dedf6996d4a5c93ddf1ccd67a6963e4827e8.zip |
Diffstat (limited to 'src/audio_core/device/device_session.h')
-rw-r--r-- | src/audio_core/device/device_session.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/audio_core/device/device_session.h b/src/audio_core/device/device_session.h index 75f766c68..7d52f362d 100644 --- a/src/audio_core/device/device_session.h +++ b/src/audio_core/device/device_session.h @@ -10,6 +10,7 @@ #include "audio_core/common/common.h" #include "audio_core/sink/sink.h" +#include "common/scratch_buffer.h" #include "core/hle/service/audio/errors.h" namespace Core { @@ -62,7 +63,7 @@ public: * * @param buffers - The buffers to play. */ - void AppendBuffers(std::span<const AudioBuffer> buffers) const; + void AppendBuffers(std::span<const AudioBuffer> buffers); /** * (Audio In only) Pop samples from the backend, and write them back to this buffer's address. @@ -146,8 +147,8 @@ private: std::shared_ptr<Core::Timing::EventType> thread_event; /// Is this session initialised? bool initialized{}; - /// Buffer queue - std::vector<AudioBuffer> buffer_queue{}; + /// Temporary sample buffer + Common::ScratchBuffer<s16> tmp_samples{}; }; } // namespace AudioCore |