diff --git a/src/engine/platform/sms.cpp b/src/engine/platform/sms.cpp index e5be23045..35bb9c40c 100644 --- a/src/engine/platform/sms.cpp +++ b/src/engine/platform/sms.cpp @@ -101,7 +101,20 @@ void DivPlatformSMS::acquire_mame(short* bufL, short* bufR, size_t start, size_t sn->write(w.val); writes.pop(); } - sn->sound_stream_update(snBuf,len); + for (size_t h=0; hsound_stream_update(outs,1); + for (int i=0; i<4; i++) { + if (isMuted[i]) { + oscBuf[i]->data[oscBuf[i]->needle++]=0; + } else { + oscBuf[i]->data[oscBuf[i]->needle++]=sn->get_channel_output(i); + } + } + } if (stereo) { for (size_t i=0; idata[oscBuf[i]->needle++]=0; - } else { - oscBuf[i]->data[oscBuf[i]->needle++]=sn->get_channel_output(i); - } - } - } } void DivPlatformSMS::acquire(short* bufL, short* bufR, size_t start, size_t len) { diff --git a/src/engine/platform/sound/sn76496.cpp b/src/engine/platform/sound/sn76496.cpp index afb82ad3a..4bbb5848a 100644 --- a/src/engine/platform/sound/sn76496.cpp +++ b/src/engine/platform/sound/sn76496.cpp @@ -411,7 +411,7 @@ void sn76496_base_device::sound_stream_update(short** outputs, int outLen) if (m_negate) { out = -out; out2 = -out2; } outputs[0][sampindex]=out; - if (m_stereo) + if (m_stereo && (outputs[1] != nullptr)) outputs[1][sampindex]=out; } }