audio_core: Port codec code from Citra for ADPCM decoding.
This commit is contained in:
parent
02fccc0940
commit
f1cb3903ac
5 changed files with 126 additions and 11 deletions
|
@ -4,6 +4,8 @@
|
|||
|
||||
#include <array>
|
||||
#include <vector>
|
||||
|
||||
#include "audio_core/codec.h"
|
||||
#include "common/logging/log.h"
|
||||
#include "core/core.h"
|
||||
#include "core/hle/ipc_helpers.h"
|
||||
|
@ -200,7 +202,7 @@ void AudOutU::OpenAudioOutImpl(Kernel::HLERequestContext& ctx) {
|
|||
rb.Push(RESULT_SUCCESS);
|
||||
rb.Push<u32>(DefaultSampleRate);
|
||||
rb.Push<u32>(params.channel_count);
|
||||
rb.Push<u32>(static_cast<u32>(PcmFormat::Int16));
|
||||
rb.Push<u32>(static_cast<u32>(AudioCore::Codec::PcmFormat::Int16));
|
||||
rb.Push<u32>(static_cast<u32>(AudioState::Stopped));
|
||||
rb.PushIpcInterface<Audio::IAudioOut>(audio_out_interface);
|
||||
}
|
||||
|
|
|
@ -38,16 +38,6 @@ private:
|
|||
|
||||
void ListAudioOutsImpl(Kernel::HLERequestContext& ctx);
|
||||
void OpenAudioOutImpl(Kernel::HLERequestContext& ctx);
|
||||
|
||||
enum class PcmFormat : u32 {
|
||||
Invalid = 0,
|
||||
Int8 = 1,
|
||||
Int16 = 2,
|
||||
Int24 = 3,
|
||||
Int32 = 4,
|
||||
PcmFloat = 5,
|
||||
Adpcm = 6,
|
||||
};
|
||||
};
|
||||
|
||||
} // namespace Service::Audio
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue