Further tweakage
This commit is contained in:
parent
3399b6409e
commit
df1c875ff4
|
@ -127,29 +127,26 @@ public final class AL {
|
|||
AL10.initNativeStubs();
|
||||
ALC.initNativeStubs();
|
||||
|
||||
device = ALC.alcOpenDevice(deviceArguments);
|
||||
if (device == null)
|
||||
throw new LWJGLException("Could not open ALC device");
|
||||
|
||||
AL.deviceArguments = deviceArguments;
|
||||
AL.contextFrequency = contextFrequency;
|
||||
AL.contextRefresh = contextRefresh;
|
||||
AL.contextSynchronized = contextSynchronized ? ALC.ALC_TRUE : ALC.ALC_FALSE;
|
||||
|
||||
if (contextFrequency == -1) {
|
||||
device = ALC.alcOpenDevice(deviceArguments);
|
||||
if (device == null)
|
||||
throw new LWJGLException("Could not open ALC device");
|
||||
|
||||
if (AL.contextFrequency == -1) {
|
||||
context = ALC.alcCreateContext(device.device, null);
|
||||
} else {
|
||||
context = ALC.alcCreateContext(device.device,
|
||||
ALCcontext.createAttributeList(AL.contextFrequency, AL.contextRefresh, AL.contextSynchronized));
|
||||
}
|
||||
ALC.alcMakeContextCurrent(context.context);
|
||||
created = true;
|
||||
} catch (LWJGLException e) {
|
||||
destroy();
|
||||
throw e;
|
||||
}
|
||||
|
||||
create();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue