asap.getWavHeader(buffer, format);
os.write(buffer, 0, ASAP.WAV_HEADER_BYTES);
}
int n_bytes;
do {
n_bytes = asap.generate(buffer, format);
os.write(buffer, 0, n_bytes);
} while (n_bytes == buffer.length);
os.close();
outputFilename = null;
song = -1;