From 4e73d3ec54ed340e07bda2712f4381fb15bbf699 Mon Sep 17 00:00:00 2001 From: "SND\\weimingzhi_cp" Date: Mon, 24 May 2010 09:18:34 +0000 Subject: Fixed freeze bug when launching an NTSC game when Config.PsxAuto is enabled and Config.PsxType is set to PAL. git-svn-id: https://pcsxr.svn.codeplex.com/svn/pcsxr@48663 e17a0e51-4ae3-4d35-97c3-1a29b211df97 --- libpcsxcore/psxcounters.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'libpcsxcore') diff --git a/libpcsxcore/psxcounters.c b/libpcsxcore/psxcounters.c index d1089b66..16cea3af 100644 --- a/libpcsxcore/psxcounters.c +++ b/libpcsxcore/psxcounters.c @@ -75,10 +75,10 @@ static const s32 VerboseLevel = 0; static Rcnt rcnts[ CounterQuantity ]; -static u32 hSyncCount; -static u32 spuSyncCount; +static u32 hSyncCount = 0; +static u32 spuSyncCount = 0; -u32 psxNextCounter, psxNextsCounter; +u32 psxNextCounter = 0, psxNextsCounter = 0; /******************************************************************************/ @@ -273,7 +273,7 @@ void psxRcntUpdate() hSyncCount++; // Update spu. - if( spuSyncCount == SpuUpdInterval[Config.PsxType] ) + if( spuSyncCount >= SpuUpdInterval[Config.PsxType] ) { spuSyncCount = 0; @@ -285,13 +285,13 @@ void psxRcntUpdate() /* // For the best times. :D // VSync irq. - if( hSyncCount == VBlankStart[Config.PsxType] ) + if( hSyncCount >= VBlankStart[Config.PsxType] ) { setIrq( 0x01 ); } */ // Update lace. (with InuYasha fix) - if( hSyncCount == (Config.VSyncWA ? HSyncTotal[Config.PsxType] / BIAS : HSyncTotal[Config.PsxType]) ) + if( hSyncCount >= (Config.VSyncWA ? HSyncTotal[Config.PsxType] / BIAS : HSyncTotal[Config.PsxType]) ) { hSyncCount = 0; -- cgit v1.2.3