diff options
author | Zach Hilman <zachhilman@gmail.com> | 2019-09-23 03:44:36 +0200 |
---|---|---|
committer | Zach Hilman <zachhilman@gmail.com> | 2019-09-23 03:44:36 +0200 |
commit | 3895f7e4562a02ee07cac6908787802bddf2c092 (patch) | |
tree | 861410fd65ece538a0d18a3504e91b4f02cb8afa /src/core/file_sys/partition_filesystem.cpp | |
parent | Merge pull request #2901 from DarkLordZach/mainline-title-bar (diff) | |
download | yuzu-3895f7e4562a02ee07cac6908787802bddf2c092.tar yuzu-3895f7e4562a02ee07cac6908787802bddf2c092.tar.gz yuzu-3895f7e4562a02ee07cac6908787802bddf2c092.tar.bz2 yuzu-3895f7e4562a02ee07cac6908787802bddf2c092.tar.lz yuzu-3895f7e4562a02ee07cac6908787802bddf2c092.tar.xz yuzu-3895f7e4562a02ee07cac6908787802bddf2c092.tar.zst yuzu-3895f7e4562a02ee07cac6908787802bddf2c092.zip |
Diffstat (limited to '')
-rw-r--r-- | src/core/file_sys/partition_filesystem.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/core/file_sys/partition_filesystem.cpp b/src/core/file_sys/partition_filesystem.cpp index a5259a593..932409d79 100644 --- a/src/core/file_sys/partition_filesystem.cpp +++ b/src/core/file_sys/partition_filesystem.cpp @@ -65,6 +65,9 @@ PartitionFilesystem::PartitionFilesystem(std::shared_ptr<VfsFile> file) { std::string name( reinterpret_cast<const char*>(&file_data[strtab_offset + entry.strtab_offset])); + offsets[name] = content_offset + entry.offset; + sizes[name] = entry.size; + pfs_files.emplace_back(std::make_shared<OffsetVfsFile>( file, entry.size, content_offset + entry.offset, std::move(name))); } @@ -78,6 +81,14 @@ Loader::ResultStatus PartitionFilesystem::GetStatus() const { return status; } +std::map<std::string, u64> PartitionFilesystem::GetFileOffsets() const { + return offsets; +} + +std::map<std::string, u64> PartitionFilesystem::GetFileSizes() const { + return sizes; +} + std::vector<std::shared_ptr<VfsFile>> PartitionFilesystem::GetFiles() const { return pfs_files; } |