public class ALC10
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static int |
ALC_ALL_ATTRIBUTES
Integer queries.
|
static int |
ALC_ATTRIBUTES_SIZE
Integer queries.
|
static int |
ALC_DEFAULT_DEVICE_SPECIFIER
String queries.
|
static int |
ALC_DEVICE_SPECIFIER
String queries.
|
static int |
ALC_EXTENSIONS
String queries.
|
static int |
ALC_FALSE
General tokens.
|
static int |
ALC_FREQUENCY
Context creation attributes.
|
static int |
ALC_INVALID
General tokens.
|
static int |
ALC_INVALID_CONTEXT
Error conditions.
|
static int |
ALC_INVALID_DEVICE
Error conditions.
|
static int |
ALC_INVALID_ENUM
Error conditions.
|
static int |
ALC_INVALID_VALUE
Error conditions.
|
static int |
ALC_MAJOR_VERSION
Integer queries.
|
static int |
ALC_MINOR_VERSION
Integer queries.
|
static int |
ALC_NO_ERROR
Error conditions.
|
static int |
ALC_OUT_OF_MEMORY
Error conditions.
|
static int |
ALC_REFRESH
Context creation attributes.
|
static int |
ALC_SYNC
Context creation attributes.
|
static int |
ALC_TRUE
General tokens.
|
| Modifier and Type | Method and Description |
|---|---|
static boolean |
alcCloseDevice(long deviceHandle)
Allows the application to disconnect from a device.
|
static long |
alcCreateContext(long deviceHandle,
int[] attrList)
Array version of:
CreateContext |
static long |
alcCreateContext(long deviceHandle,
java.nio.IntBuffer attrList)
Creates an AL context.
|
static void |
alcDestroyContext(long context)
Destroys a context.
|
static long |
alcGetContextsDevice(long context)
Queries for, and obtains a handle to, the device of a given context.
|
static long |
alcGetCurrentContext()
Queries for, and obtains a handle to, the current context for the application.
|
static int |
alcGetEnumValue(long deviceHandle,
java.nio.ByteBuffer enumName)
Returns extension enum values.
|
static int |
alcGetEnumValue(long deviceHandle,
java.lang.CharSequence enumName)
Returns extension enum values.
|
static int |
alcGetError(long deviceHandle)
Queries ALC errors.
|
static int |
alcGetInteger(long deviceHandle,
int token)
Obtains integer value(s) from ALC.
|
static void |
alcGetIntegerv(long deviceHandle,
int token,
int[] dest)
Array version of:
GetIntegerv |
static void |
alcGetIntegerv(long deviceHandle,
int token,
java.nio.IntBuffer dest)
Obtains integer value(s) from ALC.
|
static long |
alcGetProcAddress(long deviceHandle,
java.nio.ByteBuffer funcName)
Retrieves extension entry points.
|
static long |
alcGetProcAddress(long deviceHandle,
java.lang.CharSequence funcName)
Retrieves extension entry points.
|
static java.lang.String |
alcGetString(long deviceHandle,
int token)
Obtains string value(s) from ALC.
|
static boolean |
alcIsExtensionPresent(long deviceHandle,
java.nio.ByteBuffer extName)
Verifies that a given extension is available for the current context and the device it is associated with.
|
static boolean |
alcIsExtensionPresent(long deviceHandle,
java.lang.CharSequence extName)
Verifies that a given extension is available for the current context and the device it is associated with.
|
static boolean |
alcMakeContextCurrent(long context)
Makes a context current with respect to OpenAL operation.
|
static long |
alcOpenDevice(java.nio.ByteBuffer deviceSpecifier)
Allows the application to connect to a device.
|
static long |
alcOpenDevice(java.lang.CharSequence deviceSpecifier)
Allows the application to connect to a device.
|
static void |
alcProcessContext(long context)
The current context is the only context accessible to state changes by AL commands (aside from state changes affecting shared objects).
|
static void |
alcSuspendContext(long context)
The application can suspend any context from processing (including the current one).
|
static long |
nalcCreateContext(long deviceHandle,
long attrList)
Unsafe version of:
CreateContext |
static int |
nalcGetEnumValue(long deviceHandle,
long enumName)
Unsafe version of:
GetEnumValue |
static void |
nalcGetIntegerv(long deviceHandle,
int token,
int size,
long dest)
Unsafe version of:
GetIntegerv |
static long |
nalcGetProcAddress(long deviceHandle,
long funcName)
Unsafe version of:
GetProcAddress |
static long |
nalcGetString(long deviceHandle,
int token)
Unsafe version of:
GetString |
static boolean |
nalcIsExtensionPresent(long deviceHandle,
long extName)
Unsafe version of:
IsExtensionPresent |
static long |
nalcOpenDevice(long deviceSpecifier)
Unsafe version of:
OpenDevice |
public static final int ALC_INVALID
public static final int ALC_FALSE
public static final int ALC_TRUE
public static final int ALC_FREQUENCY
public static final int ALC_REFRESH
public static final int ALC_SYNC
public static final int ALC_NO_ERROR
public static final int ALC_INVALID_DEVICE
public static final int ALC_INVALID_CONTEXT
public static final int ALC_INVALID_ENUM
public static final int ALC_INVALID_VALUE
public static final int ALC_OUT_OF_MEMORY
public static final int ALC_DEFAULT_DEVICE_SPECIFIER
public static final int ALC_DEVICE_SPECIFIER
public static final int ALC_EXTENSIONS
public static final int ALC_MAJOR_VERSION
public static final int ALC_MINOR_VERSION
public static final int ALC_ATTRIBUTES_SIZE
public static final int ALC_ALL_ATTRIBUTES
public static long nalcOpenDevice(long deviceSpecifier)
OpenDevicepublic static long alcOpenDevice(@Nullable
java.nio.ByteBuffer deviceSpecifier)
If the function returns NULL, then no sound driver/device has been found. The argument is a null terminated string that requests a certain device or
device configuration. If NULL is specified, the implementation will provide an implementation specific default.
deviceSpecifier - the requested device or device configurationpublic static long alcOpenDevice(@Nullable
java.lang.CharSequence deviceSpecifier)
If the function returns NULL, then no sound driver/device has been found. The argument is a null terminated string that requests a certain device or
device configuration. If NULL is specified, the implementation will provide an implementation specific default.
deviceSpecifier - the requested device or device configurationpublic static boolean alcCloseDevice(long deviceHandle)
The return code will be ALC_TRUE or ALC_FALSE, indicating success or failure. Failure will occur if all the device's contexts and buffers have not been
destroyed. Once closed, the deviceHandle is invalid.
deviceHandle - the device to closepublic static long nalcCreateContext(long deviceHandle,
long attrList)
CreateContextpublic static long alcCreateContext(long deviceHandle,
@Nullable
java.nio.IntBuffer attrList)
deviceHandle - a valid deviceattrList - null or a zero terminated list of integer pairs composed of valid ALC attribute tokens and requested values. One of:FREQUENCY | REFRESH | SYNC | MONO_SOURCES | STEREO_SOURCES |
public static boolean alcMakeContextCurrent(long context)
The context parameter can be NULL or a valid context pointer. Using NULL results in no context being current, which is useful when shutting OpenAL down.
The operation will apply to the device that the context was created for.
For each OS process (usually this means for each application), only one context can be current at any given time. All AL commands apply to the current context. Commands that affect objects shared among contexts (e.g. buffers) have side effects on other contexts.
context - the context to make currentpublic static void alcProcessContext(long context)
alcProcessContext.
Repeated calls to alcProcessContext are legal, and do not affect a context that is already marked as processing. The default state of a context created by alcCreateContext is that it is processing.
context - the context to mark for processingpublic static void alcSuspendContext(long context)
alcSuspendContext.
Repeated calls to alcSuspendContext are legal, and do not affect a context that is already marked as suspended.
context - the context to mark as suspendedpublic static void alcDestroyContext(long context)
The correct way to destroy a context is to first release it using alcMakeCurrent with a NULL context. Applications should not attempt to destroy a
current context – doing so will not work and will result in an ALC_INVALID_OPERATION error. All sources within a context will automatically be deleted
during context destruction.
context - the context to destroypublic static long alcGetCurrentContext()
NULL is returned.public static long alcGetContextsDevice(long context)
context - the context to querypublic static boolean nalcIsExtensionPresent(long deviceHandle,
long extName)
IsExtensionPresentpublic static boolean alcIsExtensionPresent(long deviceHandle,
java.nio.ByteBuffer extName)
Invalid and unsupported string tokens return ALC_FALSE. A NULL deviceHandle is acceptable. extName is not case sensitive – the implementation
will convert the name to all upper-case internally (and will express extension names in upper-case).
deviceHandle - the device to queryextName - the extension namepublic static boolean alcIsExtensionPresent(long deviceHandle,
java.lang.CharSequence extName)
Invalid and unsupported string tokens return ALC_FALSE. A NULL deviceHandle is acceptable. extName is not case sensitive – the implementation
will convert the name to all upper-case internally (and will express extension names in upper-case).
deviceHandle - the device to queryextName - the extension namepublic static long nalcGetProcAddress(long deviceHandle,
long funcName)
GetProcAddresspublic static long alcGetProcAddress(long deviceHandle,
java.nio.ByteBuffer funcName)
The application is expected to verify the applicability of an extension or core function entry point before requesting it by name, by use of
IsExtensionPresent.
Entry points can be device specific, but are not context specific. Using a NULL device handle does not guarantee that the entry point is returned,
even if available for one of the available devices.
deviceHandle - the device to queryfuncName - the function namepublic static long alcGetProcAddress(long deviceHandle,
java.lang.CharSequence funcName)
The application is expected to verify the applicability of an extension or core function entry point before requesting it by name, by use of
IsExtensionPresent.
Entry points can be device specific, but are not context specific. Using a NULL device handle does not guarantee that the entry point is returned,
even if available for one of the available devices.
deviceHandle - the device to queryfuncName - the function namepublic static int nalcGetEnumValue(long deviceHandle,
long enumName)
GetEnumValuepublic static int alcGetEnumValue(long deviceHandle,
java.nio.ByteBuffer enumName)
Enumeration/token values are device independent, but tokens defined for extensions might not be present for a given device. Using a NULL handle is
legal, but only the tokens defined by the AL core are guaranteed. Availability of extension tokens depends on the ALC extension.
deviceHandle - the device to queryenumName - the enum namepublic static int alcGetEnumValue(long deviceHandle,
java.lang.CharSequence enumName)
Enumeration/token values are device independent, but tokens defined for extensions might not be present for a given device. Using a NULL handle is
legal, but only the tokens defined by the AL core are guaranteed. Availability of extension tokens depends on the ALC extension.
deviceHandle - the device to queryenumName - the enum namepublic static int alcGetError(long deviceHandle)
ALC uses the same conventions and mechanisms as AL for error handling. In particular, ALC does not use conventions derived from X11 (GLX) or Windows (WGL).
Error conditions are specific to the device, and (like AL) a call to alcGetError resets the error state.
deviceHandle - the device to querypublic static long nalcGetString(long deviceHandle,
int token)
GetString@Nullable
public static java.lang.String alcGetString(long deviceHandle,
int token)
LWJGL note: Use ALUtil.getStringList(long, int) for those tokens that return multiple values.
deviceHandle - the device to querytoken - the information to query. One of:DEFAULT_DEVICE_SPECIFIER | DEVICE_SPECIFIER | EXTENSIONS |
CAPTURE_DEFAULT_DEVICE_SPECIFIER | CAPTURE_DEVICE_SPECIFIER |
public static void nalcGetIntegerv(long deviceHandle,
int token,
int size,
long dest)
GetIntegervsize - the size of the dest bufferpublic static void alcGetIntegerv(long deviceHandle,
int token,
java.nio.IntBuffer dest)
deviceHandle - the device to querytoken - the information to query. One of:MAJOR_VERSION | MINOR_VERSION | ATTRIBUTES_SIZE | ALL_ATTRIBUTES | CAPTURE_SAMPLES |
dest - the destination bufferpublic static int alcGetInteger(long deviceHandle,
int token)
deviceHandle - the device to querytoken - the information to query. One of:MAJOR_VERSION | MINOR_VERSION | ATTRIBUTES_SIZE | ALL_ATTRIBUTES | CAPTURE_SAMPLES |
public static long alcCreateContext(long deviceHandle,
@Nullable
int[] attrList)
CreateContextpublic static void alcGetIntegerv(long deviceHandle,
int token,
int[] dest)
GetIntegervCopyright LWJGL. All Rights Reserved. License terms.