|
PortAudio
2.0
|
Public Member Functions | |
| native int | getReadAvailable () |
| native int | getWriteAvailable () |
| boolean | read (float[] buffer, int numFrames) |
| boolean | write (float[] buffer, int numFrames) |
| boolean | read (short[] buffer, int numFrames) |
| boolean | write (short[] buffer, int numFrames) |
| native void | start () |
| native void | stop () |
| native void | abort () |
| native void | close () |
| native boolean | isStopped () |
| native boolean | isActive () |
| String | toString () |
| native double | getTime () |
| StreamInfo | getInfo () |
Represents a stream for blocking read/write I/O.
This Java object contains the pointer to a PortAudio stream stored as a long. It is passed to PortAudio when calling stream related functions.
To create one of these, call PortAudio.openStream().
Definition at line 59 of file BlockingStream.java.
| native void com.portaudio.BlockingStream.abort | ( | ) |
Stop immediately and lose any data that was written but not played.
| native void com.portaudio.BlockingStream.close | ( | ) |
Close the stream and zero out the pointer. Do not reference the stream after this.
| native int com.portaudio.BlockingStream.getReadAvailable | ( | ) |
| native double com.portaudio.BlockingStream.getTime | ( | ) |
Get audio time related to this stream. Note that it may not start at 0.0.
| native int com.portaudio.BlockingStream.getWriteAvailable | ( | ) |
|
inline |
Read 32-bit floating point data from the stream into the array.
| buffer | |
| numFrames | number of frames to read |
Definition at line 93 of file BlockingStream.java.
References com.portaudio.PortAudio.FORMAT_FLOAT_32.
|
inline |
Read 16-bit integer data to the stream from the array.
| buffer | |
| numFrames | number of frames to write |
Definition at line 134 of file BlockingStream.java.
| native void com.portaudio.BlockingStream.start | ( | ) |
Atart audio I/O.
| native void com.portaudio.BlockingStream.stop | ( | ) |
Wait for the stream to play all of the data that has been written then stop.
|
inline |
Write 32-bit floating point data to the stream from the array. The data should be in the range -1.0 to +1.0.
| buffer | |
| numFrames | number of frames to write |
Definition at line 112 of file BlockingStream.java.
References com.portaudio.PortAudio.FORMAT_FLOAT_32.
|
inline |
Write 16-bit integer data to the stream from the array.
| buffer | |
| numFrames | number of frames to write |
Definition at line 152 of file BlockingStream.java.
1.8.5