2017-12-20 19:44:32 +01:00
|
|
|
// Copyright 2017 Citra Emulator Project
|
|
|
|
// Licensed under GPLv2 or any later version
|
|
|
|
// Refer to the license.txt file included.
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <array>
|
|
|
|
#include <memory>
|
|
|
|
#include <vector>
|
|
|
|
#include "audio_core/audio_types.h"
|
|
|
|
#include "audio_core/dsp_interface.h"
|
|
|
|
#include "common/common_types.h"
|
2018-07-24 21:54:33 +02:00
|
|
|
#include "core/hle/service/dsp/dsp_dsp.h"
|
2017-12-20 19:44:32 +01:00
|
|
|
#include "core/memory.h"
|
|
|
|
|
|
|
|
namespace AudioCore {
|
|
|
|
|
|
|
|
class DspHle final : public DspInterface {
|
|
|
|
public:
|
|
|
|
DspHle();
|
|
|
|
~DspHle();
|
|
|
|
|
|
|
|
DspState GetDspState() const override;
|
|
|
|
|
|
|
|
std::vector<u8> PipeRead(DspPipe pipe_number, u32 length) override;
|
|
|
|
size_t GetPipeReadableSize(DspPipe pipe_number) const override;
|
|
|
|
void PipeWrite(DspPipe pipe_number, const std::vector<u8>& buffer) override;
|
|
|
|
|
|
|
|
std::array<u8, Memory::DSP_RAM_SIZE>& GetDspMemory() override;
|
|
|
|
|
2018-07-24 21:54:33 +02:00
|
|
|
void SetDspToInterrupt(std::shared_ptr<Service::DSP::DSP_DSP> dsp) override;
|
|
|
|
|
2017-12-20 19:44:32 +01:00
|
|
|
private:
|
|
|
|
struct Impl;
|
|
|
|
friend struct Impl;
|
|
|
|
std::unique_ptr<Impl> impl;
|
|
|
|
};
|
|
|
|
|
|
|
|
} // namespace AudioCore
|