2018-12-06 04:14:54 -08:00
|
|
|
// Copyright 2018 Citra Emulator Project
|
|
|
|
// Licensed under GPLv2 or any later version
|
|
|
|
// Refer to the license.txt file included.
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include "audio_core/dsp_interface.h"
|
|
|
|
|
|
|
|
namespace AudioCore {
|
|
|
|
|
|
|
|
class DspLle final : public DspInterface {
|
|
|
|
public:
|
2018-12-19 16:45:22 -08:00
|
|
|
explicit DspLle(Memory::MemorySystem& memory, bool multithread);
|
2018-12-08 17:36:04 -08:00
|
|
|
~DspLle() override;
|
2018-12-06 04:14:54 -08:00
|
|
|
|
2018-12-06 04:22:31 -08:00
|
|
|
u16 RecvData(u32 register_number) override;
|
2018-12-06 04:30:10 -08:00
|
|
|
bool RecvDataIsReady(u32 register_number) const override;
|
2018-12-06 04:35:07 -08:00
|
|
|
void SetSemaphore(u16 semaphore_value) override;
|
2018-12-06 04:49:07 -08:00
|
|
|
std::vector<u8> PipeRead(DspPipe pipe_number, u32 length) override;
|
|
|
|
std::size_t GetPipeReadableSize(DspPipe pipe_number) const override;
|
2018-12-06 04:42:07 -08:00
|
|
|
void PipeWrite(DspPipe pipe_number, const std::vector<u8>& buffer) override;
|
2018-12-06 04:22:31 -08:00
|
|
|
|
2018-12-06 05:10:00 -08:00
|
|
|
std::array<u8, Memory::DSP_RAM_SIZE>& GetDspMemory() override;
|
|
|
|
|
|
|
|
void SetServiceToInterrupt(std::weak_ptr<Service::DSP::DSP_DSP> dsp) override;
|
|
|
|
|
2018-12-06 06:09:14 -08:00
|
|
|
void LoadComponent(const std::vector<u8>& buffer) override;
|
2018-12-06 06:50:55 -08:00
|
|
|
void UnloadComponent() override;
|
2018-12-06 06:09:14 -08:00
|
|
|
|
2018-12-06 04:14:54 -08:00
|
|
|
private:
|
|
|
|
struct Impl;
|
|
|
|
std::unique_ptr<Impl> impl;
|
|
|
|
};
|
|
|
|
|
|
|
|
} // namespace AudioCore
|