summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/sound
diff options
context:
space:
mode:
author Aaron Giles <aaron@aarongiles.com>2020-09-21 01:28:37 -0700
committer Aaron Giles <aaron@aarongiles.com>2020-09-21 01:28:37 -0700
commit18e20127f0df792e2e2e557c5a92392fd92f0889 (patch)
tree9fb0f384cd45eae44a84b5e9cfb594422ecc607d /src/devices/sound
parent4d72d362374a3e211762d96b818da4f894957ade (diff)
Fix for last commit
Diffstat (limited to 'src/devices/sound')
-rw-r--r--src/devices/sound/rp2c33_snd.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/devices/sound/rp2c33_snd.cpp b/src/devices/sound/rp2c33_snd.cpp
index 57e60cf9fb5..506e21ce21c 100644
--- a/src/devices/sound/rp2c33_snd.cpp
+++ b/src/devices/sound/rp2c33_snd.cpp
@@ -56,7 +56,7 @@ void rp2c33_sound_device::device_start()
for (int i = 0; i < 4; i++)
m_mvol_table[i] = int((65536.0 / (32.0 * 64.0)) * 2.0 / double(i + 2));
- m_stream = stream_alloc_legacy(0, 1, clock());
+ m_stream = stream_alloc(0, 1, clock());
// save states
save_item(NAME(m_regs));
@@ -221,9 +221,9 @@ void rp2c33_sound_device::write(offs_t offset, u8 data)
// sound_stream_update_legacy - handle a stream update
//-------------------------------------------------
-void rp2c33_sound_device::sound_stream_update_legacy(sound_stream &stream, stream_sample_t const * const *inputs, stream_sample_t * const *outputs, int samples)
+void rp2c33_sound_device::sound_stream_update(sound_stream &stream, std::vector<read_stream_view> const &inputs, std::vector<write_stream_view> &outputs)
{
- for (int i = 0; i < samples; i++)
+ for (int i = 0; i < outputs[0].samples(); i++)
{
m_output = 0;
if (!m_env_halt && !m_wave_halt)
@@ -234,7 +234,7 @@ void rp2c33_sound_device::sound_stream_update_legacy(sound_stream &stream, strea
exec_mod();
exec_wave();
/* Update the buffers */
- outputs[0][i] = m_output * m_mvol_table[m_mvol];
+ outputs[0].put_int(i, m_output * m_mvol_table[m_mvol], 32768);
}
}