diff options
author | MerryMage <MerryMage@users.noreply.github.com> | 2016-02-21 14:13:52 +0100 |
---|---|---|
committer | MerryMage <MerryMage@users.noreply.github.com> | 2016-02-21 14:13:52 +0100 |
commit | 8b00954ec79fad71691ad2d4c82d5c1c60e21b0c (patch) | |
tree | 443d275fd39c58928e68ef22ce3fe0fa56c73642 /src/audio_core/hle/pipe.h | |
parent | Merge pull request #1406 from MerryMage/bitfield2 (diff) | |
download | yuzu-8b00954ec79fad71691ad2d4c82d5c1c60e21b0c.tar yuzu-8b00954ec79fad71691ad2d4c82d5c1c60e21b0c.tar.gz yuzu-8b00954ec79fad71691ad2d4c82d5c1c60e21b0c.tar.bz2 yuzu-8b00954ec79fad71691ad2d4c82d5c1c60e21b0c.tar.lz yuzu-8b00954ec79fad71691ad2d4c82d5c1c60e21b0c.tar.xz yuzu-8b00954ec79fad71691ad2d4c82d5c1c60e21b0c.tar.zst yuzu-8b00954ec79fad71691ad2d4c82d5c1c60e21b0c.zip |
Diffstat (limited to '')
-rw-r--r-- | src/audio_core/hle/pipe.h | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/src/audio_core/hle/pipe.h b/src/audio_core/hle/pipe.h new file mode 100644 index 000000000..ff6536950 --- /dev/null +++ b/src/audio_core/hle/pipe.h @@ -0,0 +1,38 @@ +// Copyright 2016 Citra Emulator Project +// Licensed under GPLv2 or any later version +// Refer to the license.txt file included. + +#pragma once + +#include <vector> + +#include "common/common_types.h" + +namespace DSP { +namespace HLE { + +/// Reset the pipes by setting pipe positions back to the beginning. +void ResetPipes(); + +/** + * Read a DSP pipe. + * Pipe IDs: + * pipe_number = 0: Debug + * pipe_number = 1: P-DMA + * pipe_number = 2: Audio + * pipe_number = 3: Binary + * @param pipe_number The Pipe ID + * @param length How much data to request. + * @return The data read from the pipe. The size of this vector can be less than the length requested. + */ +std::vector<u8> PipeRead(u32 pipe_number, u32 length); + +/** + * Write to a DSP pipe. + * @param pipe_number The Pipe ID + * @param buffer The data to write to the pipe. + */ +void PipeWrite(u32 pipe_number, const std::vector<u8>& buffer); + +} // namespace HLE +} // namespace DSP |