mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-08-01 13:48:56 +00:00
Don't read from disk when checking volume type
Should be faster than relying on the OS to cache the magic words. Also gets rid of the odd recursive call in VolumeDirectory.
This commit is contained in:
parent
11a36ca8e2
commit
ace060748b
19 changed files with 61 additions and 56 deletions
|
@ -120,15 +120,6 @@ IVolume* CreateVolumeFromDirectory(const std::string& _rDirectory, bool _bIsWii,
|
|||
return nullptr;
|
||||
}
|
||||
|
||||
bool IsVolumeWiiDisc(const IVolume *_rVolume)
|
||||
{
|
||||
u32 MagicWord = 0;
|
||||
_rVolume->Read(0x18, 4, (u8*)&MagicWord, false);
|
||||
|
||||
return (Common::swap32(MagicWord) == 0x5D1C9EA3);
|
||||
//GameCube 0xc2339f3d
|
||||
}
|
||||
|
||||
bool IsVolumeWadFile(const IVolume *_rVolume)
|
||||
{
|
||||
u32 MagicWord = 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue