How to play .WAV files

Dear Team Basic,

I would like to create an executable to which the name of a .wav file could be passed as an argument, so that when chained to, the .wav file would begin to play, but that execution by the calling program would be immediately resumed. Further, that upon a subsequent chain/call, the previously playing .wav, if still sounding, is stopped and the sounding of the new .wav is commenced.

The TB Gold manual has a vague paragraph or two of instructions on how to play a .wav file using "tbplysnd.c", provided one is familiar enough with C or C++ or Visual Basic or whatever to write the code, compile it as a DLL, and so on. If I knew how to do all that I would probably be using one of those languages, rather than good ol' TRUE Basic.

Any help would be greatly appreciated.

Regards,
Mike C.

Comments

wave files

It has been on the wish list for over a decade that there be TrueBasic commands that would play modern sound files, through the sound cards. Some preliminary attempts were made (I was marginally involved) to get a C-program written and then turned into a library routine. That didn't work well. So..until that day comes when the language gets updated (out of the 70s), we are stuck with either chaining to an external program that can play sound/music files (done that) or live with the squeeky sounds of the internal speaker (if you even have an internal speaker). This is my understanding of the current sound capabilities of TB--would be happy to be proved wrong.

rwt