summaryrefslogtreecommitdiff
path: root/libpcsxcore/cdrom.c
diff options
context:
space:
mode:
authorSND\shalma_cp <SND\shalma_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97>2010-12-02 18:39:26 +0000
committerSND\shalma_cp <SND\shalma_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97>2010-12-02 18:39:26 +0000
commitecff5e58679454c947975da6edcfec724b0fe0aa (patch)
tree593e61c56e64f2201b4bc5ee831a87d7215b8868 /libpcsxcore/cdrom.c
parenta8ffba8f7e9bf2eb80486e058b99ae6d40c0ab4b (diff)
downloadpcsxr-ecff5e58679454c947975da6edcfec724b0fe0aa.tar.gz
Redump.org SBI - cdrom.c, cdriso.c
- native support (LibCrypt) ex. TOCA World Touring Cars (Europe) 1) Run CDROM - download SBI from redump.org - place in emu folder - name "redump.sbi" - run CDROM (subchannel optional) 2) Run ISO - download SBI from redump.org - place in iso folder - "toca world cars.bin", "toca world cars.cue", "toca world cars.sbi" or "toca world cars.img", "toca world cars.ccd", "toca world cars.sbi" - run ISO (subchannel file optional) git-svn-id: https://pcsxr.svn.codeplex.com/svn/pcsxr@60534 e17a0e51-4ae3-4d35-97c3-1a29b211df97
Diffstat (limited to 'libpcsxcore/cdrom.c')
-rw-r--r--libpcsxcore/cdrom.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/libpcsxcore/cdrom.c b/libpcsxcore/cdrom.c
index b22946b1..abc431dc 100644
--- a/libpcsxcore/cdrom.c
+++ b/libpcsxcore/cdrom.c
@@ -485,6 +485,12 @@ static void ReadTrack( u8 *time ) {
cdr.RErr = CDR_readTrack(cdr.Prev);
}
+
+extern int opensbifile(const char *isoname);
+extern int cdrIsoActive(void);
+extern int checkSBI(u8 *time);
+
+
void AddIrqQueue(unsigned char irq, unsigned long ecycle) {
cdr.Irq = irq;
cdr.eCycle = ecycle;
@@ -1104,6 +1110,11 @@ void cdrInterrupt() {
}
}
+ // redump.org - wipe time
+ if( !cdr.Play && checkSBI(cdr.Result+5) ) {
+ memset( cdr.Result+2, 0, 6 );
+ }
+
cdr.Stat = Acknowledge;
break;
@@ -2159,6 +2170,10 @@ void cdrReset() {
cdr.CurTrack = 1;
cdr.File = 1;
cdr.Channel = 1;
+
+ if( !cdrIsoActive() ) {
+ opensbifile( "redump.sbi" );
+ }
}
int cdrFreeze(gzFile f, int Mode) {