Music during program
Ok so I am wondering how to make a song play during my program. I am aware that I must compile the song and the .wav file together (link them may be the more appropriate term) but I am wondering if I must use something like fpmuisc=fopen("music.wav","r"); How do I let the program know when to start playing the music I guess.
Well we could "guess" at your operating system and compiler, or you could tell us.
I mean, if you're writing a win32 program using any half-decent win32 compiler, then it's as simple as falling off a log.
Sorry about that. Its a win32 program and I am using the bcc32 compiler to link them into an executable file
When I try to compile I get an error that it cant read the .wav file. Is there something special I have to put in for the program to use the music. I am trying the PlaySound function as described above.
Was the wav file in the same directory as
- the exe file
- the source file
- the project root
Did you specify an absolute or relative path name?
What is the effective "current directory" if you specified a relative path?