aboutsummaryrefslogtreecommitdiff
path: root/plugins/dfsound
diff options
context:
space:
mode:
authornotaz2011-01-29 19:47:46 +0200
committernotaz2011-01-29 20:11:55 +0200
commit08cfd5e5b3027af766dab3916747c0fc9ae47d7d (patch)
tree40c3a9e61a99273e1cc8445812b72f9056926c4b /plugins/dfsound
parentee849648a1bd5d12bd48c98f3b51bb96d7984d43 (diff)
downloadpcsx_rearmed-08cfd5e5b3027af766dab3916747c0fc9ae47d7d.tar.gz
pcsx_rearmed-08cfd5e5b3027af766dab3916747c0fc9ae47d7d.tar.bz2
pcsx_rearmed-08cfd5e5b3027af766dab3916747c0fc9ae47d7d.zip
spu: don't stop a channel by adsr if we have potential irq
otherwise we might miss irqs
Diffstat (limited to 'plugins/dfsound')
-rw-r--r--plugins/dfsound/adsr.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/plugins/dfsound/adsr.c b/plugins/dfsound/adsr.c
index 2496e46..387a83b 100644
--- a/plugins/dfsound/adsr.c
+++ b/plugins/dfsound/adsr.c
@@ -86,7 +86,10 @@ INLINE int MixADSR(int ch) // MIX ADSR
if(s_chan[ch].ADSRX.EnvelopeVol<0)
{
s_chan[ch].ADSRX.EnvelopeVol=0;
- s_chan[ch].bOn=0;
+ // don't stop if this chan can still cause irqs
+ if(!(spuCtrl&0x40) || (s_chan[ch].pCurr > pSpuIrq && s_chan[ch].pLoop > pSpuIrq))
+ //s_chan[ch].bOn=0;
+ s_chan[ch].pCurr=(unsigned char *)-1;
//s_chan[ch].bReverb=0;
//s_chan[ch].bNoise=0;
}