spu.s_chan[ch].sinc = NP << 4;\r
spu.s_chan[ch].sinc_inv = 0;\r
spu.SB[ch * SB_SIZE + 32] = 1; // -> freq change in simple interpolation mode: set flag\r
- if (val)\r
- spu.dwChannelsAudible |= 1u << ch;\r
- else\r
- spu.dwChannelsAudible &= ~(1u << ch);\r
+\r
+ // don't mess spu.dwChannelsAudible as adsr runs independently\r
}\r
\r
////////////////////////////////////////////////////////////////////////\r
spu.dwNewChannel&=~(1<<ch); // clear new channel bit
spu.dwChannelDead&=~(1<<ch);
- if (s_chan->iRawPitch)
- spu.dwChannelsAudible|=1<<ch;
+ spu.dwChannelsAudible|=1<<ch;
}
static void StartSound(int ch)
d = SkipADSR(&s_chan->ADSRX, d);
if (d < ns_to) {
spu.dwChannelsAudible &= ~(1 << ch);
+ s_chan->ADSRX.State = ADSR_RELEASE;
s_chan->ADSRX.EnvelopeVol = 0;
}
}