diff options
Diffstat (limited to 'src/devices/sound/ym2413.cpp')
-rw-r--r-- | src/devices/sound/ym2413.cpp | 27 |
1 files changed, 25 insertions, 2 deletions
diff --git a/src/devices/sound/ym2413.cpp b/src/devices/sound/ym2413.cpp index 755e66ea629..e226f7ef5d4 100644 --- a/src/devices/sound/ym2413.cpp +++ b/src/devices/sound/ym2413.cpp @@ -2,8 +2,8 @@ // copyright-holders:Jarek Burczynski, Ernesto Corvi /* ** -** File: ym2413.c - software implementation of YM2413 -** FM sound generator type OPLL +** File: ym2413.cpp - software implementation of YM2413 +** FM sound generator type OPLL ** ** Copyright Jarek Burczynski ** @@ -1742,11 +1742,34 @@ ym2413_device::ym2413_device(const machine_config &mconfig, const char *tag, dev ym2413_device::ym2413_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) + , eg_cnt(0) + , eg_timer(0) + , eg_timer_add(0) + , eg_timer_overflow(0) + , rhythm(0) + , LFO_AM(0) + , LFO_PM(0) + , lfo_am_cnt(0) + , lfo_am_inc(0) + , lfo_pm_cnt(0) + , lfo_pm_inc(0) + , noise_rng(0) + , noise_p(0) + , noise_f(0) + , address(0) + { for (int i = 0; i < 19; i++) { std::fill_n(&m_inst_table[i][0], 8, 0); + std::fill_n(&inst_tab[i][0], 8, 0); } + + std::fill(std::begin(tl_tab), std::end(tl_tab), 0); + std::fill(std::begin(sin_tab), std::end(sin_tab), 0); + std::fill(std::begin(instvol_r), std::end(instvol_r), 0); + std::fill(std::begin(fn_tab), std::end(fn_tab), 0); + std::fill(std::begin(output), std::end(output), 0); } DEFINE_DEVICE_TYPE(VRC7, vrc7snd_device, "vrc7snd", "Konami VRC7 (Sound)") |