Code:
output = (buffer[a] + output)/2;
This part I don't quite understand, the number of samples is 44100 a second, and at the moment it is a 10 second sine wave, and this can change....
output = (buffer[a] + output)/2;
int main() { //Create ne wav file CWavFile file; file.newWav(SR, 16, 1000, 1); float f = 10; //frequency float PIX2 = PI*2; float wave; float gain; int g = 0; float buffer[34]; //no. voices for(int a = 0; a < 34; a++) { gain = 1; for(int i = 0;
for(int i = 0; i < file.getNumSamples(); i++) {
Leave a comment: