[nx] misc

This commit is contained in:
jakcron 2018-04-21 17:38:26 +08:00
parent 17c16cfa7a
commit e9d24e4297
2 changed files with 37 additions and 1 deletions

View file

@ -17,7 +17,8 @@ namespace nx
{
char signature[4];
le_uint32_t file_num;
le_uint64_t name_table_size;
le_uint32_t name_table_size;
byte_t padding[4];
};
struct sPfsFile

View file

@ -0,0 +1,35 @@
#pragma once
#include <string>
#include <fnd/types.h>
#include <crypto/aes.h>
#include <crypto/sha.h>
#include <fnd/ISerialiseableBinary.h>
namespace nx
{
namespace romfs
{
enum HeaderSectionIndex
{
DIR_HASHMAP_TABLE,
DIR_NODE_TABLE,
FILE_HASHMAP_TABLE,
FILE_NODE_TABLE,
SECTION_NUM
};
}
#pragma pack(push,1)
struct sRomfsHeader
{
le_uint64_t header_size;
struct sSection
{
le_uint64_t offset;
le_uint64_t size;
} sections[romfs::SECTION_NUM];
le_uint64_t data_offset;
};
#pragma pack(pop)
}