diff options
Diffstat (limited to 'src/devices/sound/tms3615.cpp')
-rw-r--r-- | src/devices/sound/tms3615.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/src/devices/sound/tms3615.cpp b/src/devices/sound/tms3615.cpp index 5d9eac4e41e..85f1ec5ece0 100644 --- a/src/devices/sound/tms3615.cpp +++ b/src/devices/sound/tms3615.cpp @@ -6,11 +6,11 @@ #define VMIN 0x0000 #define VMAX 0x7fff -static const int divisor[TMS3615_TONES] = { 478, 451, 426, 402, 379, 358, 338, 319, 301, 284, 268, 253, 239 }; +const int tms3615_device::divisor[TMS3615_TONES] = { 478, 451, 426, 402, 379, 358, 338, 319, 301, 284, 268, 253, 239 }; // device type definition -const device_type TMS3615 = device_creator<tms3615_device>; +DEFINE_DEVICE_TYPE(TMS3615, tms3615_device, "tms3615", "TMS3615") //************************************************************************** @@ -22,17 +22,17 @@ const device_type TMS3615 = device_creator<tms3615_device>; //------------------------------------------------- tms3615_device::tms3615_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) - : device_t(mconfig, TMS3615, "TMS3615", tag, owner, clock, "tms3615", __FILE__), - device_sound_interface(mconfig, *this), - m_channel(nullptr), - m_samplerate(0), - m_basefreq(0), - m_output8(0), - m_output16(0), - m_enable(0) + : device_t(mconfig, TMS3615, tag, owner, clock) + , device_sound_interface(mconfig, *this) + , m_channel(nullptr) + , m_samplerate(0) + , m_basefreq(0) + , m_output8(0) + , m_output16(0) + , m_enable(0) { - memset(m_counter8, 0, TMS3615_TONES); - memset(m_counter16, 0, TMS3615_TONES); + std::fill(std::begin(m_counter8), std::end(m_counter8), 0); + std::fill(std::begin(m_counter16), std::end(m_counter16), 0); } @@ -55,8 +55,8 @@ void tms3615_device::device_start() void tms3615_device::sound_stream_update(sound_stream &stream, stream_sample_t **inputs, stream_sample_t **outputs, int samples) { int samplerate = m_samplerate; - stream_sample_t *buffer8 = outputs[TMS3615_FOOTAGE_8]; - stream_sample_t *buffer16 = outputs[TMS3615_FOOTAGE_16]; + stream_sample_t *buffer8 = outputs[FOOTAGE_8]; + stream_sample_t *buffer16 = outputs[FOOTAGE_16]; while( samples-- > 0 ) { |