Welcome To Snipplr
Everyone's Recent C Snippets Tagged file
- All /
- JavaScript /
- HTML /
- PHP /
- CSS /
- Ruby /
- Objective C
« Prev 1 Next »
Makes a mono 8-bit (i.e. one byte per sample) wav file, "out.wav" containing a 500 Hertz sine wave signal. 22050 is the sample rate, and 64000 is the total size of audio data in bytes.
1
653
posted 14 years ago by Zufolek
loadfile(filename);
returns NULL on fail or a pointer that should be free()d when no longer needed.
savefile(filename,data,dataSize);
returns 0 on fail or 1 on success.
0
663
posted 14 years ago by Zufolek
« Prev 1 Next »