Add pack writing functionality
This commit is contained in:
37
include/pak.h
Normal file
37
include/pak.h
Normal file
@@ -0,0 +1,37 @@
|
||||
#ifndef PAK_H
|
||||
#define PAK_H
|
||||
|
||||
#include "aliases.h"
|
||||
#include <stdbool.h>
|
||||
|
||||
typedef struct {
|
||||
u64 offset;
|
||||
u64 length;
|
||||
char name[];
|
||||
} toc_entry_t;
|
||||
|
||||
typedef struct {
|
||||
u64 count;
|
||||
u64 size;
|
||||
} toc_t;
|
||||
|
||||
typedef struct {
|
||||
u64 major;
|
||||
u64 minor;
|
||||
u64 patch;
|
||||
} pak_ver_t;
|
||||
|
||||
typedef struct {
|
||||
u64 size;
|
||||
u8 data[];
|
||||
} pak_entry_t;
|
||||
|
||||
typedef struct {
|
||||
u64 magic;
|
||||
pak_ver_t version;
|
||||
toc_t toc;
|
||||
} pak_t;
|
||||
|
||||
bool create_asset_pack(const char *dirpath, const char *output);
|
||||
|
||||
#endif // !PAK_H
|
Reference in New Issue
Block a user