summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author hap <happppp@users.noreply.github.com>2021-05-03 23:39:05 +0200
committer hap <happppp@users.noreply.github.com>2021-05-03 23:39:53 +0200
commit2cf018ffd25b420f5288900ec19282545a9d4193 (patch)
treeea218c0c46bfd8e45e493ec4c35ce0650bf50c00
parent68c537a52d0df0aa4c018298611bfce519462da1 (diff)
spkrdev: change device description, it's not 1bit
-rw-r--r--src/devices/sound/spkrdev.cpp10
1 files 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;