void FATRecord::Read(PseudoFile &file) { this->offset = file.ReadLE<uint32_t>(); file.ReadLE<uint32_t>(); // size uint32_t reserved[2]; file.ReadLE(reserved); }
void NDSStdHeader::Read(PseudoFile &file) { file.ReadLE(this->type); this->magic = file.ReadLE<uint32_t>(); file.ReadLE<uint32_t>(); // file size file.ReadLE<uint16_t>(); // structure size file.ReadLE<uint16_t>(); // # of blocks }
void FATSection::Read(PseudoFile &file) { int8_t type[4]; file.ReadLE(type); if (!VerifyHeader(type, "FAT ")) throw std::runtime_error("SDAT FAT Section invalid"); file.ReadLE<uint32_t>(); // size uint32_t count = file.ReadLE<uint32_t>(); this->records.resize(count); for (uint32_t i = 0; i < count; ++i) this->records[i].Read(file); }