Maybe try adding this 1 line of code under the comment.
// File writer code here
System.out.println(tempBuffer[counter]);
Type: Posts; User: JavaPF
Maybe try adding this 1 line of code under the comment.
// File writer code here
System.out.println(tempBuffer[counter]);
The code I provided is copying the contents of the array to the text file at the same time as recording.
I don't have a microphone so I will never be able to tell if the output is correct. I...
We could try:
/*File AudioCapture01.java
This program demonstrates the capture
and subsequent playback of audio data.
A GUI appears on the screen containing
the following buttons:
It looks like the data is stored in the tempBuffer[] array. You can add the file writing code here in the CaptureThread thread:
/*File AudioCapture01.java
This program demonstrates the capture
...
Yes that is the output String.
I'll take a look at the source on that web page and see what I can come up with.
Hello bondage, welcome to the forums.
This link should help you with writing to a text file: http://www.javaprogrammingforums.com/java-code-snippets-tutorials/107-how-write-file-using-java.html