EXI: Allow reading memory card data directly in CEXIMemoryCard.

This commit is contained in:
Admiral H. Curtiss 2020-08-11 23:49:01 +02:00
parent 1ba8541da9
commit 5b8c07a190
No known key found for this signature in database
GPG Key ID: F051B4C4044F33FB
2 changed files with 10 additions and 0 deletions

View File

@ -172,6 +172,14 @@ CEXIMemoryCard::GetGCIFolderPath(Slot card_slot, AllowMovieFolder allow_movie_fo
return {Config::GetGCIFolderPath(card_slot, region), true};
}
s32 CEXIMemoryCard::ReadFromMemcard(u32 memcard_offset, s32 length, u8* dest_address) const
{
if (!m_memory_card)
return 0;
return m_memory_card->Read(memcard_offset, length, dest_address);
}
void CEXIMemoryCard::SetupGciFolder(const Memcard::HeaderData& header_data)
{
const std::string& game_id = SConfig::GetInstance().GetGameID();

View File

@ -64,6 +64,8 @@ public:
static std::pair<std::string /* path */, bool /* migrate */>
GetGCIFolderPath(Slot card_slot, AllowMovieFolder allow_movie_folder, Movie::MovieManager& movie);
s32 ReadFromMemcard(u32 memcard_offset, s32 length, u8* dest_address) const;
private:
void SetupGciFolder(const Memcard::HeaderData& header_data);
void SetupRawMemcard(u16 size_mb);