blob: c45b4d4447d479d74368f87a50e6827944b711da (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
|
// license:BSD-3-Clause
// copyright-holders:Nicola Salmoria
#ifndef MAME_SOUND_N63701X_H
#define MAME_SOUND_N63701X_H
#pragma once
//**************************************************************************
// TYPE DEFINITIONS
//**************************************************************************
// ======================> namco_63701x_device
class namco_63701x_device : public device_t,
public device_sound_interface
{
public:
namco_63701x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock);
void write(offs_t offset, uint8_t data);
protected:
// device-level overrides
virtual void device_start() override;
// sound stream update overrides
virtual void sound_stream_update(sound_stream &stream, std::vector<read_stream_view> const &inputs, std::vector<write_stream_view> &outputs) override;
private:
struct voice_63701x
{
voice_63701x() { }
int select = 0;
int playing = 0;
int base_addr = 0;
int position = 0;
int volume = 0;
int silence_counter = 0;
};
required_region_ptr<uint8_t> m_rom;
voice_63701x m_voices[2];
sound_stream *m_stream; /* channel assigned by the mixer */
};
DECLARE_DEVICE_TYPE(NAMCO_63701X, namco_63701x_device)
#endif // MAME_SOUND_N63701X_H
|