You can subscribe to this list here.
| 2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(134) |
Sep
(52) |
Oct
(13) |
Nov
(342) |
Dec
(163) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2003 |
Jan
(44) |
Feb
(62) |
Mar
(158) |
Apr
(38) |
May
(70) |
Jun
(58) |
Jul
(104) |
Aug
(207) |
Sep
(83) |
Oct
(122) |
Nov
(23) |
Dec
(49) |
| 2004 |
Jan
(119) |
Feb
(132) |
Mar
(192) |
Apr
(140) |
May
(77) |
Jun
(74) |
Jul
(201) |
Aug
(63) |
Sep
(102) |
Oct
(70) |
Nov
(173) |
Dec
(78) |
| 2005 |
Jan
(174) |
Feb
(197) |
Mar
(105) |
Apr
(59) |
May
(77) |
Jun
(43) |
Jul
(21) |
Aug
(18) |
Sep
(47) |
Oct
(37) |
Nov
(74) |
Dec
(50) |
| 2006 |
Jan
(44) |
Feb
(19) |
Mar
(32) |
Apr
(24) |
May
(31) |
Jun
(55) |
Jul
(138) |
Aug
(28) |
Sep
(12) |
Oct
(41) |
Nov
(58) |
Dec
(24) |
| 2007 |
Jan
(28) |
Feb
(14) |
Mar
(10) |
Apr
(68) |
May
(30) |
Jun
(26) |
Jul
(18) |
Aug
(63) |
Sep
(19) |
Oct
(29) |
Nov
(20) |
Dec
(10) |
| 2008 |
Jan
(38) |
Feb
(7) |
Mar
(37) |
Apr
(120) |
May
(41) |
Jun
(36) |
Jul
(39) |
Aug
(24) |
Sep
(28) |
Oct
(30) |
Nov
(36) |
Dec
(75) |
| 2009 |
Jan
(46) |
Feb
(22) |
Mar
(50) |
Apr
(70) |
May
(134) |
Jun
(105) |
Jul
(75) |
Aug
(34) |
Sep
(38) |
Oct
(34) |
Nov
(19) |
Dec
(20) |
| 2010 |
Jan
(11) |
Feb
(20) |
Mar
(65) |
Apr
(83) |
May
(104) |
Jun
(73) |
Jul
(78) |
Aug
(57) |
Sep
(43) |
Oct
(35) |
Nov
(9) |
Dec
(4) |
| 2011 |
Jan
(21) |
Feb
(11) |
Mar
(18) |
Apr
(10) |
May
(18) |
Jun
(15) |
Jul
(48) |
Aug
(25) |
Sep
(17) |
Oct
(45) |
Nov
(15) |
Dec
(12) |
| 2012 |
Jan
(21) |
Feb
(9) |
Mar
(12) |
Apr
(9) |
May
(9) |
Jun
(5) |
Jul
(1) |
Aug
(10) |
Sep
(12) |
Oct
(1) |
Nov
(28) |
Dec
(5) |
| 2013 |
Jan
(4) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2014 |
Jan
|
Feb
(1) |
Mar
(1) |
Apr
|
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
| 2015 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
|
Dec
|
| 2016 |
Jan
(2) |
Feb
(1) |
Mar
(1) |
Apr
(1) |
May
(2) |
Jun
|
Jul
(1) |
Aug
(2) |
Sep
|
Oct
|
Nov
(1) |
Dec
|
| 2017 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
1
|
2
|
3
|
4
(21) |
5
(8) |
6
|
7
(1) |
|
8
(24) |
9
|
10
(2) |
11
(1) |
12
(2) |
13
|
14
|
|
15
(25) |
16
(1) |
17
(8) |
18
(7) |
19
(2) |
20
|
21
|
|
22
|
23
(7) |
24
(6) |
25
(3) |
26
(8) |
27
(2) |
28
(1) |
|
29
(3) |
|
|
|
|
|
|
|
From: <ma...@us...> - 2004-02-26 22:28:29
|
Update of /cvsroot/java-game-lib/LWJGL/platform_build/win32_vs_net In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11463 Modified Files: lwjgl.vcproj lwjgl.suo Log Message: updated build file Index: lwjgl.vcproj =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/platform_build/win32_vs_net/lwjgl.vcproj,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- lwjgl.vcproj 24 Feb 2004 14:31:37 -0000 1.2 +++ lwjgl.vcproj 26 Feb 2004 22:12:25 -0000 1.3 @@ -144,19 +144,19 @@ RelativePath="..\..\src\native\common\extgl.cpp"> </File> <File - RelativePath="..\..\src\native\common\org_lwjgl_openal_ALC.cpp"> + RelativePath="..\..\src\native\common\org_lwjgl_openal_AL.cpp"> </File> <File - RelativePath="..\..\src\native\common\org_lwjgl_openal_BaseAL.cpp"> + RelativePath="..\..\src\native\common\org_lwjgl_openal_AL10.cpp"> </File> <File - RelativePath="..\..\src\native\common\org_lwjgl_openal_CoreAL.cpp"> + RelativePath="..\..\src\native\common\org_lwjgl_openal_ALC.cpp"> </File> <File - RelativePath="..\..\src\native\common\org_lwjgl_openal_eax_BaseEAX.cpp"> + RelativePath="..\..\src\native\common\org_lwjgl_openal_eax_EAX.cpp"> </File> <File - RelativePath="..\..\src\native\common\org_lwjgl_openal_eax_CoreEAX.cpp"> + RelativePath="..\..\src\native\common\org_lwjgl_openal_eax_EAX20.cpp"> </File> <File RelativePath="..\..\src\native\common\org_lwjgl_openal_eax_EAXBufferProperties.cpp"> @@ -179,6 +179,9 @@ <File RelativePath="..\..\src\native\common\org_lwjgl_opengl_GL15.cpp"> </File> + <File + RelativePath="..\..\src\native\common\org_lwjgl_opengl_GLContext.cpp"> + </File> </Filter> <Filter Name="win32" @@ -202,9 +205,6 @@ RelativePath="..\..\src\native\win32\org_lwjgl_input_Mouse.cpp"> </File> <File - RelativePath="..\..\src\native\common\org_lwjgl_opengl_GLContext.cpp"> - </File> - <File RelativePath="..\..\src\native\win32\org_lwjgl_opengl_Pbuffer.cpp"> </File> <File Index: lwjgl.suo =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/platform_build/win32_vs_net/lwjgl.suo,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 Binary files /tmp/cvsDTHBkj and /tmp/cvsPsNe7a differ |
Update of /cvsroot/java-game-lib/LWJGL/src/native/common In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6858 Modified Files: org_lwjgl_Display.h org_lwjgl_Sys.h org_lwjgl_input_Controller.h org_lwjgl_input_Cursor.h org_lwjgl_input_Keyboard.h org_lwjgl_input_Mouse.h org_lwjgl_openal_AL.h org_lwjgl_openal_AL10.h org_lwjgl_opengl_GL11.h org_lwjgl_opengl_GL12.h org_lwjgl_opengl_GL13.h org_lwjgl_opengl_GL14.h org_lwjgl_opengl_GL15.h org_lwjgl_opengl_GLContext.h Log Message: fresh headers Index: org_lwjgl_Display.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_Display.h,v retrieving revision 1.15 retrieving revision 1.16 diff -u -d -r1.15 -r1.16 --- org_lwjgl_Display.h 22 Oct 2003 18:34:42 -0000 1.15 +++ org_lwjgl_Display.h 26 Feb 2004 21:54:05 -0000 1.16 @@ -10,7 +10,6 @@ /* Inaccessible static: _00024assertionsDisabled */ /* Inaccessible static: created */ /* Inaccessible static: mode */ -/* Inaccessible static: handle */ /* Inaccessible static: closeRequested */ #undef org_lwjgl_Display_PLATFORM_WGL #define org_lwjgl_Display_PLATFORM_WGL 0L @@ -18,7 +17,7 @@ #define org_lwjgl_Display_PLATFORM_GLX 1L #undef org_lwjgl_Display_PLATFORM_AGL #define org_lwjgl_Display_PLATFORM_AGL 2L -/* Inaccessible static: class_00024org_00024lwjgl_00024Display */ +/* Inaccessible static: class_000240 */ /* * Class: org_lwjgl_Display * Method: init Index: org_lwjgl_Sys.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_Sys.h,v retrieving revision 1.19 retrieving revision 1.20 diff -u -d -r1.19 -r1.20 --- org_lwjgl_Sys.h 20 Dec 2003 22:07:19 -0000 1.19 +++ org_lwjgl_Sys.h 26 Feb 2004 21:54:05 -0000 1.20 @@ -59,10 +59,10 @@ /* * Class: org_lwjgl_Sys - * Method: alert + * Method: nAlert * Signature: (Ljava/lang/String;Ljava/lang/String;)V */ -JNIEXPORT void JNICALL Java_org_lwjgl_Sys_alert +JNIEXPORT void JNICALL Java_org_lwjgl_Sys_nAlert (JNIEnv *, jclass, jstring, jstring); /* Index: org_lwjgl_input_Controller.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_input_Controller.h,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- org_lwjgl_input_Controller.h 30 Sep 2003 10:52:05 -0000 1.2 +++ org_lwjgl_input_Controller.h 26 Feb 2004 21:54:05 -0000 1.3 @@ -40,7 +40,7 @@ /* Inaccessible static: buttonName */ /* Inaccessible static: buttonMap */ /* Inaccessible static: initialized */ -/* Inaccessible static: class_00024org_00024lwjgl_00024input_00024Controller */ +/* Inaccessible static: class_000240 */ /* * Class: org_lwjgl_input_Controller * Method: nPoll Index: org_lwjgl_input_Cursor.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_input_Cursor.h,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- org_lwjgl_input_Cursor.h 8 Oct 2003 07:49:43 -0000 1.5 +++ org_lwjgl_input_Cursor.h 26 Feb 2004 21:54:05 -0000 1.6 @@ -9,7 +9,7 @@ #endif /* Inaccessible static: _00024assertionsDisabled */ /* Inaccessible static: initialized */ -/* Inaccessible static: class_00024org_00024lwjgl_00024input_00024Cursor */ +/* Inaccessible static: class_000240 */ /* * Class: org_lwjgl_input_Cursor * Method: nCreateCursor Index: org_lwjgl_input_Keyboard.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_input_Keyboard.h,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- org_lwjgl_input_Keyboard.h 11 Oct 2003 16:29:40 -0000 1.8 +++ org_lwjgl_input_Keyboard.h 26 Feb 2004 21:54:05 -0000 1.9 @@ -273,11 +273,12 @@ /* Inaccessible static: readBuffer */ /* Inaccessible static: translationEnabled */ /* Inaccessible static: numEvents */ -/* Inaccessible static: character */ -/* Inaccessible static: key */ -/* Inaccessible static: state */ +/* Inaccessible static: eventCharacter */ +/* Inaccessible static: eventKey */ +/* Inaccessible static: eventState */ /* Inaccessible static: initialized */ -/* Inaccessible static: class_00024org_00024lwjgl_00024input_00024Keyboard */ +/* Inaccessible static: class_000240 */ +/* Inaccessible static: class_000241 */ /* * Class: org_lwjgl_input_Keyboard * Method: initIDs Index: org_lwjgl_input_Mouse.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_input_Mouse.h,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- org_lwjgl_input_Mouse.h 11 Oct 2003 16:29:40 -0000 1.10 +++ org_lwjgl_input_Mouse.h 26 Feb 2004 21:54:05 -0000 1.11 @@ -16,6 +16,8 @@ #define org_lwjgl_input_Mouse_CURSOR_ANIMATION 4L /* Inaccessible static: created */ /* Inaccessible static: buttons */ +/* Inaccessible static: x */ +/* Inaccessible static: y */ /* Inaccessible static: dx */ /* Inaccessible static: dy */ /* Inaccessible static: dwheel */ @@ -26,9 +28,9 @@ /* Inaccessible static: buttonMap */ /* Inaccessible static: initialized */ /* Inaccessible static: readBuffer */ -/* Inaccessible static: button */ -/* Inaccessible static: state */ -/* Inaccessible static: class_00024org_00024lwjgl_00024input_00024Mouse */ +/* Inaccessible static: eventButton */ +/* Inaccessible static: eventState */ +/* Inaccessible static: class_000240 */ /* * Class: org_lwjgl_input_Mouse * Method: nGetNativeCursorCaps Index: org_lwjgl_openal_AL.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_openal_AL.h,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- org_lwjgl_openal_AL.h 26 Feb 2004 21:51:58 -0000 1.1 +++ org_lwjgl_openal_AL.h 26 Feb 2004 21:54:05 -0000 1.2 @@ -15,8 +15,8 @@ /* Inaccessible static: contextRefresh */ /* Inaccessible static: contextSynchronized */ /* Inaccessible static: created */ -/* Inaccessible static: class_000240 */ -/* Inaccessible static: class_000241 */ +/* Inaccessible static: class_00024org_00024lwjgl_00024openal_00024AL */ +/* Inaccessible static: class_00024java_00024lang_00024String */ /* * Class: org_lwjgl_openal_AL * Method: nCreate Index: org_lwjgl_openal_AL10.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_openal_AL10.h,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- org_lwjgl_openal_AL10.h 26 Feb 2004 21:51:58 -0000 1.1 +++ org_lwjgl_openal_AL10.h 26 Feb 2004 21:54:05 -0000 1.2 @@ -126,7 +126,7 @@ #define org_lwjgl_openal_AL10_AL_INVERSE_DISTANCE 53249L #undef org_lwjgl_openal_AL10_AL_INVERSE_DISTANCE_CLAMPED #define org_lwjgl_openal_AL10_AL_INVERSE_DISTANCE_CLAMPED 53250L -/* Inaccessible static: class_000240 */ +/* Inaccessible static: class_00024org_00024lwjgl_00024openal_00024AL10 */ /* * Class: org_lwjgl_openal_AL10 * Method: alEnable Index: org_lwjgl_opengl_GL11.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_opengl_GL11.h,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- org_lwjgl_opengl_GL11.h 26 Jan 2004 17:12:22 -0000 1.2 +++ org_lwjgl_opengl_GL11.h 26 Feb 2004 21:54:05 -0000 1.3 @@ -7,7 +7,6 @@ #ifdef __cplusplus extern "C" { #endif -/* Inaccessible static: _00024assertionsDisabled */ #undef org_lwjgl_opengl_GL11_GL_ACCUM #define org_lwjgl_opengl_GL11_GL_ACCUM 256L #undef org_lwjgl_opengl_GL11_GL_LOAD @@ -1072,7 +1071,6 @@ #define org_lwjgl_opengl_GL11_GL_LOGIC_OP 3057L #undef org_lwjgl_opengl_GL11_GL_TEXTURE_COMPONENTS #define org_lwjgl_opengl_GL11_GL_TEXTURE_COMPONENTS 4099L -/* Inaccessible static: class_00024org_00024lwjgl_00024opengl_00024GL11 */ /* * Class: org_lwjgl_opengl_GL11 * Method: glAccum Index: org_lwjgl_opengl_GL12.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_opengl_GL12.h,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- org_lwjgl_opengl_GL12.h 20 Jan 2004 11:19:13 -0000 1.1 +++ org_lwjgl_opengl_GL12.h 26 Feb 2004 21:54:05 -0000 1.2 @@ -7,1081 +7,24 @@ #ifdef __cplusplus extern "C" { #endif -/* Inaccessible static: _00024assertionsDisabled */ -#undef org_lwjgl_opengl_GL12_GL_ACCUM -#define org_lwjgl_opengl_GL12_GL_ACCUM 256L -#undef org_lwjgl_opengl_GL12_GL_LOAD -#define org_lwjgl_opengl_GL12_GL_LOAD 257L -#undef org_lwjgl_opengl_GL12_GL_RETURN -#define org_lwjgl_opengl_GL12_GL_RETURN 258L -#undef org_lwjgl_opengl_GL12_GL_MULT [...1543 lines suppressed...] - -/* - * Class: org_lwjgl_opengl_GL12 - * Method: nglSeparableFilter2D - * Signature: (IIIIIILjava/nio/Buffer;ILjava/nio/Buffer;I)V - */ -JNIEXPORT void JNICALL Java_org_lwjgl_opengl_GL12_nglSeparableFilter2D - (JNIEnv *, jclass, jint, jint, jint, jint, jint, jint, jobject, jint, jobject, jint); - -/* - * Class: org_lwjgl_opengl_GL12 - * Method: nglGetSeparableFilter - * Signature: (IIILjava/nio/Buffer;ILjava/nio/Buffer;ILjava/nio/Buffer;I)V - */ -JNIEXPORT void JNICALL Java_org_lwjgl_opengl_GL12_nglGetSeparableFilter - (JNIEnv *, jclass, jint, jint, jint, jobject, jint, jobject, jint, jobject, jint); - /* * Class: org_lwjgl_opengl_GL12 * Method: nglDrawRangeElements Index: org_lwjgl_opengl_GL13.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_opengl_GL13.h,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- org_lwjgl_opengl_GL13.h 20 Jan 2004 11:19:13 -0000 1.1 +++ org_lwjgl_opengl_GL13.h 26 Feb 2004 21:54:05 -0000 1.2 @@ -7,1298 +7,6 @@ #ifdef __cplusplus extern "C" { #endif -/* Inaccessible static: _00024assertionsDisabled */ -#undef org_lwjgl_opengl_GL13_GL_ACCUM -#define org_lwjgl_opengl_GL13_GL_ACCUM 256L -#undef org_lwjgl_opengl_GL13_GL_LOAD -#define org_lwjgl_opengl_GL13_GL_LOAD 257L -#undef org_lwjgl_opengl_GL13_GL_RETURN -#define org_lwjgl_opengl_GL13_GL_RETURN 258L -#undef org_lwjgl_opengl_GL13_GL_MULT [...1267 lines suppressed...] -#undef org_lwjgl_opengl_GL13_GL_TABLE_TOO_LARGE -#define org_lwjgl_opengl_GL13_GL_TABLE_TOO_LARGE 32817L -#undef org_lwjgl_opengl_GL13_GL_BLEND_EQUATION -#define org_lwjgl_opengl_GL13_GL_BLEND_EQUATION 32777L -#undef org_lwjgl_opengl_GL13_GL_MIN -#define org_lwjgl_opengl_GL13_GL_MIN 32775L -#undef org_lwjgl_opengl_GL13_GL_MAX -#define org_lwjgl_opengl_GL13_GL_MAX 32776L -#undef org_lwjgl_opengl_GL13_GL_FUNC_ADD -#define org_lwjgl_opengl_GL13_GL_FUNC_ADD 32774L -#undef org_lwjgl_opengl_GL13_GL_FUNC_SUBTRACT -#define org_lwjgl_opengl_GL13_GL_FUNC_SUBTRACT 32778L -#undef org_lwjgl_opengl_GL13_GL_FUNC_REVERSE_SUBTRACT -#define org_lwjgl_opengl_GL13_GL_FUNC_REVERSE_SUBTRACT 32779L -#undef org_lwjgl_opengl_GL13_GL_BLEND_COLOR -#define org_lwjgl_opengl_GL13_GL_BLEND_COLOR 32773L -/* Inaccessible static: class_00024org_00024lwjgl_00024opengl_00024GL12 */ #undef org_lwjgl_opengl_GL13_GL_TEXTURE0 #define org_lwjgl_opengl_GL13_GL_TEXTURE0 33984L #undef org_lwjgl_opengl_GL13_GL_TEXTURE1 Index: org_lwjgl_opengl_GL14.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_opengl_GL14.h,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- org_lwjgl_opengl_GL14.h 17 Feb 2004 21:36:17 -0000 1.2 +++ org_lwjgl_opengl_GL14.h 26 Feb 2004 21:54:05 -0000 1.3 @@ -7,1486 +7,6 @@ #ifdef __cplusplus extern "C" { #endif -#undef org_lwjgl_opengl_GL14_GL_ACCUM -#define org_lwjgl_opengl_GL14_GL_ACCUM 256L -#undef org_lwjgl_opengl_GL14_GL_LOAD -#define org_lwjgl_opengl_GL14_GL_LOAD 257L -#undef org_lwjgl_opengl_GL14_GL_RETURN -#define org_lwjgl_opengl_GL14_GL_RETURN 258L -#undef org_lwjgl_opengl_GL14_GL_MULT -#define org_lwjgl_opengl_GL14_GL_MULT 259L [...1455 lines suppressed...] -#define org_lwjgl_opengl_GL14_GL_ADD_SIGNED 34164L -#undef org_lwjgl_opengl_GL14_GL_INTERPOLATE -#define org_lwjgl_opengl_GL14_GL_INTERPOLATE 34165L -#undef org_lwjgl_opengl_GL14_GL_SUBTRACT -#define org_lwjgl_opengl_GL14_GL_SUBTRACT 34023L -#undef org_lwjgl_opengl_GL14_GL_CONSTANT -#define org_lwjgl_opengl_GL14_GL_CONSTANT 34166L -#undef org_lwjgl_opengl_GL14_GL_PRIMARY_COLOR -#define org_lwjgl_opengl_GL14_GL_PRIMARY_COLOR 34167L -#undef org_lwjgl_opengl_GL14_GL_PREVIOUS -#define org_lwjgl_opengl_GL14_GL_PREVIOUS 34168L -#undef org_lwjgl_opengl_GL14_GL_DOT3_RGB -#define org_lwjgl_opengl_GL14_GL_DOT3_RGB 34478L -#undef org_lwjgl_opengl_GL14_GL_DOT3_RGBA -#define org_lwjgl_opengl_GL14_GL_DOT3_RGBA 34479L -#undef org_lwjgl_opengl_GL14_GL_CLAMP_TO_BORDER -#define org_lwjgl_opengl_GL14_GL_CLAMP_TO_BORDER 33069L #undef org_lwjgl_opengl_GL14_GL_GENERATE_MIPMAP #define org_lwjgl_opengl_GL14_GL_GENERATE_MIPMAP 33169L #undef org_lwjgl_opengl_GL14_GL_GENERATE_MIPMAP_HINT Index: org_lwjgl_opengl_GL15.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_opengl_GL15.h,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- org_lwjgl_opengl_GL15.h 15 Feb 2004 15:21:24 -0000 1.1 +++ org_lwjgl_opengl_GL15.h 26 Feb 2004 21:54:05 -0000 1.2 @@ -1,132 +1,173 @@ -/* -* Copyright (c) 2002 Lightweight Java Game Library Project -* All rights reserved. -* -* Redistribution and use in source and binary forms, with or without -* modification, are permitted provided that the following conditions are -* met: -* -* * Redistributions of source code must retain the above copyright -* notice, this list of conditions and the following disclaimer. -* -* * Redistributions in binary form must reproduce the above copyright -* notice, this list of conditions and the following disclaimer in the -* documentation and/or other materials provided with the distribution. -* -* * Neither the name of 'Light Weight Java Game Library' nor the names of -* its contributors may be used to endorse or promote products derived -* from this software without specific prior written permission. -* -* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED -* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, -* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -*/ - -// ---------------------------------- -// MACHINE GENERATED HEADER OF CLASS: org.lwjgl.opengl.GL15 -// ---------------------------------- - +/* DO NOT EDIT THIS FILE - it is machine generated */ #include <jni.h> +/* Header for class org_lwjgl_opengl_GL15 */ #ifndef _Included_org_lwjgl_opengl_GL15 #define _Included_org_lwjgl_opengl_GL15 - #ifdef __cplusplus extern "C" { #endif - -// ---------------------------------------------------------------------- -// ---------------------- ARB_vertex_buffer_object ---------------------- -// ---------------------------------------------------------------------- - +/* Inaccessible static: _00024assertionsDisabled */ +#undef org_lwjgl_opengl_GL15_GL_ARRAY_BUFFER +#define org_lwjgl_opengl_GL15_GL_ARRAY_BUFFER 34962L +#undef org_lwjgl_opengl_GL15_GL_ELEMENT_ARRAY_BUFFER +#define org_lwjgl_opengl_GL15_GL_ELEMENT_ARRAY_BUFFER 34963L +#undef org_lwjgl_opengl_GL15_GL_ARRAY_BUFFER_BINDING +#define org_lwjgl_opengl_GL15_GL_ARRAY_BUFFER_BINDING 34964L +#undef org_lwjgl_opengl_GL15_GL_ELEMENT_ARRAY_BUFFER_BINDING +#define org_lwjgl_opengl_GL15_GL_ELEMENT_ARRAY_BUFFER_BINDING 34965L +#undef org_lwjgl_opengl_GL15_GL_VERTEX_ARRAY_BUFFER_BINDING +#define org_lwjgl_opengl_GL15_GL_VERTEX_ARRAY_BUFFER_BINDING 34966L +#undef org_lwjgl_opengl_GL15_GL_NORMAL_ARRAY_BUFFER_BINDING +#define org_lwjgl_opengl_GL15_GL_NORMAL_ARRAY_BUFFER_BINDING 34967L +#undef org_lwjgl_opengl_GL15_GL_COLOR_ARRAY_BUFFER_BINDING +#define org_lwjgl_opengl_GL15_GL_COLOR_ARRAY_BUFFER_BINDING 34968L +#undef org_lwjgl_opengl_GL15_GL_INDEX_ARRAY_BUFFER_BINDING +#define org_lwjgl_opengl_GL15_GL_INDEX_ARRAY_BUFFER_BINDING 34969L +#undef org_lwjgl_opengl_GL15_GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING +#define org_lwjgl_opengl_GL15_GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING 34970L +#undef org_lwjgl_opengl_GL15_GL_EDGE_FLAG_ARRAY_BUFFER_BINDING +#define org_lwjgl_opengl_GL15_GL_EDGE_FLAG_ARRAY_BUFFER_BINDING 34971L +#undef org_lwjgl_opengl_GL15_GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING +#define org_lwjgl_opengl_GL15_GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING 34972L +#undef org_lwjgl_opengl_GL15_GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING +#define org_lwjgl_opengl_GL15_GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING 34973L +#undef org_lwjgl_opengl_GL15_GL_WEIGHT_ARRAY_BUFFER_BINDING +#define org_lwjgl_opengl_GL15_GL_WEIGHT_ARRAY_BUFFER_BINDING 34974L +#undef org_lwjgl_opengl_GL15_GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING +#define org_lwjgl_opengl_GL15_GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING 34975L +#undef org_lwjgl_opengl_GL15_GL_STREAM_DRAW +#define org_lwjgl_opengl_GL15_GL_STREAM_DRAW 35040L +#undef org_lwjgl_opengl_GL15_GL_STREAM_READ +#define org_lwjgl_opengl_GL15_GL_STREAM_READ 35041L +#undef org_lwjgl_opengl_GL15_GL_STREAM_COPY +#define org_lwjgl_opengl_GL15_GL_STREAM_COPY 35042L +#undef org_lwjgl_opengl_GL15_GL_STATIC_DRAW +#define org_lwjgl_opengl_GL15_GL_STATIC_DRAW 35044L +#undef org_lwjgl_opengl_GL15_GL_STATIC_READ +#define org_lwjgl_opengl_GL15_GL_STATIC_READ 35045L +#undef org_lwjgl_opengl_GL15_GL_STATIC_COPY +#define org_lwjgl_opengl_GL15_GL_STATIC_COPY 35046L +#undef org_lwjgl_opengl_GL15_GL_DYNAMIC_DRAW +#define org_lwjgl_opengl_GL15_GL_DYNAMIC_DRAW 35048L +#undef org_lwjgl_opengl_GL15_GL_DYNAMIC_READ +#define org_lwjgl_opengl_GL15_GL_DYNAMIC_READ 35049L +#undef org_lwjgl_opengl_GL15_GL_DYNAMIC_COPY +#define org_lwjgl_opengl_GL15_GL_DYNAMIC_COPY 35050L +#undef org_lwjgl_opengl_GL15_GL_READ_ONLY +#define org_lwjgl_opengl_GL15_GL_READ_ONLY 35000L +#undef org_lwjgl_opengl_GL15_GL_WRITE_ONLY +#define org_lwjgl_opengl_GL15_GL_WRITE_ONLY 35001L +#undef org_lwjgl_opengl_GL15_GL_READ_WRITE +#define org_lwjgl_opengl_GL15_GL_READ_WRITE 35002L +#undef org_lwjgl_opengl_GL15_GL_BUFFER_SIZE +#define org_lwjgl_opengl_GL15_GL_BUFFER_SIZE 34660L +#undef org_lwjgl_opengl_GL15_GL_BUFFER_USAGE +#define org_lwjgl_opengl_GL15_GL_BUFFER_USAGE 34661L +#undef org_lwjgl_opengl_GL15_GL_BUFFER_ACCESS +#define org_lwjgl_opengl_GL15_GL_BUFFER_ACCESS 35003L +#undef org_lwjgl_opengl_GL15_GL_BUFFER_MAPPED +#define org_lwjgl_opengl_GL15_GL_BUFFER_MAPPED 35004L +#undef org_lwjgl_opengl_GL15_GL_BUFFER_MAP_POINTER +#define org_lwjgl_opengl_GL15_GL_BUFFER_MAP_POINTER 35005L +#undef org_lwjgl_opengl_GL15_GL_SAMPLES_PASSED +#define org_lwjgl_opengl_GL15_GL_SAMPLES_PASSED 35092L +#undef org_lwjgl_opengl_GL15_GL_QUERY_COUNTER_BITS +#define org_lwjgl_opengl_GL15_GL_QUERY_COUNTER_BITS 34916L +#undef org_lwjgl_opengl_GL15_GL_CURRENT_QUERY +#define org_lwjgl_opengl_GL15_GL_CURRENT_QUERY 34917L +#undef org_lwjgl_opengl_GL15_GL_QUERY_RESULT +#define org_lwjgl_opengl_GL15_GL_QUERY_RESULT 34918L +#undef org_lwjgl_opengl_GL15_GL_QUERY_RESULT_AVAILABLE +#define org_lwjgl_opengl_GL15_GL_QUERY_RESULT_AVAILABLE 34919L +/* Inaccessible static: class_000240 */ /* - * Class: org.lwjgl.opengl.GL15 - * Method: nglBindBuffer + * Class: org_lwjgl_opengl_GL15 + * Method: nglBindBuffer + * Signature: (II)V */ JNIEXPORT void JNICALL Java_org_lwjgl_opengl_GL15_nglBindBuffer - (JNIEnv *, jclass, jint, jint); + (JNIEnv *, jclass, jint, jint); /* - * Class: org.lwjgl.opengl.GL15 - * Method: nglDeleteBuffers + * Class: org_lwjgl_opengl_GL15 + * Method: nglDeleteBuffers + * Signature: (ILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_opengl_GL15_nglDeleteBuffers - (JNIEnv *, jclass, jint, jobject, jint); + (JNIEnv *, jclass, jint, jobject, jint); /* - * Class: org.lwjgl.opengl.GL15 - * Method: nglGenBuffers + * Class: org_lwjgl_opengl_GL15 + * Method: nglGenBuffers + * Signature: (ILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_opengl_GL15_nglGenBuffers - (JNIEnv *, jclass, jint, jobject, jint); + (JNIEnv *, jclass, jint, jobject, jint); /* - * Class: org.lwjgl.opengl.GL15 - * Method: glIsBuffer + * Class: org_lwjgl_opengl_GL15 + * Method: glIsBuffer + * Signature: (I)Z */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_opengl_GL15_glIsBuffer - (JNIEnv *, jclass, jint); + (JNIEnv *, jclass, jint); /* - * Class: org.lwjgl.opengl.GL15 - * Method: nglBufferData + * Class: org_lwjgl_opengl_GL15 + * Method: nglBufferData + * Signature: (IILjava/nio/Buffer;II)V */ JNIEXPORT void JNICALL Java_org_lwjgl_opengl_GL15_nglBufferData - (JNIEnv *, jclass, jint, jint, jobject, jint, jint); + (JNIEnv *, jclass, jint, jint, jobject, jint, jint); /* - * Class: org.lwjgl.opengl.GL15 - * Method: nglBufferSubData + * Class: org_lwjgl_opengl_GL15 + * Method: nglBufferSubData + * Signature: (IIILjava/nio/Buffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_opengl_GL15_nglBufferSubData - (JNIEnv *, jclass, jint, jint, jint, jobject, jint); + (JNIEnv *, jclass, jint, jint, jint, jobject, jint); /* - * Class: org.lwjgl.opengl.GL15 - * Method: nglGetBufferSubData + * Class: org_lwjgl_opengl_GL15 + * Method: nglGetBufferSubData + * Signature: (IIILjava/nio/Buffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_opengl_GL15_nglGetBufferSubData - (JNIEnv *, jclass, jint, jint, jint, jobject, jint); + (JNIEnv *, jclass, jint, jint, jint, jobject, jint); /* - * Class: org.lwjgl.opengl.GL15 - * Method: glMapBuffer + * Class: org_lwjgl_opengl_GL15 + * Method: glMapBuffer + * Signature: (IIILjava/nio/ByteBuffer;)Ljava/nio/ByteBuffer; */ JNIEXPORT jobject JNICALL Java_org_lwjgl_opengl_GL15_glMapBuffer - (JNIEnv *, jclass, jint, jint, jint, jobject); + (JNIEnv *, jclass, jint, jint, jint, jobject); /* - * Class: org.lwjgl.opengl.GL15 - * Method: glUnmapBuffer + * Class: org_lwjgl_opengl_GL15 + * Method: glUnmapBuffer + * Signature: (I)Z */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_opengl_GL15_glUnmapBuffer - (JNIEnv *, jclass, jint); + (JNIEnv *, jclass, jint); /* - * Class: org.lwjgl.opengl.GL15 - * Method: nglGetBufferParameteriv + * Class: org_lwjgl_opengl_GL15 + * Method: nglGetBufferParameteriv + * Signature: (IILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_opengl_GL15_nglGetBufferParameteriv - (JNIEnv *, jclass, jint, jint, jobject, jint); + (JNIEnv *, jclass, jint, jint, jobject, jint); /* - * Class: org.lwjgl.opengl.GL15 - * Method: glGetBufferPointer + * Class: org_lwjgl_opengl_GL15 + * Method: glGetBufferPointer + * Signature: (III)Ljava/nio/ByteBuffer; */ JNIEXPORT jobject JNICALL Java_org_lwjgl_opengl_GL15_glGetBufferPointer - (JNIEnv *, jclass, jint, jint, jint); - -// ----------------------------------------------------------------- -// ---------------------- ARB_occlusion_query ---------------------- -// ----------------------------------------------------------------- + (JNIEnv *, jclass, jint, jint, jint); /* * Class: org_lwjgl_opengl_GL15 @@ -195,5 +236,4 @@ #ifdef __cplusplus } #endif - #endif Index: org_lwjgl_opengl_GLContext.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_opengl_GLContext.h,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- org_lwjgl_opengl_GLContext.h 24 Feb 2004 14:31:35 -0000 1.2 +++ org_lwjgl_opengl_GLContext.h 26 Feb 2004 21:54:05 -0000 1.3 @@ -8,8 +8,6 @@ extern "C" { #endif /* Inaccessible static: currentContext */ -/* Inaccessible static: contextMap */ -/* Inaccessible static: extensionsMap */ /* Inaccessible static: GL_ARB_imaging */ /* Inaccessible static: GL_ARB_depth_texture */ /* Inaccessible static: GL_ARB_fragment_program */ @@ -76,8 +74,6 @@ /* Inaccessible static: GL_ATI_vertex_attrib_array_object */ /* Inaccessible static: GL_ATI_vertex_streams */ /* Inaccessible static: GL_ATI_separate_stencil */ -/* Inaccessible static: GL_ATIX_point_sprites */ -/* Inaccessible static: GL_ATIX_texture_env_route */ /* Inaccessible static: GL_NV_blend_square */ /* Inaccessible static: GL_NV_copy_depth_to_color */ /* Inaccessible static: GL_NV_depth_clamp */ |
Update of /cvsroot/java-game-lib/LWJGL/src/native/common In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6429/native/common Modified Files: Makefile.am Added Files: org_lwjgl_openal_AL.cpp org_lwjgl_openal_AL.h org_lwjgl_openal_AL10.cpp org_lwjgl_openal_AL10.h org_lwjgl_openal_eax_EAX.cpp org_lwjgl_openal_eax_EAX.h org_lwjgl_openal_eax_EAX20.cpp org_lwjgl_openal_eax_EAX20.h Removed Files: org_lwjgl_openal_BaseAL.cpp org_lwjgl_openal_BaseAL.h org_lwjgl_openal_CoreAL.cpp org_lwjgl_openal_CoreAL.h org_lwjgl_openal_eax_BaseEAX.cpp org_lwjgl_openal_eax_BaseEAX.h org_lwjgl_openal_eax_CoreEAX.cpp org_lwjgl_openal_eax_CoreEAX.h Log Message: OpenAL / EAX Refactor --- NEW FILE: org_lwjgl_openal_AL.cpp --- /* * Copyright (c) 2002-2004 Lightweight Java Game Library Project * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are * met: * * * Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * * Neither the name of 'Lightweight Java Game Library' nor the names of * its contributors may be used to endorse or promote products derived * from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include "org_lwjgl_openal_AL.h" /* OpenAL includes */ #include "checkALerror.h" #include "extal.h" JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL_nCreate (JNIEnv *env, jclass clazz, jobjectArray oalPaths) { InitializeOpenAL(env, oalPaths); } JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL_nDestroy(JNIEnv *env, jclass clazz) { DeInitializeOpenAL(); } --- NEW FILE: org_lwjgl_openal_AL.h --- /* DO NOT EDIT THIS FILE - it is machine generated */ #include <jni.h> /* Header for class org_lwjgl_openal_AL */ #ifndef _Included_org_lwjgl_openal_AL #define _Included_org_lwjgl_openal_AL #ifdef __cplusplus extern "C" { #endif /* Inaccessible static: alc */ /* Inaccessible static: device */ /* Inaccessible static: context */ /* Inaccessible static: deviceArguments */ /* Inaccessible static: contextFrequency */ /* Inaccessible static: contextRefresh */ /* Inaccessible static: contextSynchronized */ /* Inaccessible static: created */ /* Inaccessible static: class_000240 */ /* Inaccessible static: class_000241 */ /* * Class: org_lwjgl_openal_AL * Method: nCreate * Signature: ([Ljava/lang/String;)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL_nCreate (JNIEnv *, jclass, jobjectArray); /* * Class: org_lwjgl_openal_AL * Method: nDestroy * Signature: ()V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL_nDestroy (JNIEnv *, jclass); #ifdef __cplusplus } #endif #endif --- NEW FILE: org_lwjgl_openal_AL10.cpp --- /* * Copyright (c) 2002-2004 Lightweight Java Game Library Project * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are * met: * * * Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * * Neither the name of 'Lightweight Java Game Library' nor the names of * its contributors may be used to endorse or promote products derived * from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ /** * $Id: org_lwjgl_openal_AL10.cpp,v 1.1 2004/02/26 21:51:58 matzon Exp $ * * This is the actual JNI implementation of the OpenAL core. It handles * whatever is needed for proper OpenAL support via using Java. * * @author Brian Matzon <br...@ma...> * @version $Revision: 1.1 $ */ #include "org_lwjgl_openal_AL10.h" /* OpenAL includes */ #include "checkALerror.h" #include "extal.h" /** * This function enables a feature of the OpenAL driver. * * C Specification: * ALvoid alEnable(ALenum capability); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alEnable (JNIEnv *env, jclass clazz, jint capability) { alEnable((ALenum) capability); CHECK_AL_ERROR } /** * This function disables a feature of the OpenAL driver. * * C Specification: * ALvoid alDisable(ALenum capability); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alDisable (JNIEnv *env, jclass clazz, jint capability) { alDisable((ALenum) capability); CHECK_AL_ERROR } /** * This function returns a boolean indicating if a specific feature is enabled in the OpenAL driver. * * C Specification: * Alboolean alIsEnabled(ALenum capability); */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_openal_AL10_alIsEnabled (JNIEnv *env, jclass clazz, jint capability) { jboolean result = (jboolean) alIsEnabled((ALenum) capability); CHECK_AL_ERROR return result; } /** * This function Enables a feature of the OpenAL driver. * * C Specification * ALvoid alHint(ALenum target, ALenum mode); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alHint (JNIEnv *env, jclass clazz, jint target, jint mode) { //alHint((ALint)target, (ALint)mode); //cannot link with above statement return; } /** * This function returns a boolean OpenAL state. * * C Specification: * Alboolean alGetBoolean(ALenum pname); */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_openal_AL10_alGetBoolean (JNIEnv *env, jclass clazz, jint pname) { jboolean result = (jboolean) alGetBoolean((ALenum) pname); CHECK_AL_ERROR return result; } /** * This function returns an integer OpenAL state. * * C Specification: * Alint alGetInteger(ALenum pname); */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_AL10_alGetInteger (JNIEnv *env, jclass clazz, jint pname) { jint result = (jint) alGetInteger((ALenum) pname); CHECK_AL_ERROR return result; } /** * This function returns a floating point OpenAL state. * * C Specification: * ALfloat alGetFloat(ALenum pname); */ JNIEXPORT jfloat JNICALL Java_org_lwjgl_openal_AL10_alGetFloat (JNIEnv *env, jclass clazz, jint pname) { jfloat result = (jfloat) alGetFloat((ALenum) pname); CHECK_AL_ERROR return result; } /** * This function retrieves a floating point OpenAL state. * * C Specification: * ALvoid alGetFloatv(ALenum pname,ALfloat *data); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalGetFloatv (JNIEnv *env, jclass clazz, jint pname, jobject data, int offset) { alGetFloatv((ALenum) pname, offset + (ALfloat*) env->GetDirectBufferAddress(data)); CHECK_AL_ERROR } /** * This function retrieves an OpenAL string property. * * C Specification: * ALubyte * alGetString(ALenum pname); */ JNIEXPORT jstring JNICALL Java_org_lwjgl_openal_AL10_alGetString (JNIEnv *env, jclass clazz, jint param) { jstring string = env->NewStringUTF((char*) alGetString(param)); CHECK_AL_ERROR return string; } /** * This function returns the current error state and then clears the error state. * * C Specification: * ALenum alGetError(ALvoid); */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_AL10_alGetError (JNIEnv *env, jclass clazz) { jint result = (jint) alGetError(); // Don't think we should be checking for errors here..? // CHECK_AL_ERROR return result; } /** * This function tests if a specific extension is available for the OpenAL driver. * * C Specification: * ALboolean alIsExtensionPresent(ALubyte *extName); */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_openal_AL10_alIsExtensionPresent (JNIEnv *env, jclass clazz, jstring fname) { ALubyte* functionname = (ALubyte*) (env->GetStringUTFChars(fname, 0)); jboolean result = (jboolean) alIsExtensionPresent(functionname); env->ReleaseStringUTFChars((jstring)functionname, 0); CHECK_AL_ERROR return result; } /** * This function returns the enumeration value of an OpenAL enum described by a string. * * C Specification: * ALenum alGetEnumValue(ALubyte *enumName); */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_AL10_alGetEnumValue (JNIEnv *env, jclass clazz, jstring ename) { ALubyte* functionname = (ALubyte*) (env->GetStringUTFChars(ename, 0)); jint result = (jint) alGetEnumValue(functionname); env->ReleaseStringUTFChars((jstring)functionname, 0); CHECK_AL_ERROR return result; } /** * This function sets an integer property of the listener. * * C Specification: * ALvoid alListeneri(ALenum pname,ALint value); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alListeneri (JNIEnv *env, jclass clazz, jint pname, jint value) { alListeneri((ALenum) pname, (ALint) value); CHECK_AL_ERROR } /** * This function sets a floating point property for the listener. * * C Specification: * ALvoid alListenerf(ALenum pname,ALfloat value); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alListenerf (JNIEnv *env, jclass clazz, jint pname, jfloat value) { alListenerf((ALenum) pname, (ALfloat) value); CHECK_AL_ERROR } /* * Class: org_lwjgl_openal_AL10 * Method: nalListenerf * Signature: (ILjava/nio/FloatBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalListenerfv (JNIEnv *env, jclass clazz, jint pname, jobject values, jint offset) { alListenerfv((ALenum) pname, offset + (ALfloat*) env->GetDirectBufferAddress(values)); } /** * This function sets a floating point property for the listener. * * C Specification: * ALvoid alListener3f(ALenum pname,ALfloat v1,ALfloat v2,ALfloat v3); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alListener3f (JNIEnv *env, jclass clazz, jint pname, jfloat v1, jfloat v2, jfloat v3) { alListener3f((ALenum) pname, (ALfloat) v1, (ALfloat) v2, (ALfloat) v3); CHECK_AL_ERROR } /** * This function retrieves an integer property of the listener. * * C Specification: * ALvoid alGetListeneri(ALenum pname,ALint *value); */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_AL10_alGetListeneri (JNIEnv *env, jclass clazz, jint pname) { ALint value = 0; alGetListeneri((ALenum) pname, &value); CHECK_AL_ERROR return value; } /** * This function retrieves a floating point property of the listener. * * C Specification: * ALvoid alGetListenerf(ALenum pname,ALfloat *value); */ JNIEXPORT jfloat JNICALL Java_org_lwjgl_openal_AL10_alGetListenerf (JNIEnv *env, jclass clazz, jint pname) { ALfloat value = 0.0f; alGetListenerf((ALenum) pname, &value); CHECK_AL_ERROR return value; } /** * This function retrieves a floating point-vector property of the listener. * * C Specification: * ALvoid alGetListenerfv(ALenum pname,ALfloat *values); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalGetListenerfv (JNIEnv *env, jclass clazz, jint pname, jobject values, jint offset) { alGetListenerfv((ALenum) pname, offset + (ALfloat*) env->GetDirectBufferAddress(values)); CHECK_AL_ERROR } /** * This function generates one or more sources. * * C Specification: * ALvoid alGenSources(ALsizei n,ALuint *sources); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalGenSources (JNIEnv *env, jclass clazz, jint n, jobject sources, jint offset) { alGenSources(n, offset + (ALuint*) env->GetDirectBufferAddress(sources)); CHECK_AL_ERROR } /** * This function deletes one or more sources. * * C Specification: * ALvoid alDeleteSources(ALsizei n,ALuint *sources); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalDeleteSources (JNIEnv *env, jclass clazz, jint n, jobject sources, jint offset) { alDeleteSources(n, offset + (ALuint*) env->GetDirectBufferAddress(sources)); CHECK_AL_ERROR } /** * This function tests if a source name is valid. * * C Specification: * Alboolean alIsSource(ALuint source); */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_openal_AL10_alIsSource (JNIEnv *env, jclass clazz, jint source) { jboolean result = (jboolean) alIsSource((ALuint) source); CHECK_AL_ERROR return result; } /** * This function sets an integer property of a source. * * C Specification: * ALvoid alSourcei(ALuint source,ALenum pname,ALint value); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSourcei (JNIEnv *env, jclass clazz, jint source, jint pname, jint value) { alSourcei((ALuint) source, (ALenum) pname, (ALint) value); CHECK_AL_ERROR } /** * This function sets a floating point property of a source. * * C Specification: * ALvoid alSourcef(ALuint source,ALenum pname,ALfloat value); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSourcef (JNIEnv *env, jclass clazz, jint source, jint pname, jfloat value) { alSourcef((ALuint) source, (ALenum) pname, (ALfloat) value); CHECK_AL_ERROR } /* * Class: org_lwjgl_openal_AL10 * Method: nalSourcefv * Signature: (IILjava/nio/FloatBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourcefv (JNIEnv *env, jclass clazz, jint source, jint pname, jobject values, jint offset) { alSourcefv((ALuint) source, (ALenum) pname, offset + (ALfloat*) env->GetDirectBufferAddress(values)); CHECK_AL_ERROR } /** * This function sets a source property requiring three floating point values. * C Specification: * ALvoid alSource3f(ALuint source,ALenum pname,ALfloat v1,ALfloat v2,ALfloat v3); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSource3f (JNIEnv *env, jclass clazz, jint source, jint pname, jfloat v1, jfloat v2, jfloat v3) { alSource3f((ALuint) source, (ALenum) pname, (ALfloat) v1, (ALfloat) v2, (ALfloat) v3); CHECK_AL_ERROR } /** * This function retrieves an integer property of a source. * C Specification: * ALvoid alGetSourcei(ALuint source,ALenum pname,ALint *value); */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_AL10_alGetSourcei (JNIEnv *env, jclass clazz, jint source, jint pname) { ALint value = 0; alGetSourcei((ALuint) source, (ALenum) pname, &value); CHECK_AL_ERROR return value; } /** * This function retrieves a floating point property of a source. * * C Specification: * ALvoid alGetSourcef(ALuint source,ALenum pname,ALfloat *value); */ JNIEXPORT jfloat JNICALL Java_org_lwjgl_openal_AL10_alGetSourcef (JNIEnv *env, jclass clazz, jint source, jint pname) { ALfloat value = 0.0f; alGetSourcef((ALuint) source, (ALenum) pname, &value); CHECK_AL_ERROR return value; } /** * This function retrieves a floating point-vector property of a source. * * C Specification: * ALvoid alGetSourcefv(ALuint source,ALenum pname,ALfloat *values); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalGetSourcefv (JNIEnv *env, jclass clazz, jint source, jint pname, jobject values, jint offset) { alGetSourcefv((ALuint) source, (ALenum) pname, offset + (ALfloat*) env->GetDirectBufferAddress(values)); CHECK_AL_ERROR } /** * This function plays a set of sources. * * C Specification: * ALvoid alSourcePlayv(ALsizei n,ALuint *sources); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourcePlayv (JNIEnv *env, jclass clazz, jint n, jobject sources, jint offset) { alSourcePlayv(n, offset + (ALuint*) env->GetDirectBufferAddress(sources)); CHECK_AL_ERROR } /** * This function pauses a set of sources. * * C Specification: * ALvoid alSourcePausev(ALsizei n,ALuint *sources); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourcePausev (JNIEnv *env, jclass clazz, jint n, jobject sources, jint offset) { alSourcePausev(n, offset + (ALuint*) env->GetDirectBufferAddress(sources)); CHECK_AL_ERROR } /** * This function stops a set of sources. * * C Specification: * ALvoid alSourceStopv(ALsizei n,ALuint *sources); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourceStopv (JNIEnv *env, jclass clazz, jint n, jobject sources, jint offset) { alSourceStopv(n, offset + (ALuint*) env->GetDirectBufferAddress(sources)); CHECK_AL_ERROR } /** * This function stops a set of sources and sets all their states to AL_INITIAL. * * C Specification: * ALvoid alSourceRewindv(ALsizei n,ALuint *sources); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourceRewindv (JNIEnv *env, jclass clazz, jint n, jobject sources, jint offset) { alSourceRewindv(n, offset + (ALuint*) env->GetDirectBufferAddress(sources)); CHECK_AL_ERROR } /** * This function plays a source. * * C Specification: * ALvoid alSourcePlay(ALuint source); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSourcePlay (JNIEnv *env, jclass clazz, jint source) { alSourcePlay((ALuint) source); CHECK_AL_ERROR } /* * This function pauses a source. * * C Specification: * ALvoid alSourcePause(ALuint source); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSourcePause (JNIEnv *env, jclass clazz, jint source) { alSourcePause((ALuint) source); CHECK_AL_ERROR } /** * This function stops a source. * * C Specification: * ALvoid alSourceStop(ALuint source); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSourceStop (JNIEnv *env, jclass clazz, jint source) { alSourceStop((ALuint) source); CHECK_AL_ERROR } /** * This function stops the source and sets its state to AL_INITIAL. * * C Specification: * ALvoid alSourceRewind(ALuint source); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSourceRewind (JNIEnv *env, jclass clazz, jint source) { alSourceRewind((ALuint) source); CHECK_AL_ERROR } /** * This function generates one or more buffers. * * C Specification: * ALvoid alGenBuffers(ALsizei n,ALuint *buffers); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalGenBuffers (JNIEnv *env, jclass clazz, jint n, jobject buffers, jint offset) { alGenBuffers(n, offset + (ALuint*) env->GetDirectBufferAddress(buffers)); CHECK_AL_ERROR } /** * This function deletes one or more buffers. * * C Specification: * ALvoid alDeleteBuffers(ALsizei n,ALuint *buffers); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalDeleteBuffers (JNIEnv *env, jclass clazz, jint n, jobject buffers, jint offset) { alDeleteBuffers(n, offset + (ALuint*) env->GetDirectBufferAddress(buffers)); CHECK_AL_ERROR } /** * This function tests if a buffer name is valid. * * C Specification: * Alboolean alIsBuffer(ALuint buffer); */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_openal_AL10_alIsBuffer (JNIEnv *env, jclass clazz, jint buffer) { jboolean result = (jboolean) alIsBuffer((ALuint) buffer); CHECK_AL_ERROR return result; } /** * This function fills a buffer with audio data. * * C Specification: * ALvoid alBufferData(ALuint buffer,ALenum format,ALvoid *data,ALsizei size,ALsizei freq); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalBufferData (JNIEnv *env, jclass clazz, jint buffer, jint format, jobject data, jint offset, jint size, jint freq) { alBufferData(buffer, format, (void*) (offset + (ALubyte *)env->GetDirectBufferAddress(data)), size, freq); CHECK_AL_ERROR } /** * This function retrieves an integer property of a buffer. * * C Specification: * ALvoid alGetBufferi(ALuint buffer,ALenum pname,ALint *value); */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_AL10_alGetBufferi (JNIEnv *env, jclass clazz, jint buffer, jint pname) { ALint value = 0; alGetBufferi((ALuint) buffer, (ALenum) pname, &value); CHECK_AL_ERROR return value; } /** * This function retrieves a floating point property of a buffer. * * C Specification: * ALvoid alGetBufferf(ALuint buffer,ALenum pname,ALfloat *value); */ JNIEXPORT jfloat JNICALL Java_org_lwjgl_openal_AL10_alGetBufferf (JNIEnv *env, jclass clazz, jint buffer, jint pname) { ALfloat value = 0.0f; alGetBufferf((ALuint) buffer, (ALenum) pname, &value); CHECK_AL_ERROR return value; } /** * This function queues a set of buffers on a source. * * C Specification: * ALvoid alSourceQueueBuffers( ALuint source, ALsizei n, ALuint* buffers ); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourceQueueBuffers (JNIEnv *env, jclass clazz, jint source, jint n, jobject buffers, jint offset) { alSourceQueueBuffers((ALuint) source, (ALsizei) n, offset + (ALuint*) env->GetDirectBufferAddress(buffers)); CHECK_AL_ERROR } /** * This function unqueues a set of buffers attached to a source. * * C Specification: * ALvoid alSourceUnqueueBuffers( ALuint source, ALsizei n, ALuint* buffers ); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourceUnqueueBuffers (JNIEnv *env, jclass clazz, jint source, jint n, jobject buffers, jint offset) { alSourceUnqueueBuffers((ALuint) source, (ALsizei) n, offset + (ALuint*) env->GetDirectBufferAddress(buffers)); CHECK_AL_ERROR } /** * This function selects the OpenAL distance model. * * C Specification: * ALvoid alDistanceModel( ALenum value ); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alDistanceModel (JNIEnv *env, jclass clazz, jint value) { alDistanceModel((ALenum) value); CHECK_AL_ERROR } /** * This function selects the OpenAL Doppler factor value. * * C Specification: * ALvoid alDopplerFactor( ALfloat value ); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alDopplerFactor (JNIEnv *env, jclass clazz, jfloat value) { alDopplerFactor((ALfloat) value); CHECK_AL_ERROR } /** * This function selects the OpenAL Doppler velocity value. * * C Specification: * ALvoid alDopplerVelocity( ALfloat value ); */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alDopplerVelocity (JNIEnv *env, jclass clazz, jfloat value) { alDopplerVelocity((ALfloat) value); CHECK_AL_ERROR } --- NEW FILE: org_lwjgl_openal_AL10.h --- /* DO NOT EDIT THIS FILE - it is machine generated */ #include <jni.h> /* Header for class org_lwjgl_openal_AL10 */ #ifndef _Included_org_lwjgl_openal_AL10 #define _Included_org_lwjgl_openal_AL10 #ifdef __cplusplus extern "C" { #endif /* Inaccessible static: _00024assertionsDisabled */ #undef org_lwjgl_openal_AL10_AL_INVALID #define org_lwjgl_openal_AL10_AL_INVALID -1L #undef org_lwjgl_openal_AL10_AL_NONE #define org_lwjgl_openal_AL10_AL_NONE 0L #undef org_lwjgl_openal_AL10_AL_FALSE #define org_lwjgl_openal_AL10_AL_FALSE 0L #undef org_lwjgl_openal_AL10_AL_TRUE #define org_lwjgl_openal_AL10_AL_TRUE 1L #undef org_lwjgl_openal_AL10_AL_SOURCE_TYPE #define org_lwjgl_openal_AL10_AL_SOURCE_TYPE 512L #undef org_lwjgl_openal_AL10_AL_SOURCE_ABSOLUTE #define org_lwjgl_openal_AL10_AL_SOURCE_ABSOLUTE 513L #undef org_lwjgl_openal_AL10_AL_SOURCE_RELATIVE #define org_lwjgl_openal_AL10_AL_SOURCE_RELATIVE 514L #undef org_lwjgl_openal_AL10_AL_CONE_INNER_ANGLE #define org_lwjgl_openal_AL10_AL_CONE_INNER_ANGLE 4097L #undef org_lwjgl_openal_AL10_AL_CONE_OUTER_ANGLE #define org_lwjgl_openal_AL10_AL_CONE_OUTER_ANGLE 4098L #undef org_lwjgl_openal_AL10_AL_PITCH #define org_lwjgl_openal_AL10_AL_PITCH 4099L #undef org_lwjgl_openal_AL10_AL_POSITION #define org_lwjgl_openal_AL10_AL_POSITION 4100L #undef org_lwjgl_openal_AL10_AL_DIRECTION #define org_lwjgl_openal_AL10_AL_DIRECTION 4101L #undef org_lwjgl_openal_AL10_AL_VELOCITY #define org_lwjgl_openal_AL10_AL_VELOCITY 4102L #undef org_lwjgl_openal_AL10_AL_LOOPING #define org_lwjgl_openal_AL10_AL_LOOPING 4103L #undef org_lwjgl_openal_AL10_AL_BUFFER #define org_lwjgl_openal_AL10_AL_BUFFER 4105L #undef org_lwjgl_openal_AL10_AL_GAIN #define org_lwjgl_openal_AL10_AL_GAIN 4106L #undef org_lwjgl_openal_AL10_AL_MIN_GAIN #define org_lwjgl_openal_AL10_AL_MIN_GAIN 4109L #undef org_lwjgl_openal_AL10_AL_MAX_GAIN #define org_lwjgl_openal_AL10_AL_MAX_GAIN 4110L #undef org_lwjgl_openal_AL10_AL_ORIENTATION #define org_lwjgl_openal_AL10_AL_ORIENTATION 4111L #undef org_lwjgl_openal_AL10_AL_REFERENCE_DISTANCE #define org_lwjgl_openal_AL10_AL_REFERENCE_DISTANCE 4128L #undef org_lwjgl_openal_AL10_AL_ROLLOFF_FACTOR #define org_lwjgl_openal_AL10_AL_ROLLOFF_FACTOR 4129L #undef org_lwjgl_openal_AL10_AL_CONE_OUTER_GAIN #define org_lwjgl_openal_AL10_AL_CONE_OUTER_GAIN 4130L #undef org_lwjgl_openal_AL10_AL_MAX_DISTANCE #define org_lwjgl_openal_AL10_AL_MAX_DISTANCE 4131L #undef org_lwjgl_openal_AL10_AL_CHANNEL_MASK #define org_lwjgl_openal_AL10_AL_CHANNEL_MASK 12288L #undef org_lwjgl_openal_AL10_AL_SOURCE_STATE #define org_lwjgl_openal_AL10_AL_SOURCE_STATE 4112L #undef org_lwjgl_openal_AL10_AL_INITIAL #define org_lwjgl_openal_AL10_AL_INITIAL 4113L #undef org_lwjgl_openal_AL10_AL_PLAYING #define org_lwjgl_openal_AL10_AL_PLAYING 4114L #undef org_lwjgl_openal_AL10_AL_PAUSED #define org_lwjgl_openal_AL10_AL_PAUSED 4115L #undef org_lwjgl_openal_AL10_AL_STOPPED #define org_lwjgl_openal_AL10_AL_STOPPED 4116L #undef org_lwjgl_openal_AL10_AL_BUFFERS_QUEUED #define org_lwjgl_openal_AL10_AL_BUFFERS_QUEUED 4117L #undef org_lwjgl_openal_AL10_AL_BUFFERS_PROCESSED #define org_lwjgl_openal_AL10_AL_BUFFERS_PROCESSED 4118L #undef org_lwjgl_openal_AL10_AL_FORMAT_MONO8 #define org_lwjgl_openal_AL10_AL_FORMAT_MONO8 4352L #undef org_lwjgl_openal_AL10_AL_FORMAT_MONO16 #define org_lwjgl_openal_AL10_AL_FORMAT_MONO16 4353L #undef org_lwjgl_openal_AL10_AL_FORMAT_STEREO8 #define org_lwjgl_openal_AL10_AL_FORMAT_STEREO8 4354L #undef org_lwjgl_openal_AL10_AL_FORMAT_STEREO16 #define org_lwjgl_openal_AL10_AL_FORMAT_STEREO16 4355L #undef org_lwjgl_openal_AL10_AL_FORMAT_VORBIS_EXT #define org_lwjgl_openal_AL10_AL_FORMAT_VORBIS_EXT 65539L #undef org_lwjgl_openal_AL10_AL_FREQUENCY #define org_lwjgl_openal_AL10_AL_FREQUENCY 8193L #undef org_lwjgl_openal_AL10_AL_BITS #define org_lwjgl_openal_AL10_AL_BITS 8194L #undef org_lwjgl_openal_AL10_AL_CHANNELS #define org_lwjgl_openal_AL10_AL_CHANNELS 8195L #undef org_lwjgl_openal_AL10_AL_SIZE #define org_lwjgl_openal_AL10_AL_SIZE 8196L #undef org_lwjgl_openal_AL10_AL_DATA #define org_lwjgl_openal_AL10_AL_DATA 8197L #undef org_lwjgl_openal_AL10_AL_UNUSED #define org_lwjgl_openal_AL10_AL_UNUSED 8208L #undef org_lwjgl_openal_AL10_AL_PENDING #define org_lwjgl_openal_AL10_AL_PENDING 8209L #undef org_lwjgl_openal_AL10_AL_PROCESSED #define org_lwjgl_openal_AL10_AL_PROCESSED 8210L #undef org_lwjgl_openal_AL10_AL_NO_ERROR #define org_lwjgl_openal_AL10_AL_NO_ERROR 0L #undef org_lwjgl_openal_AL10_AL_INVALID_NAME #define org_lwjgl_openal_AL10_AL_INVALID_NAME 40961L #undef org_lwjgl_openal_AL10_AL_INVALID_ENUM #define org_lwjgl_openal_AL10_AL_INVALID_ENUM 40962L #undef org_lwjgl_openal_AL10_AL_INVALID_VALUE #define org_lwjgl_openal_AL10_AL_INVALID_VALUE 40963L #undef org_lwjgl_openal_AL10_AL_INVALID_OPERATION #define org_lwjgl_openal_AL10_AL_INVALID_OPERATION 40964L #undef org_lwjgl_openal_AL10_AL_OUT_OF_MEMORY #define org_lwjgl_openal_AL10_AL_OUT_OF_MEMORY 40965L #undef org_lwjgl_openal_AL10_AL_VENDOR #define org_lwjgl_openal_AL10_AL_VENDOR 45057L #undef org_lwjgl_openal_AL10_AL_VERSION #define org_lwjgl_openal_AL10_AL_VERSION 45058L #undef org_lwjgl_openal_AL10_AL_RENDERER #define org_lwjgl_openal_AL10_AL_RENDERER 45059L #undef org_lwjgl_openal_AL10_AL_EXTENSIONS #define org_lwjgl_openal_AL10_AL_EXTENSIONS 45060L #undef org_lwjgl_openal_AL10_AL_DOPPLER_FACTOR #define org_lwjgl_openal_AL10_AL_DOPPLER_FACTOR 49152L #undef org_lwjgl_openal_AL10_AL_DOPPLER_VELOCITY #define org_lwjgl_openal_AL10_AL_DOPPLER_VELOCITY 49153L #undef org_lwjgl_openal_AL10_AL_DISTANCE_MODEL #define org_lwjgl_openal_AL10_AL_DISTANCE_MODEL 53248L #undef org_lwjgl_openal_AL10_AL_INVERSE_DISTANCE #define org_lwjgl_openal_AL10_AL_INVERSE_DISTANCE 53249L #undef org_lwjgl_openal_AL10_AL_INVERSE_DISTANCE_CLAMPED #define org_lwjgl_openal_AL10_AL_INVERSE_DISTANCE_CLAMPED 53250L /* Inaccessible static: class_000240 */ /* * Class: org_lwjgl_openal_AL10 * Method: alEnable * Signature: (I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alEnable (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alDisable * Signature: (I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alDisable (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alIsEnabled * Signature: (I)Z */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_openal_AL10_alIsEnabled (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alHint * Signature: (II)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alHint (JNIEnv *, jclass, jint, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alGetBoolean * Signature: (I)Z */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_openal_AL10_alGetBoolean (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alGetInteger * Signature: (I)I */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_AL10_alGetInteger (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alGetFloat * Signature: (I)F */ JNIEXPORT jfloat JNICALL Java_org_lwjgl_openal_AL10_alGetFloat (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalGetBooleanv * Signature: (ILjava/nio/ByteBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalGetBooleanv (JNIEnv *, jclass, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalGetIntegerv * Signature: (ILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalGetIntegerv (JNIEnv *, jclass, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalGetFloatv * Signature: (ILjava/nio/FloatBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalGetFloatv (JNIEnv *, jclass, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alGetString * Signature: (I)Ljava/lang/String; */ JNIEXPORT jstring JNICALL Java_org_lwjgl_openal_AL10_alGetString (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alGetError * Signature: ()I */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_AL10_alGetError (JNIEnv *, jclass); /* * Class: org_lwjgl_openal_AL10 * Method: alIsExtensionPresent * Signature: (Ljava/lang/String;)Z */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_openal_AL10_alIsExtensionPresent (JNIEnv *, jclass, jstring); /* * Class: org_lwjgl_openal_AL10 * Method: alGetEnumValue * Signature: (Ljava/lang/String;)I */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_AL10_alGetEnumValue (JNIEnv *, jclass, jstring); /* * Class: org_lwjgl_openal_AL10 * Method: alListeneri * Signature: (II)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alListeneri (JNIEnv *, jclass, jint, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alListenerf * Signature: (IF)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alListenerf (JNIEnv *, jclass, jint, jfloat); /* * Class: org_lwjgl_openal_AL10 * Method: nalListenerfv * Signature: (ILjava/nio/FloatBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalListenerfv (JNIEnv *, jclass, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alListener3f * Signature: (IFFF)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alListener3f (JNIEnv *, jclass, jint, jfloat, jfloat, jfloat); /* * Class: org_lwjgl_openal_AL10 * Method: alGetListeneri * Signature: (I)I */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_AL10_alGetListeneri (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alGetListenerf * Signature: (I)F */ JNIEXPORT jfloat JNICALL Java_org_lwjgl_openal_AL10_alGetListenerf (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalGetListenerfv * Signature: (ILjava/nio/FloatBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalGetListenerfv (JNIEnv *, jclass, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalGenSources * Signature: (ILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalGenSources (JNIEnv *, jclass, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalDeleteSources * Signature: (ILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalDeleteSources (JNIEnv *, jclass, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alIsSource * Signature: (I)Z */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_openal_AL10_alIsSource (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alSourcei * Signature: (III)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSourcei (JNIEnv *, jclass, jint, jint, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alSourcef * Signature: (IIF)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSourcef (JNIEnv *, jclass, jint, jint, jfloat); /* * Class: org_lwjgl_openal_AL10 * Method: nalSourcefv * Signature: (IILjava/nio/FloatBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourcefv (JNIEnv *, jclass, jint, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alSource3f * Signature: (IIFFF)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSource3f (JNIEnv *, jclass, jint, jint, jfloat, jfloat, jfloat); /* * Class: org_lwjgl_openal_AL10 * Method: alGetSourcei * Signature: (II)I */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_AL10_alGetSourcei (JNIEnv *, jclass, jint, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alGetSourcef * Signature: (II)F */ JNIEXPORT jfloat JNICALL Java_org_lwjgl_openal_AL10_alGetSourcef (JNIEnv *, jclass, jint, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalGetSourcefv * Signature: (IILjava/nio/FloatBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalGetSourcefv (JNIEnv *, jclass, jint, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalSourcePlayv * Signature: (ILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourcePlayv (JNIEnv *, jclass, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalSourcePausev * Signature: (ILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourcePausev (JNIEnv *, jclass, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalSourceStopv * Signature: (ILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourceStopv (JNIEnv *, jclass, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalSourceRewindv * Signature: (ILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourceRewindv (JNIEnv *, jclass, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alSourcePlay * Signature: (I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSourcePlay (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alSourcePause * Signature: (I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSourcePause (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alSourceStop * Signature: (I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSourceStop (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alSourceRewind * Signature: (I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alSourceRewind (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalGenBuffers * Signature: (ILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalGenBuffers (JNIEnv *, jclass, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalDeleteBuffers * Signature: (ILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalDeleteBuffers (JNIEnv *, jclass, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alIsBuffer * Signature: (I)Z */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_openal_AL10_alIsBuffer (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalBufferData * Signature: (IILjava/nio/ByteBuffer;III)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalBufferData (JNIEnv *, jclass, jint, jint, jobject, jint, jint, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alGetBufferi * Signature: (II)I */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_AL10_alGetBufferi (JNIEnv *, jclass, jint, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alGetBufferf * Signature: (II)F */ JNIEXPORT jfloat JNICALL Java_org_lwjgl_openal_AL10_alGetBufferf (JNIEnv *, jclass, jint, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalSourceQueueBuffers * Signature: (IILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourceQueueBuffers (JNIEnv *, jclass, jint, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: nalSourceUnqueueBuffers * Signature: (IILjava/nio/IntBuffer;I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_nalSourceUnqueueBuffers (JNIEnv *, jclass, jint, jint, jobject, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alDistanceModel * Signature: (I)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alDistanceModel (JNIEnv *, jclass, jint); /* * Class: org_lwjgl_openal_AL10 * Method: alDopplerFactor * Signature: (F)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alDopplerFactor (JNIEnv *, jclass, jfloat); /* * Class: org_lwjgl_openal_AL10 * Method: alDopplerVelocity * Signature: (F)V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_AL10_alDopplerVelocity (JNIEnv *, jclass, jfloat); #ifdef __cplusplus } #endif #endif --- NEW FILE: org_lwjgl_openal_eax_EAX.cpp --- /* * Copyright (c) 2002-2004 Lightweight Java Game Library Project * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are * met: * * * Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * * Neither the name of 'Lightweight Java Game Library' nor the names of * its contributors may be used to endorse or promote products derived * from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include "org_lwjgl_openal_eax_EAX.h" /* * Class: org_lwjgl_openal_eax_EAX * Method: nCreate * Signature: ()Z */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_openal_eax_EAX_nCreate (JNIEnv *env, jclass clazz) { #ifdef _WIN32 return true; #else return false; #endif } /* * Class: org_lwjgl_openal_eax_EAX * Method: nDestroy * Signature: ()V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_eax_EAX_nDestroy (JNIEnv *env, jclass clazz) { } --- NEW FILE: org_lwjgl_openal_eax_EAX.h --- /* DO NOT EDIT THIS FILE - it is machine generated */ #include <jni.h> /* Header for class org_lwjgl_openal_eax_EAX */ #ifndef _Included_org_lwjgl_openal_eax_EAX #define _Included_org_lwjgl_openal_eax_EAX #ifdef __cplusplus extern "C" { #endif /* Inaccessible static: created */ /* * Class: org_lwjgl_openal_eax_EAX * Method: nCreate * Signature: ()Z */ JNIEXPORT jboolean JNICALL Java_org_lwjgl_openal_eax_EAX_nCreate (JNIEnv *, jclass); /* * Class: org_lwjgl_openal_eax_EAX * Method: nDestroy * Signature: ()V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_eax_EAX_nDestroy (JNIEnv *, jclass); #ifdef __cplusplus } #endif #endif --- NEW FILE: org_lwjgl_openal_eax_EAX20.cpp --- /* * Copyright (c) 2002-2004 Lightweight Java Game Library Project * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are * met: * * * Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * * Neither the name of 'Lightweight Java Game Library' nor the names of * its contributors may be used to endorse or promote products derived * from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ /** * $Id: org_lwjgl_openal_eax_EAX20.cpp,v 1.1 2004/02/26 21:51:58 matzon Exp $ * * This is the actual JNI implementation of the OpenAL EAX library. * * @author Brian Matzon <br...@ma...> * @version $Revision: 1.1 $ */ #include "org_lwjgl_openal_eax_EAX20.h" /* OpenAL includes */ #include "checkALerror.h" #include "common_tools.h" #include "extal.h" /* * Determines available EAX extensions */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_eax_EAX20_determineAvailableExtensions (JNIEnv *env, jclass clazz) { #ifdef _WIN32 bool EAXSupported = false; //check that we have a current context if(alcGetCurrentContext() == NULL) { throwOpenALException(env, "Unable to determine EAX Extensions: No current context"); } //check for extension, and assign if available if(alIsExtensionPresent((ALubyte*) "EAX") == AL_TRUE) { eaxSet = (EAXSet)alGetProcAddress((ALubyte*) "EAXSet"); eaxGet = (EAXGet)alGetProcAddress((ALubyte*) "EAXGet"); EAXSupported = (eaxSet != NULL && eaxGet != NULL); } //throw exception if no EAX support if(EAXSupported != true) { throwOpenALException(env, "Unable to determine EAX Extensions"); } #else throwOpenALException(env, "EAX extensions not supported"); #endif } /* * This function retrieves an EAX value. * * C Specification: * ALenum EAXGet(const struct _GUID *propertySetID,ALuint property,ALuint source,ALvoid * *value,ALuint size); */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_eax_EAX20_neaxGet (JNIEnv *env, jclass clazz, jint propertySetID, jint property, jint source, jobject value, jint offset, jint size) { #ifdef _WIN32 jint result = 0; // determine buffer or listener if (propertySetID == org_lwjgl_openal_eax_EAX20_BUFFER_GUID) { result = (jint) eaxGet(&DSPROPSETID_EAX20_BufferProperties, (ALuint) property, (ALuint) source, (ALvoid*) (offset + (const char*) env->GetDirectBufferAddress(value)), (ALuint) size); } else if (propertySetID == org_lwjgl_openal_eax_EAX20_LISTENER_GUID) { result = (jint) eaxGet(&DSPROPSETID_EAX20_ListenerProperties, (ALuint) property, (ALuint) source, (ALvoid*) (offset + (const char*) env->GetDirectBufferAddress(value)), (ALuint) size); } CHECK_AL_ERROR return result; #else throwOpenALException(env, "EAX extensions not supported"); return 0; #endif } /* * This function sets an EAX value. * * C Specification: * ALenum EAXSet(const struct _GUID *propertySetID,ALuint property,ALuint source,ALvoid * *value,ALuint size); */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_eax_EAX20_neaxSet (JNIEnv *env, jclass clazz, jint propertySetID, jint property, jint source, jobject value, jint offset, jint size) { #ifdef _WIN32 jint result = 0; // determine buffer or listener if (propertySetID == org_lwjgl_openal_eax_EAX20_BUFFER_GUID) { result = (jint) eaxSet(&DSPROPSETID_EAX20_BufferProperties, (ALuint) (property), source, (ALvoid*) (offset + (const char*) env->GetDirectBufferAddress(value)), (ALuint) size); } else if (propertySetID == org_lwjgl_openal_eax_EAX20_LISTENER_GUID) { result = (jint) eaxSet(&DSPROPSETID_EAX20_ListenerProperties, (ALuint) (property), source, (ALvoid*) (offset + (const char*) env->GetDirectBufferAddress(value)), (ALuint) size); } CHECK_AL_ERROR return result; #else throwOpenALException(env, "EAX extensions not supported"); return 0; #endif } --- NEW FILE: org_lwjgl_openal_eax_EAX20.h --- /* DO NOT EDIT THIS FILE - it is machine generated */ #include <jni.h> /* Header for class org_lwjgl_openal_eax_EAX20 */ #ifndef _Included_org_lwjgl_openal_eax_EAX20 #define _Included_org_lwjgl_openal_eax_EAX20 #ifdef __cplusplus extern "C" { #endif #undef org_lwjgl_openal_eax_EAX20_BUFFER_GUID #define org_lwjgl_openal_eax_EAX20_BUFFER_GUID 1L #undef org_lwjgl_openal_eax_EAX20_LISTENER_GUID #define org_lwjgl_openal_eax_EAX20_LISTENER_GUID 2L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_GENERIC #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_GENERIC 0L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_PADDEDCELL #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_PADDEDCELL 1L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_ROOM #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_ROOM 2L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_BATHROOM #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_BATHROOM 3L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_LIVINGROOM #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_LIVINGROOM 4L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_STONEROOM #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_STONEROOM 5L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_AUDITORIUM #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_AUDITORIUM 6L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_CONCERTHALL #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_CONCERTHALL 7L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_CAVE #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_CAVE 8L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_ARENA #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_ARENA 9L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_HANGAR #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_HANGAR 10L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_CARPETEDHALLWAY #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_CARPETEDHALLWAY 11L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_HALLWAY #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_HALLWAY 12L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_STONECORRIDOR #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_STONECORRIDOR 13L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_ALLEY #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_ALLEY 14L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_FOREST #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_FOREST 15L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_CITY #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_CITY 16L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_MOUNTAINS #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_MOUNTAINS 17L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_QUARRY #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_QUARRY 18L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_PLAIN #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_PLAIN 19L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_PARKINGLOT #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_PARKINGLOT 20L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_SEWERPIPE #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_SEWERPIPE 21L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_UNDERWATER #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_UNDERWATER 22L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_DRUGGED #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_DRUGGED 23L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_DIZZY #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_DIZZY 24L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_PSYCHOTIC #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_PSYCHOTIC 25L #undef org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_COUNT #define org_lwjgl_openal_eax_EAX20_EAX_ENVIRONMENT_COUNT 26L #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_SINGLEWINDOW #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_SINGLEWINDOW -2800L #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_SINGLEWINDOWLF #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_SINGLEWINDOWLF 0.71f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_SINGLEWINDOWROOMRATIO #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_SINGLEWINDOWROOMRATIO 0.43f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_DOUBLEWINDOW #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_DOUBLEWINDOW -5000L #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_DOUBLEWINDOWHF #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_DOUBLEWINDOWHF 0.4f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_DOUBLEWINDOWROOMRATIO #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_DOUBLEWINDOWROOMRATIO 0.24f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_THINDOOR #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_THINDOOR -1800L #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_THINDOORLF #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_THINDOORLF 0.66f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_THINDOORROOMRATIO #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_THINDOORROOMRATIO 0.66f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_THICKDOOR #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_THICKDOOR -4400L #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_THICKDOORLF #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_THICKDOORLF 0.64f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_THICKDOORROOMRTATION #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_THICKDOORROOMRTATION 0.27f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_WOODWALL #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_WOODWALL -4000L #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_WOODWALLLF #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_WOODWALLLF 0.5f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_WOODWALLROOMRATIO #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_WOODWALLROOMRATIO 0.3f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_BRICKWALL #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_BRICKWALL -5000L #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_BRICKWALLLF #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_BRICKWALLLF 0.6f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_BRICKWALLROOMRATIO #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_BRICKWALLROOMRATIO 0.24f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_STONEWALL #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_STONEWALL -6000L #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_STONEWALLLF #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_STONEWALLLF 0.68f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_STONEWALLROOMRATIO #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_STONEWALLROOMRATIO 0.2f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_CURTAIN #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_CURTAIN -1200L #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_CURTAINLF #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_CURTAINLF 0.15f #undef org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_CURTAINROOMRATIO #define org_lwjgl_openal_eax_EAX20_EAX_MATERIAL_CURTAINROOMRATIO 1.0f /* * Class: org_lwjgl_openal_eax_EAX20 * Method: determineAvailableExtensions * Signature: ()V */ JNIEXPORT void JNICALL Java_org_lwjgl_openal_eax_EAX20_determineAvailableExtensions (JNIEnv *, jclass); /* * Class: org_lwjgl_openal_eax_EAX20 * Method: neaxGet * Signature: (IIILjava/nio/Buffer;II)I */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_eax_EAX20_neaxGet (JNIEnv *, jclass, jint, jint, jint, jobject, jint, jint); /* * Class: org_lwjgl_openal_eax_EAX20 * Method: neaxSet * Signature: (IIILjava/nio/Buffer;II)I */ JNIEXPORT jint JNICALL Java_org_lwjgl_openal_eax_EAX20_neaxSet (JNIEnv *, jclass, jint, jint, jint, jobject, jint, jint); #ifdef __cplusplus } #endif #endif Index: Makefile.am =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/Makefile.am,v retrieving revision 1.19 retrieving revision 1.20 diff -u -d -r1.19 -r1.20 --- Makefile.am 25 Feb 2004 18:08:57 -0000 1.19 +++ Makefile.am 26 Feb 2004 21:51:58 -0000 1.20 @@ -22,14 +22,14 @@ org_lwjgl_input_Mouse.h \ org_lwjgl_openal_ALC.cpp \ org_lwjgl_openal_ALC.h \ - org_lwjgl_openal_BaseAL.cpp \ - org_lwjgl_openal_BaseAL.h \ - org_lwjgl_openal_CoreAL.cpp \ - org_lwjgl_openal_CoreAL.h \ - org_lwjgl_openal_eax_BaseEAX.cpp \ - org_lwjgl_openal_eax_BaseEAX.h \ - org_lwjgl_openal_eax_CoreEAX.cpp \ - org_lwjgl_openal_eax_CoreEAX.h \ + org_lwjgl_openal_AL.cpp \ + org_lwjgl_openal_AL.h \ + org_lwjgl_openal_AL10.cpp \ + org_lwjgl_openal_AL10.h \ + org_lwjgl_openal_eax_EAX.cpp \ + org_lwjgl_openal_eax_EAX.h \ + org_lwjgl_openal_eax_EAX20.cpp \ + org_lwjgl_openal_eax_EAX.h \ org_lwjgl_openal_eax_EAXBufferProperties.cpp \ org_lwjgl_openal_eax_EAXBufferProperties.h \ org_lwjgl_openal_eax_EAXListenerProperties.cpp \ --- org_lwjgl_openal_BaseAL.cpp DELETED --- --- org_lwjgl_openal_BaseAL.h DELETED --- --- org_lwjgl_openal_CoreAL.cpp DELETED --- --- org_lwjgl_openal_CoreAL.h DELETED --- --- org_lwjgl_openal_eax_BaseEAX.cpp DELETED --- --- org_lwjgl_openal_eax_BaseEAX.h DELETED --- --- org_lwjgl_openal_eax_CoreEAX.cpp DELETED --- --- org_lwjgl_openal_eax_CoreEAX.h DELETED --- |
|
From: <ma...@us...> - 2004-02-26 22:08:07
|
Update of /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/test/openal In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6429/java/org/lwjgl/test/openal Modified Files: BasicTest.java EAXTest.java MovingSoundTest.java OpenALCreationTest.java PlayTest.java PlayTestMemory.java PositionTest.java SourceLimitTest.java StressTest.java WaveData.java Log Message: OpenAL / EAX Refactor Index: BasicTest.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/test/openal/BasicTest.java,v retrieving revision 1.13 retrieving revision 1.14 diff -u -d -r1.13 -r1.14 --- BasicTest.java 8 Feb 2004 20:32:09 -0000 1.13 +++ BasicTest.java 26 Feb 2004 21:51:57 -0000 1.14 @@ -37,6 +37,7 @@ import java.nio.IntBuffer; import org.lwjgl.openal.AL; +import org.lwjgl.openal.AL10; /** * $Id$ @@ -115,7 +116,7 @@ * @param error Error code causing exit */ protected void exit(int error) { - System.out.println("OpenAL Error: " + AL.alGetString(error)); + System.out.println("OpenAL Error: " + AL10.alGetString(error)); alExit(); System.exit(-1); } Index: EAXTest.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/test/openal/EAXTest.java,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- EAXTest.java 8 Feb 2004 20:32:09 -0000 1.11 +++ EAXTest.java 26 Feb 2004 21:51:58 -0000 1.12 @@ -38,7 +38,9 @@ import org.lwjgl.Sys; import org.lwjgl.openal.AL; +import org.lwjgl.openal.AL10; import org.lwjgl.openal.eax.EAX; +import org.lwjgl.openal.eax.EAX20; import org.lwjgl.openal.eax.EAXBufferProperties; import org.lwjgl.openal.eax.EAXListenerProperties; @@ -94,9 +96,9 @@ runTest(); // kill sources and buffers - AL.alSourceStop(soundSources.get(0)); - AL.alDeleteSources(soundSources); - AL.alDeleteBuffers(soundBuffers); + AL10.alSourceStop(soundSources.get(0)); + AL10.alDeleteSources(soundSources); + AL10.alDeleteBuffers(soundBuffers); EAX.destroy(); } @@ -108,22 +110,22 @@ private boolean initialize() { // creating buffers Sys.log("Creating buffers"); - AL.alGenBuffers(soundBuffers); + AL10.alGenBuffers(soundBuffers); soundBuffers.rewind(); // creating sources Sys.log("Creating sources"); - AL.alGenSources(soundSources); + AL10.alGenSources(soundSources); soundSources.rewind(); // load sound files (left, center, right).wav Sys.log("Loading Footsteps.wav"); WaveData footsteps = WaveData.create("Footsteps.wav"); - AL.alBufferData(soundBuffers.get(0), footsteps.format, footsteps.data, footsteps.data.capacity(), footsteps.samplerate); - AL.alSourcef(soundSources.get(0), AL.AL_PITCH, 1.0f); - AL.alSourcef(soundSources.get(0), AL.AL_GAIN, 1.0f); - AL.alSourcei(soundSources.get(0), AL.AL_BUFFER, soundBuffers.get(0)); - AL.alSourcei(soundSources.get(0), AL.AL_LOOPING, AL.AL_TRUE); + AL10.alBufferData(soundBuffers.get(0), footsteps.format, footsteps.data, footsteps.data.capacity(), footsteps.samplerate); + AL10.alSourcef(soundSources.get(0), AL10.AL_PITCH, 1.0f); + AL10.alSourcef(soundSources.get(0), AL10.AL_GAIN, 1.0f); + AL10.alSourcei(soundSources.get(0), AL10.AL_BUFFER, soundBuffers.get(0)); + AL10.alSourcei(soundSources.get(0), AL10.AL_LOOPING, AL10.AL_TRUE); // create eax property objects listenerProperties = new EAXListenerProperties(); @@ -132,7 +134,7 @@ // set buffer to work on source 0 bufferProperties.setCurrentSource(soundSources.get(0)); - return AL.alGetError() == AL.AL_NO_ERROR; + return AL10.alGetError() == AL10.AL_NO_ERROR; } /** @@ -142,7 +144,7 @@ boolean running = true; char key; - assert AL.alIsBuffer(soundBuffers.get(0)) : "Failed to validate buffer"; + assert AL10.alIsBuffer(soundBuffers.get(0)) : "Failed to validate buffer"; // handle menu do { @@ -152,25 +154,25 @@ switch (key) { // play sound case '1' : { - AL.alSourcePlay(soundSources.get(0)); + AL10.alSourcePlay(soundSources.get(0)); break; } // stop sound case '2' : { - AL.alSourceStop(soundSources.get(0)); + AL10.alSourceStop(soundSources.get(0)); break; } // add reverb case '3' : { - listenerProperties.setEnvironment(EAX.EAX_ENVIRONMENT_HANGAR); + listenerProperties.setEnvironment(EAX20.EAX_ENVIRONMENT_HANGAR); break; } // remove reverb case '4' : { - listenerProperties.setEnvironment(EAX.EAX_ENVIRONMENT_GENERIC); + listenerProperties.setEnvironment(EAX20.EAX_ENVIRONMENT_GENERIC); break; } Index: MovingSoundTest.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/test/openal/MovingSoundTest.java,v retrieving revision 1.26 retrieving revision 1.27 diff -u -d -r1.26 -r1.27 --- MovingSoundTest.java 15 Feb 2004 15:34:56 -0000 1.26 +++ MovingSoundTest.java 26 Feb 2004 21:51:58 -0000 1.27 @@ -34,8 +34,9 @@ import java.nio.IntBuffer; import org.lwjgl.input.Keyboard; -import org.lwjgl.openal.AL; +import org.lwjgl.openal.AL10; import org.lwjgl.openal.eax.EAX; +import org.lwjgl.openal.eax.EAX20; import org.lwjgl.openal.eax.EAXListenerProperties; import org.lwjgl.opengl.Window; import org.lwjgl.vector.Vector3f; @@ -96,14 +97,14 @@ // al generate buffers and sources buffers.position(0).limit(1); - AL.alGenBuffers(buffers); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alGenBuffers(buffers); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } sources.position(0).limit(1); - AL.alGenSources(sources); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alGenSources(sources); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } @@ -111,13 +112,13 @@ WaveData wavefile = WaveData.create(args[0]); //copy to buffers - AL.alBufferData( + AL10.alBufferData( buffers.get(0), wavefile.format, wavefile.data, wavefile.data.capacity(), wavefile.samplerate); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } @@ -125,28 +126,28 @@ wavefile.dispose(); //set up source input - AL.alSourcei(sources.get(0), AL.AL_BUFFER, buffers.get(0)); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourcei(sources.get(0), AL10.AL_BUFFER, buffers.get(0)); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } - AL.alSourcef(sources.get(0), AL.AL_REFERENCE_DISTANCE, 1024.0f); - AL.alSourcef(sources.get(0), AL.AL_ROLLOFF_FACTOR, 0.5f); + AL10.alSourcef(sources.get(0), AL10.AL_REFERENCE_DISTANCE, 1024.0f); + AL10.alSourcef(sources.get(0), AL10.AL_ROLLOFF_FACTOR, 0.5f); //lets loop the sound - AL.alSourcei(sources.get(0), AL.AL_LOOPING, AL.AL_TRUE); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourcei(sources.get(0), AL10.AL_LOOPING, AL10.AL_TRUE); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //play source 0 - AL.alSourcePlay(sources.get(0)); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourcePlay(sources.get(0)); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //setup EAX if possible - if (AL.alIsExtensionPresent("EAX")) { + if (AL10.alIsExtensionPresent("EAX")) { try { EAX.create(); eaxListenerProp = new EAXListenerProperties(); @@ -163,31 +164,31 @@ if(Keyboard.isKeyDown(Keyboard.KEY_LEFT)) { if(Keyboard.isKeyDown(Keyboard.KEY_RSHIFT)) { listenerPosition.x -= MOVEMENT; - AL.alListener3f(AL.AL_POSITION, listenerPosition.x, listenerPosition.y, listenerPosition.z); + AL10.alListener3f(AL10.AL_POSITION, listenerPosition.x, listenerPosition.y, listenerPosition.z); System.out.println("listenerx: " + listenerPosition.x); } else { sourcePosition.x -= MOVEMENT; - AL.alSource3f(sources.get(0), AL.AL_POSITION, sourcePosition.x, sourcePosition.y, sourcePosition.z); + AL10.alSource3f(sources.get(0), AL10.AL_POSITION, sourcePosition.x, sourcePosition.y, sourcePosition.z); System.out.println("sourcex: " + sourcePosition.x); } } if(Keyboard.isKeyDown(Keyboard.KEY_RIGHT)) { if(Keyboard.isKeyDown(Keyboard.KEY_RSHIFT)) { listenerPosition.x += MOVEMENT; - AL.alListener3f(AL.AL_POSITION, listenerPosition.x, listenerPosition.y, listenerPosition.z); + AL10.alListener3f(AL10.AL_POSITION, listenerPosition.x, listenerPosition.y, listenerPosition.z); System.out.println("listenerx: " + listenerPosition.x); } else { sourcePosition.x += MOVEMENT; - AL.alSource3f(sources.get(0), AL.AL_POSITION, sourcePosition.x, sourcePosition.y, sourcePosition.z); + AL10.alSource3f(sources.get(0), AL10.AL_POSITION, sourcePosition.x, sourcePosition.y, sourcePosition.z); System.out.println("sourcex: " + sourcePosition.x); } } if(Keyboard.isKeyDown(Keyboard.KEY_E)) { if(eaxApplied) { - eaxListenerProp.setEnvironment(EAX.EAX_ENVIRONMENT_GENERIC); + eaxListenerProp.setEnvironment(EAX20.EAX_ENVIRONMENT_GENERIC); } else { - eaxListenerProp.setEnvironment(EAX.EAX_ENVIRONMENT_HANGAR); + eaxListenerProp.setEnvironment(EAX20.EAX_ENVIRONMENT_HANGAR); } eaxApplied = !eaxApplied; } @@ -203,21 +204,21 @@ } //stop source 0 - AL.alSourceStop(sources.get(0)); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourceStop(sources.get(0)); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //delete buffers and sources sources.position(0).limit(1); - AL.alDeleteSources(sources); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alDeleteSources(sources); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } buffers.position(0).limit(1); - AL.alDeleteBuffers(buffers); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alDeleteBuffers(buffers); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } Index: OpenALCreationTest.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/test/openal/OpenALCreationTest.java,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- OpenALCreationTest.java 8 Feb 2004 20:32:09 -0000 1.8 +++ OpenALCreationTest.java 26 Feb 2004 21:51:58 -0000 1.9 @@ -36,6 +36,7 @@ import java.nio.IntBuffer; import org.lwjgl.openal.AL; +import org.lwjgl.openal.AL10; /** * $Id$ @@ -87,7 +88,7 @@ * @param error Error code causing exit */ protected void exit(int error) { - System.out.println("OpenAL Error: " + AL.alGetString(error)); + System.out.println("OpenAL Error: " + AL10.alGetString(error)); alExit(); System.exit(-1); } @@ -137,14 +138,14 @@ // al generate buffers and sources buffers.position(0).limit(1); - AL.alGenBuffers(buffers); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alGenBuffers(buffers); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } sources.position(0).limit(1); - AL.alGenSources(sources); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alGenSources(sources); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } @@ -152,13 +153,13 @@ WaveData wavefile = WaveData.create("Footsteps.wav"); //copy to buffers - AL.alBufferData( + AL10.alBufferData( buffers.get(0), wavefile.format, wavefile.data, wavefile.data.capacity(), wavefile.samplerate); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } @@ -166,20 +167,20 @@ wavefile.dispose(); //set up source input - AL.alSourcei(sources.get(0), AL.AL_BUFFER, buffers.get(0)); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourcei(sources.get(0), AL10.AL_BUFFER, buffers.get(0)); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //lets loop the sound - AL.alSourcei(sources.get(0), AL.AL_LOOPING, AL.AL_TRUE); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourcei(sources.get(0), AL10.AL_LOOPING, AL10.AL_TRUE); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //play source 0 - AL.alSourcePlay(sources.get(0)); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourcePlay(sources.get(0)); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } @@ -192,21 +193,21 @@ System.out.println("done"); //stop source 0 - AL.alSourceStop(sources.get(0)); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourceStop(sources.get(0)); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //delete buffers and sources sources.position(0).limit(1); - AL.alDeleteSources(sources); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alDeleteSources(sources); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } buffers.position(0).limit(1); - AL.alDeleteBuffers(buffers); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alDeleteBuffers(buffers); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } } Index: PlayTest.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/test/openal/PlayTest.java,v retrieving revision 1.13 retrieving revision 1.14 diff -u -d -r1.13 -r1.14 --- PlayTest.java 8 Feb 2004 20:32:10 -0000 1.13 +++ PlayTest.java 26 Feb 2004 21:51:58 -0000 1.14 @@ -37,7 +37,7 @@ import java.nio.ByteOrder; import java.nio.IntBuffer; -import org.lwjgl.openal.AL; +import org.lwjgl.openal.AL10; /** * $Id$ @@ -70,7 +70,7 @@ if(args[0].endsWith(".ogg")) { System.out.print("Attempting to load Ogg Vorbis file, checking for extension..."); - if(AL.alIsExtensionPresent("AL_EXT_vorbis")) { + if(AL10.alIsExtensionPresent("AL_EXT_vorbis")) { System.out.println("found"); usingVorbis = true; } else { @@ -88,14 +88,14 @@ // al generate buffers and sources buffers.position(0).limit(1); - AL.alGenBuffers(buffers); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alGenBuffers(buffers); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } sources.position(0).limit(1); - AL.alGenSources(sources); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alGenSources(sources); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } @@ -103,38 +103,38 @@ ByteBuffer filebuffer = getData(args[0]); // pass directly to buffer data - AL.alBufferData(buffers.get(0), AL.AL_FORMAT_VORBIS_EXT, filebuffer, -1, -1); + AL10.alBufferData(buffers.get(0), AL10.AL_FORMAT_VORBIS_EXT, filebuffer, -1, -1); filebuffer.clear(); } else { // load wave data from buffer WaveData wavefile = WaveData.create(args[0]); //copy to buffers - AL.alBufferData(buffers.get(0), wavefile.format, wavefile.data, wavefile.data.capacity(), wavefile.samplerate); + AL10.alBufferData(buffers.get(0), wavefile.format, wavefile.data, wavefile.data.capacity(), wavefile.samplerate); //unload file again wavefile.dispose(); } - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //set up source input - AL.alSourcei(sources.get(0), AL.AL_BUFFER, buffers.get(0)); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourcei(sources.get(0), AL10.AL_BUFFER, buffers.get(0)); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //lets loop the sound - AL.alSourcei(sources.get(0), AL.AL_LOOPING, AL.AL_TRUE); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourcei(sources.get(0), AL10.AL_LOOPING, AL10.AL_TRUE); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //play source 0 - AL.alSourcePlay(sources.get(0)); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourcePlay(sources.get(0)); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } @@ -146,21 +146,21 @@ } //stop source 0 - AL.alSourceStop(sources.get(0)); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourceStop(sources.get(0)); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //delete buffers and sources sources.position(0).limit(1); - AL.alDeleteSources(sources); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alDeleteSources(sources); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } buffers.position(0).limit(1); - AL.alDeleteBuffers(buffers); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alDeleteBuffers(buffers); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } Index: PlayTestMemory.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/test/openal/PlayTestMemory.java,v retrieving revision 1.14 retrieving revision 1.15 diff -u -d -r1.14 -r1.15 --- PlayTestMemory.java 8 Feb 2004 20:32:10 -0000 1.14 +++ PlayTestMemory.java 26 Feb 2004 21:51:58 -0000 1.15 @@ -37,7 +37,7 @@ import java.nio.ByteOrder; import java.nio.IntBuffer; -import org.lwjgl.openal.AL; +import org.lwjgl.openal.AL10; /** * $Id$ @@ -70,7 +70,7 @@ if(args[0].endsWith(".ogg")) { System.out.print("Attempting to load Ogg Vorbis file, checking for extension..."); - if(AL.alIsExtensionPresent("AL_EXT_vorbis")) { + if(AL10.alIsExtensionPresent("AL_EXT_vorbis")) { System.out.println("found"); usingVorbis = true; } else { @@ -88,14 +88,14 @@ // al generate buffers and sources buffers.position(0).limit(1); - AL.alGenBuffers(buffers); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alGenBuffers(buffers); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } sources.position(0).limit(1); - AL.alGenSources(sources); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alGenSources(sources); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } @@ -111,40 +111,40 @@ //ALUTLoadWAVData file = alut.loadWAVMemory(Sys.getDirectBufferAddress(filebuffer)); if(usingVorbis) { // pass directly to buffer data - AL.alBufferData(buffers.get(0), AL.AL_FORMAT_VORBIS_EXT, filebuffer, -1, -1); + AL10.alBufferData(buffers.get(0), AL10.AL_FORMAT_VORBIS_EXT, filebuffer, -1, -1); filebuffer.clear(); } else { // load wave data from buffer WaveData wavefile = WaveData.create(filebuffer.array()); //copy to buffers - AL.alBufferData(buffers.get(0), wavefile.format, wavefile.data, wavefile.data.capacity(), wavefile.samplerate); + AL10.alBufferData(buffers.get(0), wavefile.format, wavefile.data, wavefile.data.capacity(), wavefile.samplerate); //unload file again wavefile.dispose(); } // check for errors - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //set up source input - AL.alSourcei(sources.get(0), AL.AL_BUFFER, buffers.get(0)); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourcei(sources.get(0), AL10.AL_BUFFER, buffers.get(0)); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //lets loop the sound - AL.alSourcei(sources.get(0), AL.AL_LOOPING, AL.AL_TRUE); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourcei(sources.get(0), AL10.AL_LOOPING, AL10.AL_TRUE); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //play source 0 - AL.alSourcePlay(sources.get(0)); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourcePlay(sources.get(0)); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } @@ -156,21 +156,21 @@ } //stop source 0 - AL.alSourceStop(sources.get(0)); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alSourceStop(sources.get(0)); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } //delete buffers and sources sources.position(0).limit(1); - AL.alDeleteSources(sources); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alDeleteSources(sources); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } buffers.position(0).limit(1); - AL.alDeleteBuffers(buffers); - if((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alDeleteBuffers(buffers); + if((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { exit(lastError); } Index: PositionTest.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/test/openal/PositionTest.java,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- PositionTest.java 15 Feb 2004 15:34:56 -0000 1.12 +++ PositionTest.java 26 Feb 2004 21:51:58 -0000 1.13 @@ -8,6 +8,7 @@ import org.lwjgl.input.Keyboard; import org.lwjgl.input.Mouse; import org.lwjgl.openal.AL; +import org.lwjgl.openal.AL10; import org.lwjgl.opengl.GL11; import org.lwjgl.opengl.Window; import org.lwjgl.opengl.glu.GLU; @@ -158,17 +159,17 @@ rightPosition.flip(); rightVelocity.flip(); - AL.alListener(AL.AL_POSITION, listenerPosition); - AL.alListener(AL.AL_VELOCITY, listenerVelocity); - AL.alListener(AL.AL_ORIENTATION, listenerOrientation); + AL10.alListener(AL10.AL_POSITION, listenerPosition); + AL10.alListener(AL10.AL_VELOCITY, listenerVelocity); + AL10.alListener(AL10.AL_ORIENTATION, listenerOrientation); // creating buffers Sys.log("Creating buffers"); - AL.alGenBuffers(soundBuffers); + AL10.alGenBuffers(soundBuffers); soundBuffers.rewind(); // creating sources - AL.alGenSources(soundSources); + AL10.alGenSources(soundSources); soundSources.rewind(); // load sound files (left, center, right).wav @@ -176,33 +177,33 @@ Sys.log("Loading left.wav"); WaveData left = WaveData.create("left.wav"); - AL.alBufferData(soundBuffers.get(LEFT), left.format, left.data, left.data.capacity(), left.samplerate); - AL.alSourcef(soundSources.get(LEFT), AL.AL_PITCH, 1.0f); - AL.alSourcef(soundSources.get(LEFT), AL.AL_GAIN, 1.0f); - AL.alSource(soundSources.get(LEFT), AL.AL_POSITION, leftPosition); - AL.alSource(soundSources.get(LEFT), AL.AL_VELOCITY, leftVelocity); - AL.alSourcei(soundSources.get(LEFT), AL.AL_BUFFER, soundBuffers.get(LEFT)); - AL.alSourcei(soundSources.get(LEFT), AL.AL_LOOPING, AL.AL_TRUE); + AL10.alBufferData(soundBuffers.get(LEFT), left.format, left.data, left.data.capacity(), left.samplerate); + AL10.alSourcef(soundSources.get(LEFT), AL10.AL_PITCH, 1.0f); + AL10.alSourcef(soundSources.get(LEFT), AL10.AL_GAIN, 1.0f); + AL10.alSource(soundSources.get(LEFT), AL10.AL_POSITION, leftPosition); + AL10.alSource(soundSources.get(LEFT), AL10.AL_VELOCITY, leftVelocity); + AL10.alSourcei(soundSources.get(LEFT), AL10.AL_BUFFER, soundBuffers.get(LEFT)); + AL10.alSourcei(soundSources.get(LEFT), AL10.AL_LOOPING, AL10.AL_TRUE); Sys.log("Loading center.wav"); WaveData center = WaveData.create("center.wav"); - AL.alBufferData(soundBuffers.get(CENTER), center.format, center.data, center.data.capacity(), center.samplerate); - AL.alSourcef(soundSources.get(CENTER), AL.AL_PITCH, 1.0f); - AL.alSourcef(soundSources.get(CENTER), AL.AL_GAIN, 1.0f); - AL.alSource(soundSources.get(CENTER), AL.AL_POSITION, centerPosition); - AL.alSource(soundSources.get(CENTER), AL.AL_VELOCITY, centerVelocity); - AL.alSourcei(soundSources.get(CENTER), AL.AL_BUFFER, soundBuffers.get(CENTER)); - AL.alSourcei(soundSources.get(CENTER), AL.AL_LOOPING, AL.AL_TRUE); + AL10.alBufferData(soundBuffers.get(CENTER), center.format, center.data, center.data.capacity(), center.samplerate); + AL10.alSourcef(soundSources.get(CENTER), AL10.AL_PITCH, 1.0f); + AL10.alSourcef(soundSources.get(CENTER), AL10.AL_GAIN, 1.0f); + AL10.alSource(soundSources.get(CENTER), AL10.AL_POSITION, centerPosition); + AL10.alSource(soundSources.get(CENTER), AL10.AL_VELOCITY, centerVelocity); + AL10.alSourcei(soundSources.get(CENTER), AL10.AL_BUFFER, soundBuffers.get(CENTER)); + AL10.alSourcei(soundSources.get(CENTER), AL10.AL_LOOPING, AL10.AL_TRUE); Sys.log("Loading right.wav"); WaveData right = WaveData.create("right.wav"); - AL.alBufferData(soundBuffers.get(RIGHT), right.format, right.data, right.data.capacity(), right.samplerate); - AL.alSourcef(soundSources.get(RIGHT), AL.AL_PITCH, 1.0f); - AL.alSourcef(soundSources.get(RIGHT), AL.AL_GAIN, 1.0f); - AL.alSource(soundSources.get(RIGHT), AL.AL_POSITION, rightPosition); - AL.alSource(soundSources.get(RIGHT), AL.AL_VELOCITY, rightVelocity); - AL.alSourcei(soundSources.get(RIGHT), AL.AL_BUFFER, soundBuffers.get(RIGHT)); - AL.alSourcei(soundSources.get(RIGHT), AL.AL_LOOPING, AL.AL_TRUE); + AL10.alBufferData(soundBuffers.get(RIGHT), right.format, right.data, right.data.capacity(), right.samplerate); + AL10.alSourcef(soundSources.get(RIGHT), AL10.AL_PITCH, 1.0f); + AL10.alSourcef(soundSources.get(RIGHT), AL10.AL_GAIN, 1.0f); + AL10.alSource(soundSources.get(RIGHT), AL10.AL_POSITION, rightPosition); + AL10.alSource(soundSources.get(RIGHT), AL10.AL_VELOCITY, rightVelocity); + AL10.alSourcei(soundSources.get(RIGHT), AL10.AL_BUFFER, soundBuffers.get(RIGHT)); + AL10.alSourcei(soundSources.get(RIGHT), AL10.AL_LOOPING, AL10.AL_TRUE); Sys.log("Soundfiles loaded successfully"); // ----------------------------------------------------- @@ -281,11 +282,11 @@ * Starts playing the sounds at different times */ private void startSounds() { - AL.alSourcePlay(soundSources.get(LEFT)); + AL10.alSourcePlay(soundSources.get(LEFT)); pause(300); - AL.alSourcePlay(soundSources.get(CENTER)); + AL10.alSourcePlay(soundSources.get(CENTER)); pause(500); - AL.alSourcePlay(soundSources.get(RIGHT)); + AL10.alSourcePlay(soundSources.get(RIGHT)); } /** @@ -297,7 +298,7 @@ // if requesting pause, and not paused - pause and stop sound if(paused && !pauseMode) { pauseMode = true; - AL.alSourcePause(soundSources); + AL10.alSourcePause(soundSources); } // else go out of pause mode and start sounds @@ -325,17 +326,17 @@ // Test for play // ============================================ if (Keyboard.isKeyDown(Keyboard.KEY_1)) { - AL.alSourcePlay(soundSources.get(LEFT)); + AL10.alSourcePlay(soundSources.get(LEFT)); Sys.log("Playing left.wav"); } if (Keyboard.isKeyDown(Keyboard.KEY_2)) { - AL.alSourcePlay(soundSources.get(CENTER)); + AL10.alSourcePlay(soundSources.get(CENTER)); Sys.log("Playing center.wav"); } if (Keyboard.isKeyDown(Keyboard.KEY_3)) { - AL.alSourcePlay(soundSources.get(RIGHT)); + AL10.alSourcePlay(soundSources.get(RIGHT)); Sys.log("Playing right.wav"); } // -------------------------------------------- @@ -343,17 +344,17 @@ // Test for stop // ============================================ if (Keyboard.isKeyDown(Keyboard.KEY_4)) { - AL.alSourceStop(soundSources.get(LEFT)); + AL10.alSourceStop(soundSources.get(LEFT)); Sys.log("Stopped left.wav"); } if (Keyboard.isKeyDown(Keyboard.KEY_5)) { - AL.alSourceStop(soundSources.get(CENTER)); + AL10.alSourceStop(soundSources.get(CENTER)); Sys.log("Stopped center.wav"); } if (Keyboard.isKeyDown(Keyboard.KEY_6)) { - AL.alSourceStop(soundSources.get(RIGHT)); + AL10.alSourceStop(soundSources.get(RIGHT)); Sys.log("Stopped right.wav"); } // -------------------------------------------- @@ -362,12 +363,12 @@ // ============================================ if (Keyboard.isKeyDown(Keyboard.KEY_LEFT)) { listenerPosition.put(0, listenerPosition.get(0) - 0.1f); - AL.alListener(AL.AL_POSITION, listenerPosition); + AL10.alListener(AL10.AL_POSITION, listenerPosition); } if (Keyboard.isKeyDown(Keyboard.KEY_RIGHT)) { listenerPosition.put(0, listenerPosition.get(0) + 0.1f); - AL.alListener(AL.AL_POSITION, listenerPosition); + AL10.alListener(AL10.AL_POSITION, listenerPosition); } if (Keyboard.isKeyDown(Keyboard.KEY_UP)) { @@ -376,7 +377,7 @@ } else { listenerPosition.put(2, listenerPosition.get(2) - 0.1f); } - AL.alListener(AL.AL_POSITION, listenerPosition); + AL10.alListener(AL10.AL_POSITION, listenerPosition); } if (Keyboard.isKeyDown(Keyboard.KEY_DOWN)) { @@ -385,7 +386,7 @@ } else { listenerPosition.put(2, listenerPosition.get(2) + 0.1f); } - AL.alListener(AL.AL_POSITION, listenerPosition); + AL10.alListener(AL10.AL_POSITION, listenerPosition); } // -------------------------------------------- @@ -400,7 +401,7 @@ listenerPosition.put(2, listenerPosition.get(2) + 0.1f); } - AL.alListener(AL.AL_POSITION, listenerPosition); + AL10.alListener(AL10.AL_POSITION, listenerPosition); } @@ -463,9 +464,9 @@ Mouse.destroy(); Sys.log("Shutting down OpenAL"); - AL.alSourceStop(soundSources); - AL.alDeleteSources(soundSources); - AL.alDeleteBuffers(soundBuffers); + AL10.alSourceStop(soundSources); + AL10.alDeleteSources(soundSources); + AL10.alDeleteBuffers(soundBuffers); AL.destroy(); Sys.log("Shutting down Window"); Index: SourceLimitTest.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/test/openal/SourceLimitTest.java,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- SourceLimitTest.java 8 Feb 2004 20:32:09 -0000 1.10 +++ SourceLimitTest.java 26 Feb 2004 21:51:58 -0000 1.11 @@ -33,7 +33,7 @@ import java.nio.IntBuffer; -import org.lwjgl.openal.AL; +import org.lwjgl.openal.AL10; import org.lwjgl.openal.OpenALException; /** @@ -97,15 +97,15 @@ //Create sourcesToCreate sources in one fell swoop sources.position(0).limit(sourcesToCreate); - AL.alGenSources(sources); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { - System.out.println("failed to create " + sourcesToCreate + " sources (" + AL.alGetString(lastError) + ")"); + AL10.alGenSources(sources); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { + System.out.println("failed to create " + sourcesToCreate + " sources (" + AL10.alGetString(lastError) + ")"); return; } //delete sources sources.position(0).limit(sourcesToCreate); - AL.alDeleteSources(sources); + AL10.alDeleteSources(sources); System.out.println("created " + sourcesToCreate + " sources successfully!"); } @@ -124,8 +124,8 @@ for (int i = 0; i <= sourcesToCreate; i++) { sources[i] = createIntBuffer(1); sources[i].position(0).limit(1); - AL.alGenSources(sources[i]); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { + AL10.alGenSources(sources[i]); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { System.out.println("failed to create source: " + (i + 1)); break; } @@ -136,9 +136,9 @@ for (int i = 0; i < sourcesCreated; i++) { //delete buffers and sources sources[i].position(0).limit(1); - AL.alDeleteSources(sources[i]); - if ((lastError = AL.alGetError()) != AL.AL_NO_ERROR) { - System.out.println("failed to delete source: " + i + "(" + AL.alGetString(lastError) + ")"); + AL10.alDeleteSources(sources[i]); + if ((lastError = AL10.alGetError()) != AL10.AL_NO_ERROR) { + System.out.println("failed to delete source: " + i + "(" + AL10.alGetString(lastError) + ")"); break; } } Index: StressTest.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/test/openal/StressTest.java,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- StressTest.java 8 Feb 2004 20:32:09 -0000 1.10 +++ StressTest.java 26 Feb 2004 21:51:58 -0000 1.11 @@ -33,7 +33,7 @@ import java.nio.IntBuffer; -import org.lwjgl.openal.AL; +import org.lwjgl.openal.AL10; /** * $Id$ @@ -81,8 +81,8 @@ private void createSources() { sources = createIntBuffer(4); sources.position(0).limit(4); - AL.alGenSources(sources); - if (AL.alGetError() != AL.AL_NO_ERROR) { + AL10.alGenSources(sources); + if (AL10.alGetError() != AL10.AL_NO_ERROR) { System.out.println("Unable to create 4 sources"); alExit(); } @@ -91,32 +91,32 @@ private void createBuffers() { buffers = createIntBuffer(10); buffers.position(0).limit(10); - AL.alGenBuffers(buffers); - if (AL.alGetError() != AL.AL_NO_ERROR) { + AL10.alGenBuffers(buffers); + if (AL10.alGetError() != AL10.AL_NO_ERROR) { System.out.println("Unable to create 10 buffers"); sources.position(0).limit(4); - AL.alDeleteSources(sources); + AL10.alDeleteSources(sources); alExit(); } } private void loadSamples() throws Exception { - AL.alGetError(); + AL10.alGetError(); WaveData data = WaveData.create("ding.wav"); for (int i = 1; i <= 10; i++) { - AL.alBufferData( + AL10.alBufferData( buffers.get(i - 1), data.format, data.data, data.data.capacity(), data.samplerate); - if (AL.alGetError() != AL.AL_NO_ERROR) { + if (AL10.alGetError() != AL10.AL_NO_ERROR) { System.out.println("Failed to load " + i + ".wav into buffer"); sources.position(0).limit(4); - AL.alDeleteSources(sources); + AL10.alDeleteSources(sources); buffers.position(0).limit(10); - AL.alDeleteBuffers(buffers); + AL10.alDeleteBuffers(buffers); alExit(); } @@ -132,11 +132,11 @@ long startTime = System.currentTimeMillis(); //mark background source as looping - AL.alSourcei(sources.get(0), AL.AL_LOOPING, AL.AL_TRUE); + AL10.alSourcei(sources.get(0), AL10.AL_LOOPING, AL10.AL_TRUE); //play background - AL.alSourcei(sources.get(0), AL.AL_BUFFER, buffers.get(0)); - AL.alSourcePlay(sources.get(0)); + AL10.alSourcei(sources.get(0), AL10.AL_BUFFER, buffers.get(0)); + AL10.alSourcePlay(sources.get(0)); while (System.currentTimeMillis() - startTime < (2000)) { @@ -144,22 +144,22 @@ System.out.println("random:" + randomBuffer); //stop source at slot - AL.alSourceStop(sources.get(nextSlot)); - if (AL.alGetError() != AL.AL_NO_ERROR) { + AL10.alSourceStop(sources.get(nextSlot)); + if (AL10.alGetError() != AL10.AL_NO_ERROR) { System.out.println("Error stopping source."); } System.out.println("Stopped source: " + nextSlot); //link source<->buffer - AL.alSourcei(sources.get(nextSlot), AL.AL_BUFFER, buffers.get(randomBuffer)); - if (AL.alGetError() != AL.AL_NO_ERROR) { + AL10.alSourcei(sources.get(nextSlot), AL10.AL_BUFFER, buffers.get(randomBuffer)); + if (AL10.alGetError() != AL10.AL_NO_ERROR) { System.out.println("Error linking buffer and source."); } System.out.println("linked source " + nextSlot + " with buffer " + randomBuffer); //start playing System.out.println("playing source " + nextSlot); - AL.alSourcePlay(sources.get(nextSlot++)); + AL10.alSourcePlay(sources.get(nextSlot++)); if (nextSlot == 4) { nextSlot = startSlot; } @@ -182,7 +182,7 @@ //stop all sources for (int i = 0; i < 4; i++) { - AL.alSourceStop(sources.get(i)); + AL10.alSourceStop(sources.get(i)); System.out.println("Stopping source " + (i+1)); } @@ -200,9 +200,9 @@ } sources.position(0).limit(4); - AL.alDeleteSources(sources); + AL10.alDeleteSources(sources); buffers.position(0).limit(10); - AL.alDeleteBuffers(buffers); + AL10.alDeleteBuffers(buffers); } private int getRandomBuffer() { Index: WaveData.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/test/openal/WaveData.java,v retrieving revision 1.14 retrieving revision 1.15 diff -u -d -r1.14 -r1.15 --- WaveData.java 8 Feb 2004 20:32:09 -0000 1.14 +++ WaveData.java 26 Feb 2004 21:51:58 -0000 1.15 @@ -42,7 +42,7 @@ import javax.sound.sampled.AudioInputStream; import javax.sound.sampled.AudioSystem; -import org.lwjgl.openal.AL; +import org.lwjgl.openal.AL10; /** * $Id$ @@ -131,17 +131,17 @@ int channels = 0; if (audioformat.getChannels() == 1) { if (audioformat.getSampleSizeInBits() == 8) { - channels = AL.AL_FORMAT_MONO8; + channels = AL10.AL_FORMAT_MONO8; } else if (audioformat.getSampleSizeInBits() == 16) { - channels = AL.AL_FORMAT_MONO16; + channels = AL10.AL_FORMAT_MONO16; } else { assert false : "Illegal sample size"; } } else if (audioformat.getChannels() == 2) { if (audioformat.getSampleSizeInBits() == 8) { - channels = AL.AL_FORMAT_STEREO8; + channels = AL10.AL_FORMAT_STEREO8; } else if (audioformat.getSampleSizeInBits() == 16) { - channels = AL.AL_FORMAT_STEREO16; + channels = AL10.AL_FORMAT_STEREO16; } else { assert false : "Illegal sample size"; } |
Update of /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/eax In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6429/java/org/lwjgl/openal/eax Modified Files: EAX.java EAXBufferProperties.java EAXListenerProperties.java Added Files: EAX20.java Removed Files: BaseEAX.java BaseEAXConstants.java CoreEAX.java Log Message: OpenAL / EAX Refactor --- NEW FILE: EAX20.java --- /* * Copyright (c) 2002 Lightweight Java Game Library Project * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are * met: * * * Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * * Neither the name of 'Light Weight Java Game Library' nor the names of * its contributors may be used to endorse or promote products derived * from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ package org.lwjgl.openal.eax; import java.nio.Buffer; /** * $Id: EAX20.java,v 1.1 2004/02/26 21:51:57 matzon Exp $ * * This is the OpenAL EAX class. It extends the latest core. * * @author Brian Matzon <br...@ma...> * @version $Revision: 1.1 $ */ public class EAX20 { /** GUID for buffer */ public static final int BUFFER_GUID = 1; /** GUID for listener */ public static final int LISTENER_GUID = 2; public static final int EAX_ENVIRONMENT_GENERIC = 0; public static final int EAX_ENVIRONMENT_PADDEDCELL = 1; public static final int EAX_ENVIRONMENT_ROOM = 2; public static final int EAX_ENVIRONMENT_BATHROOM = 3; public static final int EAX_ENVIRONMENT_LIVINGROOM = 4; public static final int EAX_ENVIRONMENT_STONEROOM = 5; public static final int EAX_ENVIRONMENT_AUDITORIUM = 6; public static final int EAX_ENVIRONMENT_CONCERTHALL = 7; public static final int EAX_ENVIRONMENT_CAVE = 8; public static final int EAX_ENVIRONMENT_ARENA = 9; public static final int EAX_ENVIRONMENT_HANGAR = 10; public static final int EAX_ENVIRONMENT_CARPETEDHALLWAY = 11; public static final int EAX_ENVIRONMENT_HALLWAY = 12; public static final int EAX_ENVIRONMENT_STONECORRIDOR = 13; public static final int EAX_ENVIRONMENT_ALLEY = 14; public static final int EAX_ENVIRONMENT_FOREST = 15; public static final int EAX_ENVIRONMENT_CITY = 16; public static final int EAX_ENVIRONMENT_MOUNTAINS = 17; public static final int EAX_ENVIRONMENT_QUARRY = 18; public static final int EAX_ENVIRONMENT_PLAIN = 19; public static final int EAX_ENVIRONMENT_PARKINGLOT = 20; public static final int EAX_ENVIRONMENT_SEWERPIPE = 21; public static final int EAX_ENVIRONMENT_UNDERWATER = 22; public static final int EAX_ENVIRONMENT_DRUGGED = 23; public static final int EAX_ENVIRONMENT_DIZZY = 24; public static final int EAX_ENVIRONMENT_PSYCHOTIC = 25; public static final int EAX_ENVIRONMENT_COUNT = 26; // Single window material preset public static final int EAX_MATERIAL_SINGLEWINDOW = -2800; public static final float EAX_MATERIAL_SINGLEWINDOWLF = 0.71f; public static final float EAX_MATERIAL_SINGLEWINDOWROOMRATIO = 0.43f; // Double window material preset public static final int EAX_MATERIAL_DOUBLEWINDOW = -5000; public static final float EAX_MATERIAL_DOUBLEWINDOWHF = 0.40f; public static final float EAX_MATERIAL_DOUBLEWINDOWROOMRATIO = 0.24f; // Thin door material preset public static final int EAX_MATERIAL_THINDOOR = -1800; public static final float EAX_MATERIAL_THINDOORLF = 0.66f; public static final float EAX_MATERIAL_THINDOORROOMRATIO = 0.66f; // Thick door material preset public static final int EAX_MATERIAL_THICKDOOR = -4400; public static final float EAX_MATERIAL_THICKDOORLF = 0.64f; public static final float EAX_MATERIAL_THICKDOORROOMRTATION = 0.27f; // Wood wall material preset public static final int EAX_MATERIAL_WOODWALL = -4000; public static final float EAX_MATERIAL_WOODWALLLF = 0.50f; public static final float EAX_MATERIAL_WOODWALLROOMRATIO = 0.30f; // Brick wall material preset public static final int EAX_MATERIAL_BRICKWALL = -5000; public static final float EAX_MATERIAL_BRICKWALLLF = 0.60f; public static final float EAX_MATERIAL_BRICKWALLROOMRATIO = 0.24f; // Stone wall material preset public static final int EAX_MATERIAL_STONEWALL = -6000; public static final float EAX_MATERIAL_STONEWALLLF = 0.68f; public static final float EAX_MATERIAL_STONEWALLROOMRATIO = 0.20f; // Curtain material preset public static final int EAX_MATERIAL_CURTAIN = -1200; public static final float EAX_MATERIAL_CURTAINLF = 0.15f; public static final float EAX_MATERIAL_CURTAINROOMRATIO = 1.00f; /** * Load extensions */ protected static void init() { determineAvailableExtensions(); } /** * Determines available EAX extensions */ protected static native void determineAvailableExtensions(); /** * Retrieves an EAX Value * * @param propertySetID adress to the property set GUID of the object being queried (a listener or a source) * @param property property being queried * @param source the source to be queried * @param data Buffer to write value to * @param size size of area being written to * @return OpenAL Error code */ public static int eaxGet(int propertySetID, int property, int source, Buffer data, int size) { return neaxGet(propertySetID, property, source, data, data.position(), size); } private static native int neaxGet(int propertySetID, int property, int source, Buffer data, int position, int size); /** * Sets an EAX Value * * @param propertySetID adress to the property set GUID of the object being queried (a listener or a source) * @param property property being queried * @param source the source to be queried * @param data Buffer to write value to * @param size size of area being written to * @return OpenAL Error code */ public static int eaxSet(int propertySetID, int property, int source, Buffer data, int size) { return neaxSet(propertySetID, property, source, data, data.position(), size); } private static native int neaxSet(int propertySetID, int property, int source, Buffer data, int position, int size); } Index: EAX.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/eax/EAX.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- EAX.java 17 Aug 2003 16:38:57 -0000 1.6 +++ EAX.java 26 Feb 2004 21:51:57 -0000 1.7 @@ -39,5 +39,66 @@ * @author Brian Matzon <br...@ma...> * @version $Revision$ */ -public class EAX extends CoreEAX { +public class EAX { + + /** Has the EAX object been created? */ + protected static boolean created; + + static { + initialize(); + } + + /** + * Static initialization + */ + private static void initialize() { + System.loadLibrary(org.lwjgl.Sys.getLibraryName()); + } + + /** + * Loads the EAX functions + * + * @throws Exception if the EAX extensions couldn't be loaded + */ + public static void create() throws Exception { + if (created) { + return; + } + + if (!nCreate()) { + throw new Exception("EAX instance could not be created."); + } + EAX20.init(); + created = true; + } + + /** + * Native method to create EAX instance + * + * @return true if the EAX extensions could be found + */ + protected static native boolean nCreate(); + + /** + * "Destroy" the EAX object + */ + public static void destroy() { + if (!created) { + return; + } + created = false; + nDestroy(); + } + + /** + * Native method the destroy the EAX + */ + protected static native void nDestroy(); + + /** + * @return true if EAX has been created + */ + public static boolean isCreated() { + return created; + } } \ No newline at end of file Index: EAXBufferProperties.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/eax/EAXBufferProperties.java,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- EAXBufferProperties.java 6 Jan 2004 19:22:12 -0000 1.11 +++ EAXBufferProperties.java 26 Feb 2004 21:51:57 -0000 1.12 @@ -229,8 +229,8 @@ * Loads current EAX values from current source */ public void loadEAXValues() { - EAX.eaxGet( - CoreEAX.BUFFER_GUID, + EAX20.eaxGet( + EAX20.BUFFER_GUID, EAXBUFFER_ALLPARAMETERS, currentSource, eaxBufferProperties, @@ -271,8 +271,8 @@ */ public void commit() { // call eaxSet with Buffer guid, setting all parameters - EAX.eaxSet( - CoreEAX.BUFFER_GUID, EAXBUFFER_ALLPARAMETERS, + EAX20.eaxSet( + EAX20.BUFFER_GUID, EAXBUFFER_ALLPARAMETERS, currentSource, eaxBufferProperties, EAXBUFFERPROPERTIES_SIZE); } Index: EAXListenerProperties.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/eax/EAXListenerProperties.java,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- EAXListenerProperties.java 6 Jan 2004 19:22:12 -0000 1.10 +++ EAXListenerProperties.java 26 Feb 2004 21:51:57 -0000 1.11 @@ -184,9 +184,9 @@ public static final int EAXLISTENER_MINENVIRONMENT = 0; public static final int EAXLISTENER_MAXENVIRONMENT = - (EAX.EAX_ENVIRONMENT_COUNT - 1); + (EAX20.EAX_ENVIRONMENT_COUNT - 1); public static final int EAXLISTENER_DEFAULTENVIRONMENT = - EAX.EAX_ENVIRONMENT_GENERIC; + EAX20.EAX_ENVIRONMENT_GENERIC; public static final float EAXLISTENER_MINENVIRONMENTSIZE = 1.0f; public static final float EAXLISTENER_MAXENVIRONMENTSIZE = 100.0f; @@ -226,8 +226,8 @@ * Loads current EAX values */ public void loadEAXValues() { - EAX.eaxGet( - CoreEAX.LISTENER_GUID, + EAX20.eaxGet( + EAX20.LISTENER_GUID, EAXLISTENER_ALLPARAMETERS, 0, eaxListenerProperties, @@ -269,8 +269,8 @@ */ public void commit() { // call eaxSet with Listener guid, setting all parameters - EAX.eaxSet( - CoreEAX.LISTENER_GUID, EAXLISTENER_ALLPARAMETERS | EAXLISTENER_IMMEDIATE, + EAX20.eaxSet( + EAX20.LISTENER_GUID, EAXLISTENER_ALLPARAMETERS | EAXLISTENER_IMMEDIATE, 0, eaxListenerProperties, EAXLISTENERPROPERTIES_SIZE); } @@ -575,8 +575,8 @@ // only the environment value and its size. Also pass the // EAXLISTENER_ENVIRONMENT value (and since we're committing IMMEDIATE too) if (autoCommit) { - EAX.eaxSet( - CoreEAX.LISTENER_GUID, EAXLISTENER_ENVIRONMENT | EAXLISTENER_IMMEDIATE, + EAX20.eaxSet( + EAX20.LISTENER_GUID, EAXLISTENER_ENVIRONMENT | EAXLISTENER_IMMEDIATE, 0, eaxListenerProperties.position(environment_offset), 4); // rewind buffer @@ -609,8 +609,8 @@ // only the environment size value and its size. Also pass the // EAXLISTENER_ENVIRONMENTSIZE value (and since we're committing IMMEDIATE too) if (autoCommit) { - EAX.eaxSet( - CoreEAX.LISTENER_GUID, EAXLISTENER_ENVIRONMENTSIZE | EAXLISTENER_IMMEDIATE, + EAX20.eaxSet( + EAX20.LISTENER_GUID, EAXLISTENER_ENVIRONMENTSIZE | EAXLISTENER_IMMEDIATE, 0, eaxListenerProperties.position(environmentSize_offset), 4); // rewind buffer --- BaseEAX.java DELETED --- --- BaseEAXConstants.java DELETED --- --- CoreEAX.java DELETED --- |
Update of /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6429/java/org/lwjgl/openal Modified Files: AL.java Added Files: AL10.java Removed Files: ALConstants.java BaseAL.java BaseALConstants.java CoreAL.java Log Message: OpenAL / EAX Refactor --- NEW FILE: AL10.java --- /* * Copyright (c) 2002 Lightweight Java Game Library Project * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are * met: * * * Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * * Neither the name of 'Light Weight Java Game Library' nor the names of * its contributors may be used to endorse or promote products derived * from this software without specific prior written permission. * [...1171 lines suppressed...] * </p> * <p> * There are two API calls global to the current context that provide control of the two * related parameters. * </p> * <p> * AL_DOPPLER_VELOCITY allows the application to change the reference (propagation) * velocity used in the Doppler Effect calculation. This permits the application to use a * velocity scale appropriate to its purposes. * </p> * <p> * A negative or zero value will result in an AL_INVALID_VALUE error, the command is * then ignored. The default value is 1. The current setting can be queried using * GetFloatv and AL_DOPPLER_VELOCITY. * </p> * * @param value Doppler velocity value to set */ public static native void alDopplerVelocity(float value); } Index: AL.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/AL.java,v retrieving revision 1.16 retrieving revision 1.17 diff -u -d -r1.16 -r1.17 --- AL.java 8 Jan 2004 22:41:22 -0000 1.16 +++ AL.java 26 Feb 2004 21:51:57 -0000 1.17 @@ -31,6 +31,13 @@ */ package org.lwjgl.openal; +import java.io.File; +import java.lang.reflect.Method; +import java.util.StringTokenizer; + +import org.lwjgl.Display; +import org.lwjgl.Sys; + /** * $Id$ * <br> @@ -39,7 +46,7 @@ * @author Brian Matzon <br...@ma...> * @version $Revision$ */ -public abstract class AL extends CoreAL { +public abstract class AL { /** ALC instance. */ protected static ALC alc; @@ -53,7 +60,8 @@ /** * String that requests a certain device or device configuration. * If null is specified, the implementation will provide an - * implementation specific default. */ + * implementation specific default. + */ protected static String deviceArguments; /** Frequency for mixing output buffer, in units of Hz. */ @@ -65,6 +73,40 @@ /** Flag, indicating a synchronous context. */ protected static int contextSynchronized = ALC.ALC_FALSE; + /** Have we been created? */ + protected static boolean created; + + static { + initialize(); + } + + /** + * Static initialization + */ + private static void initialize() { + System.loadLibrary(org.lwjgl.Sys.getLibraryName()); + } + + /** + * Native method to create AL instance + * + * @param oalPaths Array of strings containing paths to search for OpenAL library + * @return true if the AL creation process succeeded + */ + protected static native void nCreate(String[] oalPaths) throws OpenALException; + + /** + * Native method the destroy the AL + */ + protected static native void nDestroy(); + + /** + * @return true if AL has been created + */ + public static boolean isCreated() { + return created; + } + /** * Creates an OpenAL instance. Using this constructor will cause OpenAL to * open the device using supplied device argument, and create a context using the context values @@ -99,10 +141,52 @@ if(created) { return; } + + // need to pass path of possible locations of OAL to native side + String libpath = System.getProperty("java.library.path"); + String seperator = System.getProperty("path.separator"); + String libname; + String jwsLibname; + + // libname is hardcoded atm - this will change in a near future... + switch (Display.getPlatform()) { + case Display.PLATFORM_WGL: + libname = "lwjglaudio.dll"; + jwsLibname = "lwjglaudio"; + break; + case Display.PLATFORM_GLX: + libname = "libopenal.so"; + jwsLibname = "openal"; + break; + case Display.PLATFORM_AGL: + libname = "openal.dylib"; + jwsLibname = "openal"; + break; + default: + throw new OpenALException("Unknown platform"); + } - BaseAL.create(); + String jwsPath = getPathFromJWS(jwsLibname); + if (jwsPath != null) { + libpath += seperator + + jwsPath.substring(0, jwsPath.lastIndexOf(File.separator)); + } - ALC.create(); + StringTokenizer st = new StringTokenizer(libpath, seperator); + + //create needed string array + String[] oalPaths = new String[st.countTokens() + 1]; + + //build paths + for (int i = 0; i < oalPaths.length - 1; i++) { + oalPaths[i] = st.nextToken() + File.separator + libname; + } + + //add cwd path + oalPaths[oalPaths.length - 1] = libname; + nCreate(oalPaths); + + ALC.create(); device = ALC.alcOpenDevice(deviceArguments); @@ -118,6 +202,7 @@ ALC.alcMakeContextCurrent(context.context); + created = true; } /** @@ -140,7 +225,36 @@ contextFrequency = -1; contextRefresh = -1; contextSynchronized = ALC.ALC_FALSE; - - BaseAL.destroy(); + + created = false; + nDestroy(); } + + /** + * Tries to locate OpenAL from the JWS Library path + * This method exists because OpenAL is loaded from native code, and as such + * is exempt from JWS library loading rutines. OpenAL therefore always fails. + * We therefore invoke the protected method of the JWS classloader to see if it can + * locate it. + * + * @param libname Name of library to search for + * @return Absolute path to library if found, otherwise null + */ + private static String getPathFromJWS(String libname) { + try { + + Sys.log("JWS Classloader looking for: " + libname); + + Object o = AL.class.getClassLoader(); + Class c = o.getClass(); + Method findLibrary = + c.getMethod("findLibrary", new Class[] { String.class }); + Object[] arguments = new Object[] { libname }; + return (String) findLibrary.invoke(o, arguments); + + } catch (Exception e) { + Sys.log("Failure locating OpenAL using classloader:" + e); + } + return null; + } } \ No newline at end of file --- ALConstants.java DELETED --- --- BaseAL.java DELETED --- --- BaseALConstants.java DELETED --- --- CoreAL.java DELETED --- |
|
From: <ma...@us...> - 2004-02-26 22:04:02
|
Update of /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/opengl In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5647 Modified Files: Window.java Log Message: fixed import Index: Window.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/Window.java,v retrieving revision 1.26 retrieving revision 1.27 diff -u -d -r1.26 -r1.27 --- Window.java 24 Feb 2004 14:31:34 -0000 1.26 +++ Window.java 26 Feb 2004 21:47:58 -0000 1.27 @@ -47,8 +47,6 @@ * @author foo */ -import java.util.HashSet; - import org.lwjgl.Display; import org.lwjgl.Sys; |
|
From: <ma...@us...> - 2004-02-26 21:55:29
|
Update of /cvsroot/java-game-lib/LWJGL/src/native/win32 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3793 Removed Files: org_lwjgl_Sys.h Log Message: *puff* --- org_lwjgl_Sys.h DELETED --- |