Wav files and winbase.h
I'm in trouble again with my c program. I need to play wav files. I searched the old posts and all I could find was about sndPlaySound. If I use it, my compiler tells me: missing prototype. If I include windows.h, the compiler tells me there are errors in the winbase.h file. It's not a file written by me, then I guess it is correct. Should I include something else?
Thank you all in advance! This is for my job, it's very important!
Thank you again very much!
my favourite audio lib
very simple to use.
Make sure you have included <windows.h> before other headers. You can also use the PlaySound function. You will need to link with Winmm.lib.
Thank you very much everybody!!!
I have included windows.h, but it is my last header, actually! I'll try moving it up. And I'll try fmod too.
Thank you a lot again, this forum is a very welcoming place, not to mention a very useful resource! Thank you all!
I followed your advice: with fmod everything worked perfectly. WIth windows.h as my first include, compiling was successful, but I had a "linking error": symbol sndSoundPlayA@8 undefined.
I don't know what this means. Anyway fmod is more powerful, it even lets me pre-load my samples and then quickly play them whenever I need to warn the user of my app.
Thank you very much again!
PS: i tried to edit my first post and add "SOLVED" to the title, but i couldn't. "Edit" appears on my last post only.
Thank you again, bye!
No problem. Fmod is quite powerful and it is ported to many many OS's including Xbox and PS2 i believe.