aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/facade/Sound.cpp
diff options
context:
space:
mode:
authorLoek Le Blansch <loek@pipeframe.xyz>2024-11-14 19:57:45 +0100
committerLoek Le Blansch <loek@pipeframe.xyz>2024-11-14 19:57:45 +0100
commitadd8724446fdeae1aaec9b07544cf7a5475a9bfe (patch)
tree7c51cf0d65f8f0d906a0abe2b29bad916dcf83e8 /src/crepe/facade/Sound.cpp
parentab0b4923c4f49e7a28f6d17e994d3e013ca344bb (diff)
ResourceManager working + tested
Diffstat (limited to 'src/crepe/facade/Sound.cpp')
-rw-r--r--src/crepe/facade/Sound.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/crepe/facade/Sound.cpp b/src/crepe/facade/Sound.cpp
index 4eefcda..b589759 100644
--- a/src/crepe/facade/Sound.cpp
+++ b/src/crepe/facade/Sound.cpp
@@ -11,6 +11,7 @@ Sound::Sound(const Asset & src) : Resource(src) {
this->sample.load(src.get_path().c_str());
dbg_trace();
}
+Sound::~Sound() { dbg_trace(); }
void Sound::play() {
SoundContext & ctx = this->context.get();
@@ -52,3 +53,7 @@ void Sound::set_looping(bool looping) {
ctx.engine.setLooping(this->handle, this->looping);
}
+void Sound::set_context(SoundContext & ctx) {
+ this->context = ctx;
+}
+