diff options
Diffstat (limited to 'src/audio_core/hle/pipe.h')
| -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 @@ | |||
| 1 | // Copyright 2016 Citra Emulator Project | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | #include <vector> | ||
| 8 | |||
| 9 | #include "common/common_types.h" | ||
| 10 | |||
| 11 | namespace DSP { | ||
| 12 | namespace HLE { | ||
| 13 | |||
| 14 | /// Reset the pipes by setting pipe positions back to the beginning. | ||
| 15 | void ResetPipes(); | ||
| 16 | |||
| 17 | /** | ||
| 18 | * Read a DSP pipe. | ||
| 19 | * Pipe IDs: | ||
| 20 | * pipe_number = 0: Debug | ||
| 21 | * pipe_number = 1: P-DMA | ||
| 22 | * pipe_number = 2: Audio | ||
| 23 | * pipe_number = 3: Binary | ||
| 24 | * @param pipe_number The Pipe ID | ||
| 25 | * @param length How much data to request. | ||
| 26 | * @return The data read from the pipe. The size of this vector can be less than the length requested. | ||
| 27 | */ | ||
| 28 | std::vector<u8> PipeRead(u32 pipe_number, u32 length); | ||
| 29 | |||
| 30 | /** | ||
| 31 | * Write to a DSP pipe. | ||
| 32 | * @param pipe_number The Pipe ID | ||
| 33 | * @param buffer The data to write to the pipe. | ||
| 34 | */ | ||
| 35 | void PipeWrite(u32 pipe_number, const std::vector<u8>& buffer); | ||
| 36 | |||
| 37 | } // namespace HLE | ||
| 38 | } // namespace DSP | ||