diff options
| -rw-r--r-- | ChangeLog | 6 | ||||
| -rw-r--r-- | libpcsxcore/plugins.c | 3 | ||||
| -rw-r--r-- | libpcsxcore/plugins.h | 2 | ||||
| -rw-r--r-- | libpcsxcore/psxcounters.c | 11 |
4 files changed, 18 insertions, 4 deletions
@@ -1,3 +1,9 @@ +July 4, 2010 edgbla <edgbla@yandex.ru>
+
+ * libpcsxcore/plugins.c: GPUvBlank (for gpuBladeSoft now, experimental).
+ * libpcsxcore/plugins.h: Likewise.
+ * libpcsxcore/psxcounters.c: Likewise.
+
July 3, 2010 edgbla <edgbla@yandex.ru>
* libpcsxcore/psxhw.c: Sio1 interface (link cable).
diff --git a/libpcsxcore/plugins.c b/libpcsxcore/plugins.c index 32a3de0a..d1371751 100644 --- a/libpcsxcore/plugins.c +++ b/libpcsxcore/plugins.c @@ -49,6 +49,7 @@ GPUfreeze GPU_freeze; GPUgetScreenPic GPU_getScreenPic;
GPUshowScreenPic GPU_showScreenPic;
GPUclearDynarec GPU_clearDynarec;
+GPUvBlank GPU_vBlank;
CDRinit CDR_init;
CDRshutdown CDR_shutdown;
@@ -201,6 +202,7 @@ void CALLBACK GPU__keypressed(int key) {} long CALLBACK GPU__getScreenPic(unsigned char *pMem) { return -1; }
long CALLBACK GPU__showScreenPic(unsigned char *pMem) { return -1; }
void CALLBACK GPU__clearDynarec(void (CALLBACK *callback)(void)) {}
+void CALLBACK GPU__vBlank(int val) {}
#define LoadGpuSym1(dest, name) \
LoadSym(GPU_##dest, GPU##dest, name, TRUE);
@@ -240,6 +242,7 @@ static int LoadGPUplugin(const char *GPUdll) { LoadGpuSym0(getScreenPic, "GPUgetScreenPic");
LoadGpuSym0(showScreenPic, "GPUshowScreenPic");
LoadGpuSym0(clearDynarec, "GPUclearDynarec");
+ LoadGpuSym0(vBlank, "GPUvBlank");
LoadGpuSym0(configure, "GPUconfigure");
LoadGpuSym0(test, "GPUtest");
LoadGpuSym0(about, "GPUabout");
diff --git a/libpcsxcore/plugins.h b/libpcsxcore/plugins.h index 470985cd..20fde072 100644 --- a/libpcsxcore/plugins.h +++ b/libpcsxcore/plugins.h @@ -91,6 +91,7 @@ typedef long (CALLBACK* GPUfreeze)(uint32_t, GPUFreeze_t *); typedef long (CALLBACK* GPUgetScreenPic)(unsigned char *);
typedef long (CALLBACK* GPUshowScreenPic)(unsigned char *);
typedef void (CALLBACK* GPUclearDynarec)(void (CALLBACK *callback)(void));
+typedef void (CALLBACK* GPUvBlank)(int);
// GPU function pointers
extern GPUupdateLace GPU_updateLace;
@@ -115,6 +116,7 @@ extern GPUfreeze GPU_freeze; extern GPUgetScreenPic GPU_getScreenPic;
extern GPUshowScreenPic GPU_showScreenPic;
extern GPUclearDynarec GPU_clearDynarec;
+extern GPUvBlank GPU_vBlank;
// CD-ROM Functions
typedef long (CALLBACK* CDRinit)(void);
diff --git a/libpcsxcore/psxcounters.c b/libpcsxcore/psxcounters.c index fed43c69..ebfe6296 100644 --- a/libpcsxcore/psxcounters.c +++ b/libpcsxcore/psxcounters.c @@ -282,19 +282,22 @@ void psxRcntUpdate() SPU_async( SpuUpdInterval[Config.PsxType] * rcnts[3].target ); } } - /* - // For the best times. :D + // VSync irq. if( hSyncCount == VBlankStart[Config.PsxType] ) { - setIrq( 0x01 ); + GPU_vBlank( 1 ); + + // For the best times. :D + //setIrq( 0x01 ); } - */ + // Update lace. (with InuYasha fix) if( hSyncCount >= (Config.VSyncWA ? HSyncTotal[Config.PsxType] / BIAS : HSyncTotal[Config.PsxType]) ) { hSyncCount = 0; + GPU_vBlank( 0 ); setIrq( 0x01 ); GPU_updateLace(); |
