If I do this

read( sd, inbuffer, BUFSIZE);

for( i=0;i<BUFSIZE;i++) {
leftBuf=(inbuffer[2*i] * gain);

}

would I do this?
write( file_d, leftBuf, BUFSIZE/2);

to write a mono file?

Some code I am working with does this.

read( sd, inbuffer, BUFSIZE*2)/2;

What would be the advantage of doing this?

thanks-
ljp

Reply via email to