flyinghead / flycast

Flycast is a multiplatform Sega Dreamcast, Naomi, Naomi 2 and Atomiswave emulator
GNU General Public License v2.0
1.38k stars 168 forks source link

Problems loading unlicensed games with redump cue/bin or chd images #906

Open gabberhead opened 1 year ago

gabberhead commented 1 year ago

I have tested some unlicensed games with flycast core on retroarch. a lot are working, but with some of them i have problems. here are the games, which i have problems:

Unsupported subtype or pre/postgap: Breakers (USA, Japan) (Unl) Cool Herders (USA) (Unl) Fast Striker Ver. 1.5 (Europe) (Unl) Feet of Fury (USA) (Unl) Gunlord (Europe) (Unl) Last Hope - Pink Bullets (Europe) (Unl) Leona's Tricky Adventures (Europe) (Unl) Neo XYX (Europe) (Unl) Sturmwind (Europe) (Unl) (Rerelease) Xeno Crisis (USA, Japan) (En,Ja,Fr,De,Es,It,Nl,Pt) (Unl)

chd only. cue/bin are working. except Sturmwind

Unhandled SH4 exception: Sturmwind (Europe) (Unl) (Rerelease)

cue/bin only. perhabs chd also, but chd is getting Unsupported subtype or pre/postgap error

Music/Sound Distortion: Dux Version 1.5 (USA, Japan) (Unl) Redux - Dark Matters (Europe) (Unl) Wind and Water - Puzzle Battles (Europe) (En,Ja) (Unl)

chd only. cue/bin are working

Fatal: SH4 branch instruction in delay slot: Ghost Blade (Europe) (Unl) (Limited Edition) Pier Solar and the Great Architects (USA) (Unl)

chd and cue/bin

Freeze after booting at the Sega Logo: Ganryu (USA, Japan) (Unl)

chd and cue/bin

chd files were made from the redump images with the newest chdman 0.251 version

flyinghead commented 1 year ago

What version of the flycast core are you using? I tested Breakers and Sturwind CUE and I can load them without issue. Please upgrade to the latest core version and retest.

There's an SH4 exception with Sturmwind so there might be an issue since the CDI works fine.

The Pier Solar issue is known. See #378 The Ghost Blade issue is probably due to copy protection.

gabberhead commented 1 year ago

i use the always the latest.

Unsupported subtype or pre/postgap: i get this only with chd images. cue/bin are working. but sturmwind its not working. not with chd and not with cue/bin

flyinghead commented 1 year ago

chdman supports GDI and CUE GD-ROMs but I'm not sure it can create valid CHDs from MIL-CDs.

See https://github.com/mamedev/mame/issues/8242

gabberhead commented 1 year ago

Unsupported subtype or pre/postgap errors with the chds I get, are the All mil-cds?

flyinghead commented 1 year ago

Yes, all unofficial Dreamcast games are MIL-CD (mixed audio+data CD-ROMs) while all official games are GD-ROMs. You can tell the difference by looking at the cue file.

GD-ROMs have a single density area and a high density area:

REM SINGLE-DENSITY AREA
FILE "Alienfront Online (USA) (Track 1).bin" BINARY
  TRACK 01 MODE1/2352
    INDEX 01 00:00:00
...
REM HIGH-DENSITY AREA
FILE "Alienfront Online (USA) (Track 3).bin" BINARY
  TRACK 03 MODE1/2352
    INDEX 01 00:00:00

MIL-CDs are multisession CD-ROMs:

REM SESSION 01
FILE "Breakers (USA, Japan) (Unl) (Track 01).bin" BINARY
  TRACK 01 AUDIO
    INDEX 01 00:00:00
...
REM SESSION 02
FILE "Breakers (USA, Japan) (Unl) (Track 33).bin" BINARY
  TRACK 33 MODE2/2352
    INDEX 01 00:00:00
gabberhead commented 1 year ago

But why games like finding teddy or some other unlicensed games are working with chd images. Are they not mil-cds?

flyinghead commented 1 year ago

I don't know. Finding Teddy has only one audio track and one data track so that may help.

gabberhead commented 1 year ago

here are some other unlicensed games wich are running fine with chd images with flycast:

Alice Dreams Tournament (US) [UNL] Alice Sisters (US) [UNL] Battle Crust (US) [UNL] Captain Tomaday (US) [UNL] Elansar (EU-DE) [UNL] Escapee, The (US-DE) [UNL] Flashback (US) [UNL] FX Unit Yuki (US) [UNL] Hermes (EU) [UNL] Inhabitants (US) [UNL] Intrepid Izzy (US) [UNL] Irides - Master of Blocks (US) [UNL] Magic Pockets (US) [UNL] Maqiupai (US-DE) [UNL] Orion's Puzzle Collection (EU) [UNL] Philia - The Sequel to Elansar (EU) [UNL] Satazius Next (US) [UNL] Wolflame (US) [UNL] Völgarr the Viking (World) [UNL]

flyinghead commented 1 year ago

Ghost Blade and Pier Solar both use a similar copy protection feature and need correct disk media catalog and track ISRC numbers. You can see them in the .CUE file:

CATALOG 0731453345927
REM SESSION 01
FILE "Track 01.bin" BINARY
  TRACK 01 AUDIO
    ISRC USPR39640267
    INDEX 01 00:00:00

As far as I know there is no way to store this information in CHDv5 files, so even if MIL-CD to CHD conversion is supported, these numbers will be lost and the games won't run. This would require a new CHD format version.

gabberhead commented 1 year ago

Ok. Thats understandable for chd files. But cue/bin also not working. Is this fixable for Cue/bin images?

Do u have investigated the Music distortion on dux, redux and Wind and water? The music distortion also happens only with chd files. cue bin the Music is working.

ValiumBear commented 1 month ago

Workaround for Unsupported subtype or pre/postgap:

CUE that works fine after converted to CHD: m1Mb5gSty9

CUE that produces error after converted to CHD BsS1cPMMpM

So I removed the INDEX 00 Lines, converted to CHD and the game finally loads without Unsupported subtype or pre/postgap error. Unfortunately the white noise audio bug (CHD related) is still present.