diff options
author | 2025-04-14 11:31:53 +0200 | |
---|---|---|
committer | 2025-04-27 22:23:20 +0200 | |
commit | d0f1c15a0f6df2dd51a754cb46e6175b7079c8f2 (patch) | |
tree | be35c94340442af08c316a8679089ee68e119fac /src/devices/imagedev/floppy.cpp | |
parent | ec636faeba5c5841c5a4a35b7c9dc2f06a00f538 (diff) |
New sound infrastructure.
Should be added soon:
- mute
- speaker/microphone resampling
To be added a little later:
- compression
- reverb
Needs to be added by someone else:
- coreaudio
- direct
- portaudio
- xaudio2
- js
Diffstat (limited to 'src/devices/imagedev/floppy.cpp')
-rw-r--r-- | src/devices/imagedev/floppy.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/devices/imagedev/floppy.cpp b/src/devices/imagedev/floppy.cpp index 8dd70d5fd62..b6f3e2b69b5 100644 --- a/src/devices/imagedev/floppy.cpp +++ b/src/devices/imagedev/floppy.cpp @@ -1595,18 +1595,17 @@ void floppy_sound_device::step(int zone) // sound_stream_update - update the sound stream //------------------------------------------------- -void floppy_sound_device::sound_stream_update(sound_stream &stream, std::vector<read_stream_view> const &inputs, std::vector<write_stream_view> &outputs) +void floppy_sound_device::sound_stream_update(sound_stream &stream) { // We are using only one stream, unlike the parent class // Also, there is no need for interpolation, as we only expect // one sample rate of 44100 for all samples int16_t out; - auto &samplebuffer = outputs[0]; int m_idx = 0; int sampleend = 0; - for (int sampindex = 0; sampindex < samplebuffer.samples(); sampindex++) + for (int sampindex = 0; sampindex < stream.samples(); sampindex++) { out = 0; @@ -1700,7 +1699,7 @@ void floppy_sound_device::sound_stream_update(sound_stream &stream, std::vector< } // Write to the stream buffer - samplebuffer.put_int(sampindex, out, 32768); + stream.put_int(0, sampindex, out, 32768); } } |