Part Of ESR patches the game's sceCdMmode function to always 'see' a valid PS2 DVD game:
int hook_sceCdMmode(int mode)
{
DBGPRINTF("sceCdMmode, val = %d\n", mode);
if (mode != CdMmodeDvd)
{
if (readDiscType() == 0xFE || readDiscType() == 0x14)
mode = CdMmodeDvd;
}
return allValues.def_sceCdMmode(mode);
Can we do something like this? (or better yet determine if it wants CD or DVD and do that):
int hook_sceCdMmode(int mode)
{
DBGPRINTF("sceCdMmode, val = %d\n", mode);
if (mode != CdMmodeCd)
{
if (readDiscType() == 0xFE || readDiscType() == 0x14)
mode = CdMmodeCd;
}
return allValues.def_sceCdMmode(mode);
}
Not sure if I'm missing other checks, but the idea would be to obsolete DVD Scan Lite and Console Media Patcher. Right now one needs to :
1) Extract all ISO files.
2) Clumsily select all files in each folder and search them with either closed-source windows-only patcher (though CMP and DVD Scan Lite both work great in Wine). You have to do this for sub-folders manually too...
3) Rebuild or insert the files back into the image file.
4) Convert the image file to UDF DVD with DOS 8.3 names. with LBA order in-tact.
5) Add dummy file at end of image (not required for some games AFAICT)
6) Patch with ESR
The old tutorials are great but the simplest way I have found is to use UltraISO. Using UltraISO you can literally open a bin/cue PS2 CD game, click properties, check UDF, check DOS 8.3, in the drop-down select 4.7GB, and then save a .iso file. If I can obsolete CMP and DVD Scan Lite I don't need to extract/patch/insert anything (besides possibly a dummy file). Apparently the patchers could also miss some of the calls too, this would be bulliet-proof if done console-side and might even allow more PS2 CD games to work with ESR overall (without requiring one to know MIPS assembly to make thier own CD to DVD patches for a game that CMP or DVD Scan Lite can't patch).