summaryrefslogtreecommitdiff
path: root/src/audio_core/hle/pipe.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/audio_core/hle/pipe.h')
-rw-r--r--src/audio_core/hle/pipe.h19
1 files changed, 6 insertions, 13 deletions
diff --git a/src/audio_core/hle/pipe.h b/src/audio_core/hle/pipe.h
index b714c0496..73b857a90 100644
--- a/src/audio_core/hle/pipe.h
+++ b/src/audio_core/hle/pipe.h
@@ -15,20 +15,17 @@ namespace HLE {
15/// Reset the pipes by setting pipe positions back to the beginning. 15/// Reset the pipes by setting pipe positions back to the beginning.
16void ResetPipes(); 16void ResetPipes();
17 17
18enum class DspPipe { 18enum class DspPipe { Debug = 0, Dma = 1, Audio = 2, Binary = 3 };
19 Debug = 0,
20 Dma = 1,
21 Audio = 2,
22 Binary = 3
23};
24constexpr size_t NUM_DSP_PIPE = 8; 19constexpr size_t NUM_DSP_PIPE = 8;
25 20
26/** 21/**
27 * Reads `length` bytes from the DSP pipe identified with `pipe_number`. 22 * Reads `length` bytes from the DSP pipe identified with `pipe_number`.
28 * @note Can read up to the maximum value of a u16 in bytes (65,535). 23 * @note Can read up to the maximum value of a u16 in bytes (65,535).
29 * @note IF an error is encoutered with either an invalid `pipe_number` or `length` value, an empty vector will be returned. 24 * @note IF an error is encoutered with either an invalid `pipe_number` or `length` value, an empty
25 * vector will be returned.
30 * @note IF `length` is set to 0, an empty vector will be returned. 26 * @note IF `length` is set to 0, an empty vector will be returned.
31 * @note IF `length` is greater than the amount of data available, this function will only read the available amount. 27 * @note IF `length` is greater than the amount of data available, this function will only read the
28 * available amount.
32 * @param pipe_number a `DspPipe` 29 * @param pipe_number a `DspPipe`
33 * @param length the number of bytes to read. The max is 65,535 (max of u16). 30 * @param length the number of bytes to read. The max is 65,535 (max of u16).
34 * @returns a vector of bytes from the specified pipe. On error, will be empty. 31 * @returns a vector of bytes from the specified pipe. On error, will be empty.
@@ -49,11 +46,7 @@ size_t GetPipeReadableSize(DspPipe pipe_number);
49 */ 46 */
50void PipeWrite(DspPipe pipe_number, const std::vector<u8>& buffer); 47void PipeWrite(DspPipe pipe_number, const std::vector<u8>& buffer);
51 48
52enum class DspState { 49enum class DspState { Off, On, Sleeping };
53 Off,
54 On,
55 Sleeping
56};
57/// Get the state of the DSP 50/// Get the state of the DSP
58DspState GetDspState(); 51DspState GetDspState();
59 52