summary refs log tree commit diff stats
path: root/src/mixer.h
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2021-02-03 17:11:46 -0500
committerKelly Rauchenberger <fefferburbia@gmail.com>2021-02-03 17:11:46 -0500
commitdab96b810691c26e29fef92d88c828a311be3e9d (patch)
treee906b10f8dbca817e2b65bd14469226c2717a05a /src/mixer.h
parentc54dd4fd583f1d00d424590a9f192b2a35ede26b (diff)
downloadtanetane-dab96b810691c26e29fef92d88c828a311be3e9d.tar.gz
tanetane-dab96b810691c26e29fef92d88c828a311be3e9d.tar.bz2
tanetane-dab96b810691c26e29fef92d88c828a311be3e9d.zip
Added running sounds
Diffstat (limited to 'src/mixer.h')
-rw-r--r--src/mixer.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/mixer.h b/src/mixer.h index 010bb09..7f6ef72 100644 --- a/src/mixer.h +++ b/src/mixer.h
@@ -56,10 +56,16 @@ using chunk_ptr = std::unique_ptr<Mix_Chunk, chunk_deleter>;
56class Mixer { 56class Mixer {
57public: 57public:
58 58
59 void playSound(std::string filename); 59 void playSound(std::string_view filename);
60
61 int loopSound(std::string_view filename);
62
63 void stopChannel(int channel);
60 64
61private: 65private:
62 66
67 Mix_Chunk* getChunkByFilename(std::string filename);
68
63 mix_wrapper mix_; 69 mix_wrapper mix_;
64 std::map<std::string, chunk_ptr> sounds_; 70 std::map<std::string, chunk_ptr> sounds_;
65}; 71};