diff options
author | 2012-09-03 13:56:17 +0000 | |
---|---|---|
committer | 2012-09-03 13:56:17 +0000 | |
commit | b711b1a007c3a4a75e78eb88f9a6afe4d4180728 (patch) | |
tree | 1498465a0134d7b039fce9271d2b388d218425d4 /src/emu/sound/multipcm.c | |
parent | f552908ea962ecdd7e94ea609c84144815b64557 (diff) |
conversion of legacy devices into modern wip (no whatsnew)
Diffstat (limited to 'src/emu/sound/multipcm.c')
-rw-r--r-- | src/emu/sound/multipcm.c | 42 |
1 files changed, 40 insertions, 2 deletions
diff --git a/src/emu/sound/multipcm.c b/src/emu/sound/multipcm.c index 43c7a2b3a2f..b03d1bc604b 100644 --- a/src/emu/sound/multipcm.c +++ b/src/emu/sound/multipcm.c @@ -130,7 +130,7 @@ INLINE MultiPCM *get_safe_token(device_t *device) { assert(device != NULL); assert(device->type() == MULTIPCM); - return (MultiPCM *)downcast<legacy_device_base *>(device)->token(); + return (MultiPCM *)downcast<multipcm_device *>(device)->token(); } @@ -700,4 +700,42 @@ DEVICE_GET_INFO( multipcm ) } -DEFINE_LEGACY_SOUND_DEVICE(MULTIPCM, multipcm); +const device_type MULTIPCM = &device_creator<multipcm_device>; + +multipcm_device::multipcm_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) + : device_t(mconfig, MULTIPCM, "Sega/Yamaha 315-5560", tag, owner, clock), + device_sound_interface(mconfig, *this) +{ + m_token = global_alloc_array_clear(UINT8, sizeof(MultiPCM)); +} + +//------------------------------------------------- +// device_config_complete - perform any +// operations now that the configuration is +// complete +//------------------------------------------------- + +void multipcm_device::device_config_complete() +{ +} + +//------------------------------------------------- +// device_start - device-specific startup +//------------------------------------------------- + +void multipcm_device::device_start() +{ + DEVICE_START_NAME( multipcm )(this); +} + +//------------------------------------------------- +// sound_stream_update - handle a stream update +//------------------------------------------------- + +void multipcm_device::sound_stream_update(sound_stream &stream, stream_sample_t **inputs, stream_sample_t **outputs, int samples) +{ + // should never get here + fatalerror("sound_stream_update called; not applicable to legacy sound devices\n"); +} + + |