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 () |
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 int com::portaudio::BlockingStream::getReadAvailable | ( | ) |
native int com::portaudio::BlockingStream::getWriteAvailable | ( | ) |
boolean com::portaudio::BlockingStream::read | ( | float[] | buffer, | |
int | numFrames | |||
) | [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.
boolean com::portaudio::BlockingStream::write | ( | float[] | buffer, | |
int | numFrames | |||
) | [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.
boolean com::portaudio::BlockingStream::read | ( | short[] | buffer, | |
int | numFrames | |||
) | [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.
boolean com::portaudio::BlockingStream::write | ( | short[] | buffer, | |
int | numFrames | |||
) | [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.
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.
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 double com::portaudio::BlockingStream::getTime | ( | ) |
Get audio time related to this stream. Note that it may not start at 0.0.