mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-13 06:20:26 +02:00
Open directory as disc image
This commit is contained in:
1 parent
c9279a951b
commit
8955fedf44
14 files changed
+214
-15
No files matched your search
+19
-5
@@ -27,6 +27,7 @@
|
||||
#include "MIPS/MIPSAnalyst.h"
|
||||
#include "MIPS/MIPSCodeUtils.h"
|
||||
|
||||
#include "file/file_util.h"
|
||||
#include "StringUtils.h"
|
||||
|
||||
#include "Host.h"
|
||||
@@ -44,11 +45,24 @@
|
||||
// to determine if the emulator should enable extra memory and
|
||||
// double-sized texture coordinates.
|
||||
void InitMemoryForGameISO(std::string fileToStart) {
|
||||
auto bd = constructBlockDevice(fileToStart.c_str());
|
||||
// Can't init anything without a block device...
|
||||
if (!bd)
|
||||
return;
|
||||
ISOFileSystem *umd2 = new ISOFileSystem(&pspFileSystem, bd);
|
||||
IFileSystem* umd2;
|
||||
|
||||
// check if it's a disc directory
|
||||
FileInfo info;
|
||||
if (!getFileInfo(fileToStart.c_str(), &info)) return;
|
||||
|
||||
if (info.isDirectory)
|
||||
{
|
||||
umd2 = new DirectoryFileSystem(&pspFileSystem, fileToStart,true);
|
||||
}
|
||||
else
|
||||
{
|
||||
auto bd = constructBlockDevice(fileToStart.c_str());
|
||||
// Can't init anything without a block device...
|
||||
if (!bd)
|
||||
return;
|
||||
umd2 = new ISOFileSystem(&pspFileSystem, bd);
|
||||
}
|
||||
|
||||
// Parse PARAM.SFO
|
||||
|
||||
|
||||
Reference in new issue
Block a user