DarkNess, in the code you posted where is the call to Mix_OpenAudio?

Also you are using mix_playmusic to play WAV files. I don't think that will work.