Added splashpack parser, made renderer a singleton

This commit is contained in:
2025-03-21 17:54:25 +01:00
parent 4b7389da8d
commit 0d46881d7f
8 changed files with 121 additions and 44 deletions

23
src/splashpack.hh Normal file
View File

@@ -0,0 +1,23 @@
#pragma once
#include "EASTL/vector.h"
#include "gameobject.hh"
#include <cstdint>
namespace psxsplash {
struct SPLASHPACKFileHeader {
char magic[2];
uint16_t version;
uint16_t gameObjectCount;
uint16_t textureAtlasCount;
};
struct SPLASHPACKTextureAtlas {
uint32_t polygonsOffset;
uint16_t width, height;
uint16_t x,y;
};
eastl::vector<GameObject> LoadSplashpack(const uint8_t *data);
}; // namespace psxsplash