35package com.jogamp.openal.sound3d;
37import com.jogamp.openal.AL;
38import com.jogamp.openal.ALConstants;
39import java.nio.ByteBuffer;
57 private int alBufferID;
58 private ByteBuffer data;
61 this.alBufferID = bufferID;
65 public int getID() {
return alBufferID; }
77 if( 0 <= alBufferID ) {
91 public void configure(
final ByteBuffer data,
final int alFormat,
final int freq) {
102 final int[] i =
new int[1];
114 final int[] i =
new int[1];
135 final int[] i =
new int[1];
147 final int[] i =
new int[1];
155 return "ALBuffer[id "+alBufferID+
"]";
The AudioSystem3D class provides a set of methods for creating and manipulating a 3D audio environmen...
The Sound3D Buffer is a container for audio data used in the Sound3D environment.
ByteBuffer getData()
Gets the raw data contained in this buffer.
void delete()
Delete this buffer, and free its resources.
int getBitDepth()
Get the bit-depth of the data, (8 or 16)
int getNumChannels()
Get the number of channels of the data (1-Mono, 2-Stereo)
static final int FORMAT_MONO8
static final int FORMAT_MONO16
static final int FORMAT_STEREO8
boolean isValid()
Returns whether getID() is valid, i.e.
int getID()
Return the OpenAL buffer ID, -1 if invalid.
int getFrequency()
Gets the audio frequency of the data contained in this buffer.
int getSize()
Gets the size (in bytes) of the raw data containe in this buffer.
void configure(final ByteBuffer data, final int alFormat, final int freq)
Configure the Sound3D buffer.
static final int FORMAT_STEREO16
Buffer(final int bufferID)
static final int AL_CHANNELS
Define "AL_CHANNELS" with expression '0x2003', CType: int.
static final int AL_BITS
Define "AL_BITS" with expression '0x2002', CType: int.
static final int AL_FREQUENCY
Define "AL_FREQUENCY" with expression '0x2001', CType: int.
static final int AL_FORMAT_MONO8
Define "AL_FORMAT_MONO8" with expression '0x1100', CType: int.
static final int AL_SIZE
Define "AL_SIZE" with expression '0x2004', CType: int.
static final int AL_FORMAT_STEREO16
Define "AL_FORMAT_STEREO16" with expression '0x1103', CType: int.
static final int AL_FORMAT_STEREO8
Define "AL_FORMAT_STEREO8" with expression '0x1102', CType: int.
static final int AL_FORMAT_MONO16
Define "AL_FORMAT_MONO16" with expression '0x1101', CType: int.
void alBufferData(int buffer, int format, Buffer data, int size, int samplerate)
Entry point (through function pointer) to C language function: void alBufferData(ALuint buffer,...
boolean alIsBuffer(int buffer)
Entry point (through function pointer) to C language function: ALboolean alIsBuffer(ALuint buffer)
void alGetBufferi(int buffer, int param, IntBuffer value)
Entry point (through function pointer) to C language function: void alGetBufferi(ALuint buffer,...
void alDeleteBuffers(int n, IntBuffer buffers)
Entry point (through function pointer) to C language function: void alDeleteBuffers(ALsizei n,...