@Override public void createALC() { device = ALC10.alcOpenDevice((ByteBuffer) null); ALCCapabilities deviceCaps = ALC.createCapabilities(device); context = ALC10.alcCreateContext(device, (IntBuffer) null); ALC10.alcMakeContextCurrent(context); AL.createCapabilities(deviceCaps); }
/** Returns the {@link FunctionProviderLocal} for the OpenAL native library. */ public static FunctionProviderLocal getFunctionProvider() { return check(ALC.functionProvider); }
/** Loads the OpenAL native library, using the default library name. */ public static void create() { String libName; switch (Platform.get()) { case LINUX: case MACOSX: libName = "openal"; break; case WINDOWS: libName = "OpenAL"; break; default: throw new IllegalStateException(); } create(Configuration.OPENAL_LIBRARY_NAME.get(Platform.mapLibraryNameBundled(libName))); }
static void init() { functionProvider = new FunctionProvider() { // We'll use alGetProcAddress for both core and extension entry points. // To do that, we need to first grab the alGetProcAddress function from // the OpenAL native library. private final long alGetProcAddress = ALC.getFunctionProvider().getFunctionAddress("alGetProcAddress"); @Override public long getFunctionAddress(ByteBuffer functionName) { long address = invokePP(alGetProcAddress, memAddress(functionName)); if (address == NULL && Checks.DEBUG_FUNCTIONS) { apiLog("Failed to locate address for AL function " + memASCII(functionName)); } return address; } }; }
/** Returns the {@link ALCCapabilities} of the OpenAL implementation. */ static ALCCapabilities getICD() { return check(icd); }
/** * Loads the OpenAL native library, using the specified library name. * * @param libName the native library name */ public static void create(String libName) { SharedLibrary OPENAL = Library.loadNative(ALC.class, libName, true); try { create(new SharedLibraryAL(OPENAL)); } catch (RuntimeException e) { OPENAL.free(); throw e; } }
FunctionProviderLocal functionProvider = getFunctionProvider();
return; ALCCapabilities deviceCapabilities = ALC.createCapabilities(device); context = alcCreateContext(device, (IntBuffer)null); if (context == 0L) {
static ALCapabilities getICD() { return ALC.check(icd.get()); }
return; ALCCapabilities deviceCapabilities = ALC.createCapabilities(device); context = alcCreateContext(device, (IntBuffer)null); if (context == 0L) {
FunctionProvider functionProvider = ALC.check(AL.functionProvider);
public void init() throws Exception { this.device = alcOpenDevice((ByteBuffer) null); if (device == NULL) { throw new IllegalStateException("Failed to open the default OpenAL device."); } ALCCapabilities deviceCaps = ALC.createCapabilities(device); this.context = alcCreateContext(device, (IntBuffer) null); if (context == NULL) { throw new IllegalStateException("Failed to create OpenAL context."); } alcMakeContextCurrent(context); AL.createCapabilities(deviceCaps); }
public void init() throws Exception { this.device = alcOpenDevice((ByteBuffer) null); if (device == NULL) { throw new IllegalStateException("Failed to open the default OpenAL device."); } ALCCapabilities deviceCaps = ALC.createCapabilities(device); this.context = alcCreateContext(device, (IntBuffer) null); if (context == NULL) { throw new IllegalStateException("Failed to create OpenAL context."); } alcMakeContextCurrent(context); AL.createCapabilities(deviceCaps); }
public void init() throws Exception { this.device = alcOpenDevice((ByteBuffer) null); if (device == NULL) { throw new IllegalStateException("Failed to open the default OpenAL device."); } ALCCapabilities deviceCaps = ALC.createCapabilities(device); this.context = alcCreateContext(device, (IntBuffer) null); if (context == NULL) { throw new IllegalStateException("Failed to create OpenAL context."); } alcMakeContextCurrent(context); AL.createCapabilities(deviceCaps); }
public void init() throws Exception { this.device = alcOpenDevice((ByteBuffer) null); if (device == NULL) { throw new IllegalStateException("Failed to open the default OpenAL device."); } ALCCapabilities deviceCaps = ALC.createCapabilities(device); this.context = alcCreateContext(device, (IntBuffer) null); if (context == NULL) { throw new IllegalStateException("Failed to create OpenAL context."); } alcMakeContextCurrent(context); AL.createCapabilities(deviceCaps); }
public void init() throws Exception { this.device = alcOpenDevice((ByteBuffer) null); if (device == NULL) { throw new IllegalStateException("Failed to open the default OpenAL device."); } ALCCapabilities deviceCaps = ALC.createCapabilities(device); this.context = alcCreateContext(device, (IntBuffer) null); if (context == NULL) { throw new IllegalStateException("Failed to create OpenAL context."); } alcMakeContextCurrent(context); AL.createCapabilities(deviceCaps); }
public void init() throws Exception { this.device = alcOpenDevice((ByteBuffer) null); if (device == NULL) { throw new IllegalStateException("Failed to open the default OpenAL device."); } ALCCapabilities deviceCaps = ALC.createCapabilities(device); this.context = alcCreateContext(device, (IntBuffer) null); if (context == NULL) { throw new IllegalStateException("Failed to create OpenAL context."); } alcMakeContextCurrent(context); AL.createCapabilities(deviceCaps); }
public void init() throws Exception { this.device = alcOpenDevice((ByteBuffer) null); if (device == NULL) { throw new IllegalStateException("Failed to open the default OpenAL device."); } ALCCapabilities deviceCaps = ALC.createCapabilities(device); this.context = alcCreateContext(device, (IntBuffer) null); if (context == NULL) { throw new IllegalStateException("Failed to create OpenAL context."); } alcMakeContextCurrent(context); AL.createCapabilities(deviceCaps); }
public void init() throws Exception { this.device = alcOpenDevice((ByteBuffer) null); if (device == NULL) { throw new IllegalStateException("Failed to open the default OpenAL device."); } ALCCapabilities deviceCaps = ALC.createCapabilities(device); this.context = alcCreateContext(device, (IntBuffer) null); if (context == NULL) { throw new IllegalStateException("Failed to create OpenAL context."); } alcMakeContextCurrent(context); AL.createCapabilities(deviceCaps); }
public void init() throws Exception { this.device = alcOpenDevice((ByteBuffer) null); if (device == NULL) { throw new IllegalStateException("Failed to open the default OpenAL device."); } ALCCapabilities deviceCaps = ALC.createCapabilities(device); this.context = alcCreateContext(device, (IntBuffer) null); if (context == NULL) { throw new IllegalStateException("Failed to create OpenAL context."); } alcMakeContextCurrent(context); AL.createCapabilities(deviceCaps); }