Add SPU memory allocation

This commit is contained in:
Jaby
2024-08-07 23:01:43 -05:00
committed by Jaby
parent 2b4bd6fd2e
commit 1fc096485d
7 changed files with 181 additions and 4 deletions

View File

@@ -5,7 +5,6 @@
#ifdef __SUPPORT_VAG__
namespace JabyEngine {
namespace FileProcessor {
#pragma pack(push, 1)
struct VAGHeader {
char id[4];
uint32_t version;
@@ -27,7 +26,6 @@ namespace JabyEngine {
return read_be(this->sample_frequency);
}
};
#pragma pack(pop)
struct VAGState {
static constexpr VAGState create() {
@@ -39,7 +37,8 @@ namespace JabyEngine {
if(config.data_bytes >= sizeof(VAGHeader)) {
const auto& header = *reinterpret_cast<const VAGHeader*>(config.data_adr);
printf("VAG-ID: %s\nName: %s\nSample size: %i\nSample rate: %i\n", header.id, header.name, header.get_sample_size(), header.get_sample_frequency());
//printf("VAG-ID: %s\nName: %s\nSample size: %i\nSample rate: %i\n", header.id, header.name, header.get_sample_size(), header.get_sample_frequency());
// TODO: Allocate SPU memory
return Progress::Error;
}