|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jogamp.openal.util.WAVData
public final class WAVData
This class is a holder for WAV (.wav ) file Data returned from the WavLoader,
or directly via #loadFromStream(InputStream, int, int, int)
.
Field Summary | |
---|---|
ByteBuffer |
data
The audio data |
int |
format
the format of the Data. |
int |
freq
The frequency of the data |
boolean |
loop
flag indicating whether or not the sound in the data should loop |
int |
size
Size (in bytes) of the data |
Constructor Summary | |
---|---|
WAVData(ByteBuffer data,
int format,
int size,
int freq,
boolean loop)
|
Method Summary | |
---|---|
static WAVData |
loadFromStream(InputStream aIn,
int initialCapacity,
int numChannels,
int bits,
int sampleRate,
ByteOrder byteOrder,
boolean loop)
This method loads a (.wav) file into a WAVData object. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public final ByteBuffer data
public final int format
AL.AL_FORMAT_MONO8 AL.AL_FORMAT_MONO16 AL.AL_FORMAT_STEREO8 AL.AL_FORMAT_STEREO16
public final int size
public final int freq
public final boolean loop
Constructor Detail |
---|
public WAVData(ByteBuffer data, int format, int size, int freq, boolean loop)
Method Detail |
---|
public static WAVData loadFromStream(InputStream aIn, int initialCapacity, int numChannels, int bits, int sampleRate, ByteOrder byteOrder, boolean loop) throws IOException
initialCapacity
- initial buffer capacity in bytes, if > available bytesnumChannels
- bits
- sampleRate
- byteOrder
- stream
- An InputStream for the .WAV stream
UnsupportedAudioFileException
- if the format of the audio if not
supported.
IOException
- If the file can no be found or some other IO error
occurs
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |