From 2cf018ffd25b420f5288900ec19282545a9d4193 Mon Sep 17 00:00:00 2001 From: hap Date: Mon, 3 May 2021 23:39:05 +0200 Subject: spkrdev: change device description, it's not 1bit --- src/devices/sound/spkrdev.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/devices/sound/spkrdev.cpp b/src/devices/sound/spkrdev.cpp index 03694c84b3e..7d9333d02cb 100644 --- a/src/devices/sound/spkrdev.cpp +++ b/src/devices/sound/spkrdev.cpp @@ -74,14 +74,14 @@ #include "emu.h" #include "sound/spkrdev.h" - -static constexpr double default_levels[2] = {0.0, 1.0}; +// The default is 1-bit, but can be customized with set_levels. +static constexpr double default_levels[2] = { 0.0, 1.0 }; // Internal oversampling factor (intermediate samples vs stream samples) static constexpr int RATE_MULTIPLIER = 4; -DEFINE_DEVICE_TYPE(SPEAKER_SOUND, speaker_sound_device, "speaker_sound_device", "Filtered 1-bit DAC") +DEFINE_DEVICE_TYPE(SPEAKER_SOUND, speaker_sound_device, "speaker_sound_device", "Filtered DAC") speaker_sound_device::speaker_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) @@ -143,9 +143,9 @@ void speaker_sound_device::device_start() */ #define FILTER_STEP (M_PI / 2 / RATE_MULTIPLIER) /* Distribute symmetrically on x axis; center has x=0 if length is odd */ - for (i = 0, x = (0.5 - FILTER_LENGTH / 2.) * FILTER_STEP; + for (i = 0, x = (0.5 - FILTER_LENGTH / 2.) * FILTER_STEP; i < FILTER_LENGTH; - i++, x += FILTER_STEP) + i++, x += FILTER_STEP) { if (x == 0) m_ampl[i] = 1; -- cgit v1.2.3