summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/sound/flt_vol.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/devices/sound/flt_vol.h')
-rw-r--r--src/devices/sound/flt_vol.h11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/devices/sound/flt_vol.h b/src/devices/sound/flt_vol.h
index bcd4a05d399..96bc61af200 100644
--- a/src/devices/sound/flt_vol.h
+++ b/src/devices/sound/flt_vol.h
@@ -17,18 +17,19 @@ class filter_volume_device : public device_t, public device_sound_interface
public:
filter_volume_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0);
- void flt_volume_set_volume(float volume);
+ filter_volume_device &set_gain(float gain); // also may be used in mcfg to set initial value (default is 1.0)
+ float gain() { return m_gain; }
protected:
// device-level overrides
- virtual void device_start() override;
+ virtual void device_start() override ATTR_COLD;
// sound stream update overrides
- virtual void sound_stream_update(sound_stream &stream, stream_sample_t **inputs, stream_sample_t **outputs, int samples) override;
+ virtual void sound_stream_update(sound_stream &stream) override;
private:
- sound_stream* m_stream;
- int m_gain;
+ sound_stream* m_stream;
+ float m_gain;
};
DECLARE_DEVICE_TYPE(FILTER_VOLUME, filter_volume_device)