diff options
Diffstat (limited to 'src/devices/sound/nes_apu.cpp')
-rw-r--r-- | src/devices/sound/nes_apu.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/devices/sound/nes_apu.cpp b/src/devices/sound/nes_apu.cpp index 3f5c7787a93..1e79304fb3a 100644 --- a/src/devices/sound/nes_apu.cpp +++ b/src/devices/sound/nes_apu.cpp @@ -134,7 +134,7 @@ void nesapu_device::calculate_rates() if (m_stream != nullptr) m_stream->set_sample_rate(rate); else - m_stream = machine().sound().stream_alloc(*this, 0, 1, rate); + m_stream = stream_alloc_legacy(0, 1, rate); } //------------------------------------------------- @@ -725,13 +725,14 @@ void nesapu_device::write(offs_t address, u8 value) //------------------------------------------------- -// sound_stream_update - handle a stream update +// sound_stream_update_legacy - handle a stream update //------------------------------------------------- -void nesapu_device::sound_stream_update(sound_stream &stream, stream_sample_t **inputs, stream_sample_t **outputs, int samples) +void nesapu_device::sound_stream_update_legacy(sound_stream &stream, stream_sample_t const * const *inputs, stream_sample_t * const *outputs, int samples) { int accum; - memset( outputs[0], 0, samples*sizeof(*outputs[0]) ); + stream_sample_t *output = outputs[0]; + memset( output, 0, samples*sizeof(*output) ); while (samples--) { @@ -747,6 +748,6 @@ void nesapu_device::sound_stream_update(sound_stream &stream, stream_sample_t ** else if (accum < -128) accum = -128; - *(outputs[0]++)=accum<<8; + *output++=accum<<8; } } |