different cue gap sector synth for data and audio sectors
This commit is contained in:
parent
9b5daa9e3c
commit
1de6033c0a
|
@ -330,9 +330,9 @@ namespace BizHawk.Client.DiscoHawk
|
|||
sw_dump_chunk_one(string.Format("DST #{0,6} ({1})", lba, new Timestamp(lba)), lba, dst_databuf, addr, count);
|
||||
};
|
||||
|
||||
//verify each sector contents (skip the pregap junk for now)
|
||||
//verify each sector contents
|
||||
int nSectors = src_disc.LBACount;
|
||||
for (int lba = 0; lba < nSectors; lba++)
|
||||
for (int lba = -150; lba < nSectors; lba++)
|
||||
{
|
||||
if (lba % 1000 == 0)
|
||||
Console.WriteLine("LBA {0} of {1}", lba, src_disc.LBACount);
|
||||
|
|
|
@ -213,7 +213,9 @@ namespace BizHawk.Emulation.DiscSystem
|
|||
for (int s = 0; s < specifiedPregapLength; s++)
|
||||
{
|
||||
var se = new SectorEntry(null);
|
||||
var ss = new SS_Gap();
|
||||
SS_Base ss;
|
||||
if (cct.TrackType == CueFile.TrackType.Audio) ss = new SS_AudioGap();
|
||||
else ss = new SS_DataGap();
|
||||
|
||||
//-subq-
|
||||
byte ADR = 1;
|
||||
|
@ -285,6 +287,12 @@ namespace BizHawk.Emulation.DiscSystem
|
|||
curr_blobOffset += 2048;
|
||||
break;
|
||||
|
||||
default:
|
||||
case CueFile.TrackType.Mode2_2336:
|
||||
throw new InvalidOperationException("Not supported: " + cct.TrackType);
|
||||
|
||||
case CueFile.TrackType.CDI_2352:
|
||||
case CueFile.TrackType.Mode1_2352:
|
||||
case CueFile.TrackType.Mode2_2352:
|
||||
case CueFile.TrackType.Audio:
|
||||
ss = new SS_2352() { Blob = curr_blobInfo.Blob, BlobOffset = curr_blobOffset };
|
||||
|
@ -335,7 +343,9 @@ namespace BizHawk.Emulation.DiscSystem
|
|||
for (int s = 0; s < specifiedPostgapLength; s++)
|
||||
{
|
||||
var se= new SectorEntry(null);
|
||||
var ss = new SS_Gap();
|
||||
SS_Base ss;
|
||||
if (cct.TrackType == CueFile.TrackType.Audio) ss = new SS_AudioGap();
|
||||
else ss = new SS_DataGap();
|
||||
|
||||
//-subq-
|
||||
byte ADR = 1;
|
||||
|
|
|
@ -106,13 +106,26 @@ namespace BizHawk.Emulation.DiscSystem
|
|||
}
|
||||
|
||||
/// <summary>
|
||||
/// Represents a pregap or postgap sector.
|
||||
/// The Pause flag isn't set in here because it might need special logic varying between sectors
|
||||
/// Represents a data pregap or postgap sector.
|
||||
/// The Pause flag isn't set in here because it might need special logic varying between sectors and so that's setup by the cue loader
|
||||
/// Implemented as another sector type with a blob reading all zeros
|
||||
/// </summary>
|
||||
class SS_Gap : SS_Mode1_2048
|
||||
class SS_DataGap : SS_Mode1_2048
|
||||
{
|
||||
public SS_Gap()
|
||||
public SS_DataGap()
|
||||
{
|
||||
Blob = new Disc.Blob_Zeros();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Represents an audio pregap or postgap sector.
|
||||
/// The Pause flag isn't set in here because it might need special logic varying between sectors and so that's setup by the cue loader
|
||||
/// Implemented as another sector type with a blob reading all zeros
|
||||
/// </summary>
|
||||
class SS_AudioGap : SS_2352
|
||||
{
|
||||
public SS_AudioGap()
|
||||
{
|
||||
Blob = new Disc.Blob_Zeros();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue