diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2005-06-23 23:33:34 +0000 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2005-06-23 23:33:34 +0000 |
commit | 4b0172d1f666a12cffbdd6bd331e95a92d8f652f (patch) | |
tree | dde7ab71fd5d02200be35e041b00e5649f9cd3a8 /src/resources/music.cpp | |
parent | 33587089cf7d87bbc2104e80746fdddc7a5498e1 (diff) | |
download | mana-4b0172d1f666a12cffbdd6bd331e95a92d8f652f.tar.gz mana-4b0172d1f666a12cffbdd6bd331e95a92d8f652f.tar.bz2 mana-4b0172d1f666a12cffbdd6bd331e95a92d8f652f.tar.xz mana-4b0172d1f666a12cffbdd6bd331e95a92d8f652f.zip |
Finishing resource manager ability to clean up resources. Still work to do on
resources other than images.
Diffstat (limited to 'src/resources/music.cpp')
-rw-r--r-- | src/resources/music.cpp | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/src/resources/music.cpp b/src/resources/music.cpp index 7c353f03..6b41dd76 100644 --- a/src/resources/music.cpp +++ b/src/resources/music.cpp @@ -32,7 +32,9 @@ Music::Music(Mix_Chunk *music): Music::~Music() { - unload(); + //Mix_FreeMusic(music); + Mix_FreeChunk(music); + music = NULL; } Music* Music::load(void* buffer, unsigned int bufferSize) @@ -50,14 +52,6 @@ Music* Music::load(void* buffer, unsigned int bufferSize) return new Music(tmpMusic); } -void Music::unload() -{ - //Mix_FreeMusic(music); - Mix_FreeChunk(music); - music = NULL; - loaded = false; -} - bool Music::play(int loops) { /* |