diff options
Diffstat (limited to 'src/music/dmusic.cpp')
-rw-r--r-- | src/music/dmusic.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/music/dmusic.cpp b/src/music/dmusic.cpp index 934bb9fe2..b874924f2 100644 --- a/src/music/dmusic.cpp +++ b/src/music/dmusic.cpp @@ -21,6 +21,7 @@ #include "../core/mem_func.hpp" #include "../thread/thread.h" #include "../fileio_func.h" +#include "../base_media_base.h" #include "dmusic.h" #include "midifile.hpp" #include "midi.h" @@ -1225,11 +1226,13 @@ void MusicDriver_DMusic::Stop() } -void MusicDriver_DMusic::PlaySong(const char *filename) +void MusicDriver_DMusic::PlaySong(const MusicSongInfo &song) { + if (song.filetype != MTT_STANDARDMIDI) return; + ThreadMutexLocker lock(_thread_mutex); - _playback.next_file.LoadFile(filename); + _playback.next_file.LoadFile(song.filename); _playback.next_segment.start = 0; _playback.next_segment.end = 0; _playback.next_segment.loop = false; |