Fixed independent channel volumes in Okim6376 sound chip, used by the games from the Road Hog era of MPU4 [J. Wallace]

This commit is contained in:
Angelo Salese 2011-08-17 13:19:50 +00:00
parent f818f699f8
commit 3d5a7dfd54

View File

@ -219,9 +219,12 @@ static void oki_process(okim6376_state *info, int channel, int command)
/* also reset the ADPCM parameters */
reset_adpcm(voice);
/* FIX: no attenuation for now, handle for channel 2 separately */
if (channel == 0)
{
/* We set channel 2's audio separately */
voice->volume = volume_table[0];
}
}
else
{
if (((info->nar)&&(channel == 0))||(channel == 1))//Store the request, for later processing (channel 2 ignores NAR)
@ -574,6 +577,7 @@ WRITE_LINE_DEVICE_HANDLER( okim6376_st_w )
{
info->st_pulses ++;
MSM6376LOG(("OKIM6376:'%s' ST pulses %x\n",device->tag(),info->st_pulses));
if (info->st_pulses > 3)
{
info->st_pulses = 3; //undocumented behaviour beyond 3 pulses