From 52736498b15a7464a2a395eb1984f9aa6578736d Mon Sep 17 00:00:00 2001 From: sD Date: Sat, 23 May 2020 17:21:22 +0200 Subject: fix up nomusic --- include/aomusicplayer.h | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/aomusicplayer.h b/include/aomusicplayer.h index 5c72649..f08b7d2 100644 --- a/include/aomusicplayer.h +++ b/include/aomusicplayer.h @@ -67,14 +67,28 @@ private: class AOMusicPlayer { public: AOMusicPlayer(QWidget *parent, AOApplication *p_ao_app); - ~AOMusicPlayer(); + virtual ~AOMusicPlayer(); + void set_volume(int p_value, int channel = -1); + void set_looping(bool toggle, int channel = 0); - void play(QString p_song); - void set_volume(int p_value); + const int m_channelmax = 4; + +public slots: + void play(QString p_song, int channel = 0, bool loop = false, + int effect_flags = 0); + void stop(int channel = 0); private: QWidget *m_parent; AOApplication *ao_app; + + bool m_looping = false; + int m_volume[4] = {0, 0, 0, 0}; + + // Channel 0 = music + // Channel 1 = ambience + // Channel 2 = extra + // Channel 3 = extra }; #endif -- cgit