diff --git a/SDLWrapper/Music.cpp b/SDLWrapper/Music.cpp index 0fd8a41..8e9410b 100644 --- a/SDLWrapper/Music.cpp +++ b/SDLWrapper/Music.cpp @@ -37,6 +37,11 @@ void Music::release() _clear(); } +MusicType Music::getType() const +{ + return _internal::getMusicTypeFromMixMusicType(Mix_GetMusicType(_get())); +} + //static int MusicPlayer::GetDecoderNum() { @@ -75,6 +80,12 @@ int MusicPlayer::stop() return Mix_HaltMusic(); } +int MusicPlayer::fadeIn(Music music, int loops, int ms) +{ + m=music; + return fadeIn(loops,ms); +} + int MusicPlayer::fadeIn(int loops, int ms) { return Mix_FadeInMusic(m._get(), loops, ms); diff --git a/SDLWrapper/Music.h b/SDLWrapper/Music.h index e5cbc1e..1d870a6 100644 --- a/SDLWrapper/Music.h +++ b/SDLWrapper/Music.h @@ -42,6 +42,7 @@ public: void rewind(); int setPosition(double second); int stop(); + int fadeIn(Music music,int loops,int ms); int fadeIn(int loops, int ms); int fadeOut(int ms);