music¶
-
void kn::music::load(const std::string &fileDir)¶
Loads a music file.
- Parameters:
fileDir – The directory of the music file.
-
void kn::music::play(int loops = 0, int fadeMs = 0)¶
Plays the currently loaded music file.
- Parameters:
loops – The number of times to loop the music. -1 loops forever.
fadeMs – The number of milliseconds to fade in the music.
-
void kn::music::fadeOut(int fadeMs)¶
Fades out the currently loaded music file to the a stop.
- Parameters:
fadeMs – The number of milliseconds to fade out the music.