diff options
| author | stonedDiscord <stoned@derpymail.org> | 2019-08-17 20:47:41 +0200 |
|---|---|---|
| committer | stonedDiscord <stoned@derpymail.org> | 2019-08-17 20:47:41 +0200 |
| commit | 4700902551f80769b54cb452b0fcb794669c553b (patch) | |
| tree | 3c291dc4fae450af760c3d01ed126467c08cce3a /include | |
| parent | 2509cc5e0bf4d9c4bbd6798f71886e34cc8476b2 (diff) | |
fix qaudio volume
Diffstat (limited to 'include')
| -rw-r--r-- | include/aoblipplayer.h | 5 | ||||
| -rw-r--r-- | include/aosfxplayer.h | 8 |
2 files changed, 8 insertions, 5 deletions
diff --git a/include/aoblipplayer.h b/include/aoblipplayer.h index 102a0408..68dca191 100644 --- a/include/aoblipplayer.h +++ b/include/aoblipplayer.h @@ -21,15 +21,16 @@ public: void set_blips(QString p_sfx); void blip_tick(); - void set_volume(int p_volume); + void set_volume(qreal p_volume); + void set_volume_internal(qreal p_volume); int m_cycle = 0; private: QWidget *m_parent; AOApplication *ao_app; + qreal m_volume; - int m_volume; #if defined(BASSAUDIO) HSTREAM m_stream_list[5]; #elif defined(QTAUDIO) diff --git a/include/aosfxplayer.h b/include/aosfxplayer.h index 4b976852..5b4b41d8 100644 --- a/include/aosfxplayer.h +++ b/include/aosfxplayer.h @@ -20,17 +20,19 @@ public: void play(QString p_sfx, QString p_char = "", QString shout = ""); void stop(); - void set_volume(int p_volume); + void set_volume(qreal p_volume); + void set_volume_internal(qreal p_volume); private: QWidget *m_parent; AOApplication *ao_app; + qreal m_volume = 0; + #if defined(BASSAUDIO) HSTREAM m_stream; #elif defined(QTAUDIO) - QSoundEffect m_sfx; + QSoundEffect m_sfx; #endif - int m_volume = 0; }; #endif // AOSFXPLAYER_H |
