BASSMOD
BASSMOD is a MOD only (XM, IT, S3M, MOD, MTM, UMX) version of BASS - useful for demos, or anything else where you want to play some MOD music.
Website: http://www.un4seen.com/bassmod.html
Platforms supported: Win32, Linux
Headers to include: bassmod.bi
Header version: 2.0
Examples: in examples/sound/BASS/
Website: http://www.un4seen.com/bassmod.html
Platforms supported: Win32, Linux
Headers to include: bassmod.bi
Header version: 2.0
Examples: in examples/sound/BASS/
Example
#include once "bassmod.bi"
Const SOUND_FILE = "test.mod"
If (BASSMOD_GetVersion() < 2) Then
Print "BASSMOD version 2 or above required!"
End 1
End If
If (BASSMOD_Init(-1, 44100, 0) = 0) Then
Print "Could not initialize BASSMOD"
End 1
End If
If (BASSMOD_MusicLoad(FALSE, SOUND_FILE, 0, 0, BASS_MUSIC_LOOP) = 0) Then
Print "BASSMOD could not load '" & SOUND_FILE & "'"
BASSMOD_Free()
End 1
End If
BASSMOD_MusicPlay()
Print "Sound playing; waiting for keypress to stop and exit..."
Sleep
BASSMOD_MusicStop()
BASSMOD_MusicFree()
BASSMOD_Free()
Const SOUND_FILE = "test.mod"
If (BASSMOD_GetVersion() < 2) Then
Print "BASSMOD version 2 or above required!"
End 1
End If
If (BASSMOD_Init(-1, 44100, 0) = 0) Then
Print "Could not initialize BASSMOD"
End 1
End If
If (BASSMOD_MusicLoad(FALSE, SOUND_FILE, 0, 0, BASS_MUSIC_LOOP) = 0) Then
Print "BASSMOD could not load '" & SOUND_FILE & "'"
BASSMOD_Free()
End 1
End If
BASSMOD_MusicPlay()
Print "Sound playing; waiting for keypress to stop and exit..."
Sleep
BASSMOD_MusicStop()
BASSMOD_MusicFree()
BASSMOD_Free()