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
(8) |
2
(34) |
|
3
(15) |
4
(17) |
5
(7) |
6
(2) |
7
(4) |
8
|
9
|
|
10
(1) |
11
(8) |
12
(5) |
13
(7) |
14
|
15
|
16
(1) |
|
17
(70) |
18
|
19
(5) |
20
(1) |
21
|
22
|
23
(7) |
|
24
(3) |
25
(3) |
26
(1) |
27
|
28
(1) |
29
(4) |
30
(3) |
|
31
|
|
|
|
|
|
|
|
From: Caspian Rychlik-P. <ci...@us...> - 2003-08-03 22:27:31
|
Update of /cvsroot/java-game-lib/LWJGL/src/native/common In directory sc8-pr-cvs1:/tmp/cvs-serv30067/src/native/common Modified Files: org_lwjgl_opengl_GL.cpp Log Message: Index: org_lwjgl_opengl_GL.cpp CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/native/common/org_lwjgl_opengl_GL.cpp =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_opengl_GL.cpp,v retrieving revision 1.14 retrieving revision 1.15 diff -u -d -r1.14 -r1.15 --- org_lwjgl_opengl_GL.cpp 2 Aug 2003 15:21:55 -0000 1.14 +++ org_lwjgl_opengl_GL.cpp 3 Aug 2003 22:27:28 -0000 1.15 @@ -47,6 +47,8 @@ #include "extgl.h" #include "checkGLerror.h" +extern HDC hdc; + static inline void * safeGetBufferAddress(JNIEnv *env, jobject buffer) { if (buffer == NULL) return NULL; @@ -3237,11 +3239,11 @@ * Class: org_lwjgl_opengl_GL * Method: wglGetExtensionsStringARB */ -JNIEXPORT jstring JNICALL Java_org_lwjgl_opengl_GL_wglGetExtensionsStringARB(JNIEnv * env, jclass clazz, jint p0) +JNIEXPORT jstring JNICALL Java_org_lwjgl_opengl_GL_wglGetExtensionsStringARB(JNIEnv * env, jclass clazz) { #ifdef _WIN32 if (wglGetExtensionsStringARB) - return env->NewStringUTF(wglGetExtensionsStringARB(GetDC((HWND) p0))); + return env->NewStringUTF(wglGetExtensionsStringARB(hdc)); else return NULL; #else |
|
From: Caspian Rychlik-P. <ci...@us...> - 2003-08-03 22:10:07
|
Update of /cvsroot/java-game-lib/LWJGL/src/native/common In directory sc8-pr-cvs1:/tmp/cvs-serv27556/src/native/common Modified Files: org_lwjgl_opengl_GL.h org_lwjgl_Window.h Removed Files: org_lwjgl_opengl_GLWindow.h Log Message: Index: org_lwjgl_opengl_GL.h CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/native/common/org_lwjgl_opengl_GL.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_opengl_GL.h,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- org_lwjgl_opengl_GL.h 2 Aug 2003 15:21:55 -0000 1.11 +++ org_lwjgl_opengl_GL.h 3 Aug 2003 22:10:03 -0000 1.12 @@ -8,7 +8,9 @@ extern "C" { #endif /* Inaccessible static: _00024assertionsDisabled */ -/* Inaccessible static: class_00024org_00024lwjgl_00024opengl_00024GL */ +/* Inaccessible static: class_000240 */ +/* Inaccessible static: _00024assertionsDisabled */ +/* Inaccessible static: class_000240 */ /* * Class: org_lwjgl_opengl_GL * Method: glActiveStencilFaceEXT @@ -2164,10 +2166,10 @@ /* * Class: org_lwjgl_opengl_GL * Method: wglGetExtensionsStringARB - * Signature: (I)Ljava/lang/String; + * Signature: ()Ljava/lang/String; */ JNIEXPORT jstring JNICALL Java_org_lwjgl_opengl_GL_wglGetExtensionsStringARB - (JNIEnv *, jclass, jint); + (JNIEnv *, jclass); /* * Class: org_lwjgl_opengl_GL Index: org_lwjgl_Window.h CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/native/common/org_lwjgl_Window.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/org_lwjgl_Window.h,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- org_lwjgl_Window.h 24 Jun 2003 12:24:55 -0000 1.4 +++ org_lwjgl_Window.h 3 Aug 2003 22:10:03 -0000 1.5 @@ -1,48 +1,86 @@ /* DO NOT EDIT THIS FILE - it is machine generated */ -#include <jni.h> +#include <jni.h> /* Header for class org_lwjgl_Window */ #ifndef _Included_org_lwjgl_Window -#define _Included_org_lwjgl_Window +#define _Included_org_lwjgl_Window #ifdef __cplusplus extern "C" { -#endif -/* Inaccessible static: _00024assertionsDisabled */ -/* Inaccessible static: currentWindow */ -/* Inaccessible static: class_00024org_00024lwjgl_00024Window */ -/* - * Class: org_lwjgl_Window - * Method: nSetTitle - * Signature: (Ljava/lang/String;)V - */ -JNIEXPORT void JNICALL Java_org_lwjgl_Window_nSetTitle - (JNIEnv *, jobject, jstring); - -/* - * Class: org_lwjgl_Window - * Method: minimize - * Signature: ()V - */ -JNIEXPORT void JNICALL Java_org_lwjgl_Window_minimize - (JNIEnv *, jobject); - -/* - * Class: org_lwjgl_Window - * Method: restore - * Signature: ()V - */ -JNIEXPORT void JNICALL Java_org_lwjgl_Window_restore - (JNIEnv *, jobject); - -/* - * Class: org_lwjgl_Window - * Method: tick - * Signature: ()V - */ -JNIEXPORT void JNICALL Java_org_lwjgl_Window_tick - (JNIEnv *, jobject); - +#endif +/* Inaccessible static: _00024assertionsDisabled */ +/* Inaccessible static: created */ +/* Inaccessible static: minimized */ +/* Inaccessible static: focused */ +/* Inaccessible static: closeRequested */ +/* Inaccessible static: dirty */ +/* Inaccessible static: x */ +/* Inaccessible static: y */ +/* Inaccessible static: width */ +/* Inaccessible static: height */ +/* Inaccessible static: title */ +/* Inaccessible static: color */ +/* Inaccessible static: alpha */ +/* Inaccessible static: depth */ +/* Inaccessible static: stencil */ +/* Inaccessible static: fullscreen */ +/* Inaccessible static: class_000240 */ +/* + * Class: org_lwjgl_Window + * Method: nSetTitle + * Signature: (Ljava/lang/String;)V + */ +JNIEXPORT void JNICALL Java_org_lwjgl_Window_nSetTitle + (JNIEnv *, jclass, jstring); + +/* + * Class: org_lwjgl_Window + * Method: minimize + * Signature: ()V + */ +JNIEXPORT void JNICALL Java_org_lwjgl_Window_minimize + (JNIEnv *, jclass); + +/* + * Class: org_lwjgl_Window + * Method: restore + * Signature: ()V + */ +JNIEXPORT void JNICALL Java_org_lwjgl_Window_restore + (JNIEnv *, jclass); + +/* + * Class: org_lwjgl_Window + * Method: swapBuffers + * Signature: ()V + */ +JNIEXPORT void JNICALL Java_org_lwjgl_Window_swapBuffers + (JNIEnv *, jclass); + +/* + * Class: org_lwjgl_Window + * Method: nCreate + * Signature: (Ljava/lang/String;IIIIZIIII)V + */ +JNIEXPORT void JNICALL Java_org_lwjgl_Window_nCreate + (JNIEnv *, jclass, jstring, jint, jint, jint, jint, jboolean, jint, jint, jint, jint); + +/* + * Class: org_lwjgl_Window + * Method: nDestroy + * Signature: ()V + */ +JNIEXPORT void JNICALL Java_org_lwjgl_Window_nDestroy + (JNIEnv *, jclass); + +/* + * Class: org_lwjgl_Window + * Method: tick + * Signature: ()V + */ +JNIEXPORT void JNICALL Java_org_lwjgl_Window_tick + (JNIEnv *, jclass); + #ifdef __cplusplus } -#endif -#endif +#endif +#endif --- org_lwjgl_opengl_GLWindow.h DELETED --- CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/native/common/org_lwjgl_opengl_GLWindow.h |
|
From: Caspian Rychlik-P. <ci...@us...> - 2003-08-03 22:09:00
|
Update of /cvsroot/java-game-lib/LWJGL/src/native/win32 In directory sc8-pr-cvs1:/tmp/cvs-serv27445/src/native/win32 Modified Files: org_lwjgl_Window.cpp Removed Files: org_lwjgl_opengl_GLWindow.cpp Log Message: Index: org_lwjgl_Window.cpp CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/native/win32/org_lwjgl_Window.cpp =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/win32/org_lwjgl_Window.cpp,v retrieving revision 1.15 retrieving revision 1.16 diff -u -d -r1.15 -r1.16 --- org_lwjgl_Window.cpp 27 Jul 2003 13:12:43 -0000 1.15 +++ org_lwjgl_Window.cpp 3 Aug 2003 22:08:58 -0000 1.16 @@ -46,16 +46,18 @@ bool oneShotInitialised = false; // Registers the LWJGL window class HWND hwnd = NULL; // Handle to the window HDC hdc = NULL; // Device context +HGLRC hglrc = NULL; // OpenGL context LPDIRECTINPUT lpdi = NULL; // DirectInput bool isFullScreen = false; // Whether we're fullscreen or not bool isMinimized = false; // Whether we're minimized or not JNIEnv * environment = NULL; // Cached environment -jobject window; // Cached Java Window instance handle +jclass window; // Cached Java Window class extern HINSTANCE dll_handle; // Handle to the LWJGL dll RECT clientSize; -extern void tempRestoreDisplayMode(); -extern void tempResetDisplayMode(); +//CAS: commented these out as no longer used +//extern void tempRestoreDisplayMode(); +//extern void tempResetDisplayMode(); #define WINDOWCLASSNAME "LWJGL" @@ -80,10 +82,96 @@ } /* + * Find an appropriate pixel format + */ +static int findPixelFormat(JNIEnv *env, unsigned int flags, int bpp, int alpha, int depth, int stencil) +{ + PIXELFORMATDESCRIPTOR pfd = { + sizeof(PIXELFORMATDESCRIPTOR), // size of this pfd + 1, // version number + flags, // RGBA type + PFD_TYPE_RGBA, + (BYTE)bpp, + 0, 0, 0, 0, 0, 0, // color bits ignored + (BYTE)alpha, + 0, // shift bit ignored + 0, // no accumulation buffer + 0, 0, 0, 0, // accum bits ignored + (BYTE)depth, + (BYTE)stencil, + 0, // No auxiliary buffer + PFD_MAIN_PLANE, // main layer + 0, // reserved + 0, 0, 0 // layer masks ignored + }; + + // get the best available match of pixel format for the device context + int iPixelFormat = ChoosePixelFormat(hdc, &pfd); + if (iPixelFormat == 0) { + throwException(env, "Failed to choose pixel format"); + return -1; + } + +#ifdef _DEBUG + printf("Pixel format is %d\n", iPixelFormat); +#endif + + // make that the pixel format of the device context + if (SetPixelFormat(hdc, iPixelFormat, &pfd) == FALSE) { + printf("Failed to set pixel format\n"); + throwException(env, "Failed to choose pixel format"); + return -1; + } + + // 3. Check the chosen format matches or exceeds our specifications + PIXELFORMATDESCRIPTOR desc; + if (DescribePixelFormat(hdc, iPixelFormat, sizeof(PIXELFORMATDESCRIPTOR), &desc) == 0) { + throwException(env, "Could not describe pixel format"); + return -1; + } + + if (desc.cColorBits < bpp) { + throwException(env, "This application requires a greater colour depth"); + return -1; + } + + if (desc.cAlphaBits < alpha) { + throwException(env, "This application requires a greater alpha depth"); + return -1; + } + + if (desc.cStencilBits < stencil) { + throwException(env, "This application requires a greater stencil depth"); + return -1; + } + + if (desc.cDepthBits < depth) { + throwException(env, "This application requires a greater depth buffer depth"); + return -1; + } + + if ((desc.dwFlags & PFD_GENERIC_FORMAT) != 0 || (desc.dwFlags & PFD_GENERIC_ACCELERATED) != 0) { + throwException(env, "Mode not supported by hardware"); + return -1; + } + + if ((desc.dwFlags & flags) != flags) { + throwException(env, "Capabilities not supported"); + return -1; + } + + // 4. Initialise other things now + if (extgl_Open() != 0) { + throwException(env, "Failed to open extgl"); + return -1; + } + return iPixelFormat; +} +/* * Create DirectInput. * Returns true for success, or false for failure */ -bool createDirectInput() +static bool createDirectInput() { // Create input HRESULT ret = DirectInputCreate(dll_handle, DIRECTINPUT_VERSION, &lpdi, NULL); @@ -111,7 +199,7 @@ /* * Close the window */ -void closeWindow() +static void closeWindow() { // Release DirectInput if (lpdi != NULL) { @@ -147,7 +235,7 @@ /* * Called when the application is alt-tabbed to or from */ -void appActivate(bool active) +static void appActivate(bool active) { // if (!active) { // tempResetDisplayMode(); @@ -184,15 +272,15 @@ case SC_MONITORPOWER: return 0L; case SC_MINIMIZE: - environment->SetBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "minimized", "Z"), JNI_TRUE); + environment->SetStaticBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "minimized", "Z"), JNI_TRUE); appActivate(false); break; case SC_RESTORE: - environment->SetBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "minimized", "Z"), JNI_FALSE); + environment->SetStaticBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "minimized", "Z"), JNI_FALSE); appActivate(true); break; case SC_CLOSE: - environment->SetBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "closeRequested", "Z"), JNI_TRUE); + environment->SetStaticBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "closeRequested", "Z"), JNI_TRUE); //don't continue processing this command since this //would shutdown the window, which the application might not want to return 0L; @@ -204,12 +292,12 @@ switch(LOWORD(wParam)) { case WA_ACTIVE: case WA_CLICKACTIVE: - environment->SetBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "minimized", "Z"), JNI_FALSE); + environment->SetStaticBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "minimized", "Z"), JNI_FALSE); isMinimized = false; break; case WA_INACTIVE: - environment->SetBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "minimized", "Z"), JNI_TRUE); + environment->SetStaticBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "minimized", "Z"), JNI_TRUE); isMinimized = true; break; @@ -219,12 +307,12 @@ break; case WM_QUIT: { - environment->SetBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "closeRequested", "Z"), JNI_TRUE); + environment->SetStaticBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "closeRequested", "Z"), JNI_TRUE); return 0L; } case WM_PAINT: { - environment->SetBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "dirty", "Z"), JNI_TRUE); + environment->SetStaticBooleanField(window, environment->GetFieldID(environment->GetObjectClass(window), "dirty", "Z"), JNI_TRUE); } } @@ -236,7 +324,7 @@ * Register the LWJGL window class. * Returns true for success, or false for failure */ -bool registerWindow() +static bool registerWindow() { if (!oneShotInitialised) { WNDCLASS windowClass; @@ -266,13 +354,43 @@ } /* + * Handle native Win32 messages + */ +static void handleMessages(JNIEnv * env, jclass clazz) +{ + // Cache env and obj + environment = env; + window = clazz; + + /* + * Now's our chance to deal with Windows messages that are + * otherwise just piling up and causing everything not to + * work properly + */ + MSG msg; + while (PeekMessage( + &msg, // message information + hwnd, // handle to window + 0, // first message + 0, // last message + PM_REMOVE // removal options + )) + { + TranslateMessage(&msg); + DispatchMessage(&msg); + }; + environment = NULL; + window = NULL; +} + +/* * Create a window with the specified title, position, size, and * fullscreen attribute. The window will have DirectInput associated * with it. * * Returns true for success, or false for failure */ -bool createWindow(const char * title, int x, int y, int width, int height, bool fullscreen) +static bool createWindow(const char * title, int x, int y, int width, int height, bool fullscreen) { // 1. Register window class if necessary if (!registerWindow()) @@ -355,7 +473,7 @@ * Signature: ()V */ JNIEXPORT void JNICALL Java_org_lwjgl_Window_nSetTitle - (JNIEnv * env, jobject obj, jstring title_obj) + (JNIEnv * env, jclass clazz, jstring title_obj) { const char * title = env->GetStringUTFChars(title_obj, NULL); SetWindowText(hwnd, title); @@ -363,44 +481,14 @@ } /* - * Handle native Win32 messages - */ -void handleMessages(JNIEnv * env, jobject obj) -{ - // Cache env and obj - environment = env; - window = obj; - - /* - * Now's our chance to deal with Windows messages that are - * otherwise just piling up and causing everything not to - * work properly - */ - MSG msg; - while (PeekMessage( - &msg, // message information - hwnd, // handle to window - 0, // first message - 0, // last message - PM_REMOVE // removal options - )) - { - TranslateMessage(&msg); - DispatchMessage(&msg); - }; - environment = NULL; - window = NULL; -} - -/* * Class: org_lwjgl_Window * Method: tick * Signature: ()V */ JNIEXPORT void JNICALL Java_org_lwjgl_Window_tick - (JNIEnv * env, jobject obj) + (JNIEnv * env, jclass clazz) { - handleMessages(env, obj); + handleMessages(env, clazz); } @@ -410,7 +498,7 @@ * Signature: ()V */ JNIEXPORT void JNICALL Java_org_lwjgl_Window_minimize - (JNIEnv * env, jobject obj) + (JNIEnv * env, jclass clazz) { if (isMinimized) return; @@ -423,10 +511,90 @@ * Signature: ()V */ JNIEXPORT void JNICALL Java_org_lwjgl_Window_restore - (JNIEnv * env, jobject obj) + (JNIEnv * env, jclass clazz) { if (!isMinimized) return; ShowWindow(hwnd, SW_RESTORE); +} + +/* + * Class: org_lwjgl_Window + * Method: swapBuffers + * Signature: ()V + */ +JNIEXPORT void JNICALL Java_org_lwjgl_Window_swapBuffers + (JNIEnv * env, jclass clazz) +{ + wglSwapLayerBuffers(hdc, WGL_SWAP_MAIN_PLANE); +} + +/* + * Class: org_lwjgl_Window + * Method: nCreate + * Signature: (Ljava/lang/String;IIIIZIIII)V + */ +JNIEXPORT void JNICALL Java_org_lwjgl_Window_nCreate + (JNIEnv * env, jclass clazz, jstring title, jint x, jint y, jint width, jint height, jboolean fullscreen, jint bpp, jint alpha, jint depth, jint stencil) +{ + // 1. Create a window + const char * titleString = env->GetStringUTFChars(title, NULL); + if (!createWindow(titleString, x, y, width, height, fullscreen == JNI_TRUE ? true : false)) { + env->ReleaseStringUTFChars((jstring) title, titleString); + closeWindow(); + throwException(env, "Failed to create the window."); + return; + } + env->ReleaseStringUTFChars(title, titleString); + + // 2. Choose a pixel format and set it + unsigned int flags = PFD_DRAW_TO_WINDOW | // support window + PFD_SUPPORT_OPENGL | // support OpenGL + PFD_DOUBLEBUFFER; // double buffered + + int iPixelFormat = findPixelFormat(env, flags, bpp, alpha, depth, stencil); + if (iPixelFormat == -1) { + closeWindow(); + return; + } + // Create a rendering context + hglrc = wglCreateContext(hdc); + if (hglrc == NULL) { + throwException(env, "Failed to create OpenGL rendering context"); + closeWindow(); + return; + } + + // Automatically make it the current context + wglMakeCurrent(hdc, hglrc); + + // Initialise GL extensions + if (extgl_Initialize() != 0) { + closeWindow(); + throwException(env, "Failed to initialize GL extensions"); + return; + } +} + +/* + * Class: org_lwjgl_Window + * Method: doDestroy + * Signature: ()V + */ +JNIEXPORT void JNICALL Java_org_lwjgl_Window_nDestroy + (JNIEnv * env, jclass clazz) +{ + wglMakeCurrent(NULL, NULL); + + // Delete the rendering context + if (hglrc != NULL) { +#ifdef _DEBUG + printf("Delete GL context\n"); +#endif + wglDeleteContext(hglrc); + hglrc = NULL; + } + closeWindow(); + extgl_Close(); } --- org_lwjgl_opengl_GLWindow.cpp DELETED --- CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/native/win32/org_lwjgl_opengl_GLWindow.cpp |
|
From: Caspian Rychlik-P. <ci...@us...> - 2003-08-03 22:05:43
|
Update of /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl In directory sc8-pr-cvs1:/tmp/cvs-serv27002/src/java/org/lwjgl Modified Files: Window.java Log Message: Now the only Window class you need :D Index: Window.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/Window.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/Window.java,v retrieving revision 1.15 retrieving revision 1.16 diff -u -d -r1.15 -r1.16 --- Window.java 2 Aug 2003 17:09:40 -0000 1.15 +++ Window.java 3 Aug 2003 22:05:40 -0000 1.16 @@ -7,7 +7,7 @@ package org.lwjgl; /** - * This is the abstract base class for a Window in LWJGL. LWJGL windows have some + * This is the abstract class for a Window in LWJGL. LWJGL windows have some * peculiar characteristics: * * - width and height are always fixed and cannot be changed @@ -20,51 +20,60 @@ * * @author foo */ -public abstract class Window { +public final class Window { static { System.loadLibrary(Sys.getLibraryName()); } - - /** The currently created window */ - private static Window currentWindow; - + /** Whether the window is currently created, ie. has a native peer */ private static boolean created; - /** The window's native data structure. On Win32 this is an HWND. */ - private static int handle; - /** Whether the window is currently minimized */ private static boolean minimized; - + /** Whether the window has focus */ private static boolean focused = true; - + /** Whether the window has been asked to close by the user or underlying OS */ private static boolean closeRequested; - + /** Whether the window is dirty, ie. needs painting */ private static boolean dirty; - + /** X coordinate of the window */ private static int x; - + /** * Y coordinate of the window. Y in window coordinates is from the top of the display down, * unlike GL, where it is typically at the bottom of the display. */ private static int y; - + /** Width of the window */ private static int width; - + /** Height of the window */ private static int height; - + /** Title of the window */ private static String title; - + + /** Color bits */ + private static int color; + + /** Alpha bits */ + private static int alpha; + + /** Depth bits */ + private static int depth; + + /** Stencil bits */ + private static int stencil; + + /** Fullscreen */ + private static boolean fullscreen; + /** * Construct a Window. Some OSs may not support non-fullscreen windows; in * which case the window will be fullscreen regardless. @@ -88,13 +97,7 @@ * @param height Height of window * @throws RuntimeException if you attempt to create more than one window at the same time */ - protected Window(String title, int x, int y, int width, int height) { - Window.title = title; - Window.x = x; - Window.y = y; - Window.width = width; - Window.height = height; - + private Window() { } /** @@ -103,21 +106,21 @@ public static int getWidth() { return width; } - + /** * @return the height of the window */ public static int getHeight() { return height; } - + /** * @return the title of the window */ public static String getTitle() { return title; } - + /** * Set the title of the window. This may be ignored by the underlying OS. * @param newTitle The new window title @@ -127,7 +130,7 @@ title = newTitle; nSetTitle(title); } - + /** * Native implementation of setTitle(). This will read the window's title member * and stash it in the native title of the window. @@ -144,7 +147,7 @@ closeRequested = false; return currentValue; } - + /** * @return true if the window is minimized or otherwise not visible */ @@ -152,7 +155,7 @@ assert isCreated(); return minimized; } - + /** * @return true if window is focused */ @@ -160,7 +163,7 @@ assert isCreated(); return focused; } - + /** * Minimize the game and allow the operating system's default display to become * visible. It is the responsibility of LWJGL's native code to restore the display @@ -169,7 +172,7 @@ * If the display is already minimized then this is a no-op. */ public static native void minimize(); - + /** * Restore the game and hide the operating system away. It is the responsibility of * LWJGL's native code to restore the display to its game display settings. @@ -177,7 +180,7 @@ * If the display is not minimized then this is a no-op/ */ public static native void restore(); - + /** * Determine if the window's contents have been damaged by external events. * If you are writing a straightforward game rendering loop and simply paint @@ -192,83 +195,130 @@ assert isCreated(); return dirty; } - + /** * Paint the window. This clears the dirty flag and swaps the buffers. */ public static void paint() { assert isCreated(); dirty = false; - currentWindow.doPaint(); + swapBuffers(); } - protected abstract void doPaint(); - /** - * Create the window. + * Swap double buffers. */ - public final void create() throws Exception { - if (currentWindow != null) - throw new RuntimeException("Only one LWJGL window may be instantiated at any one time."); - doCreate(); - currentWindow = this; + private static native void swapBuffers(); + + /** + * Create a fullscreen window. If the underlying OS does not + * support fullscreen mode, then a window will be created instead. If this + * fails too then an Exception will be thrown. + * + * @param title The title of the window + * @param bpp Minimum bits per pixel + * @param alpha Minimum bits per pixel in alpha buffer + * @param depth Minimum bits per pixel in depth buffer + * @param stencil Minimum bits per pixel in stencil buffer + * @throws Exception if the window could not be created for any reason; typically because + * the minimum requirements could not be met satisfactorily + */ + public static void create(String title, int bpp, int alpha, int depth, int stencil) throws Exception { + if (isCreated()) + throw new Exception("Only one LWJGL window may be instantiated at any one time."); + Window.x = 0; + Window.y = 0; + Window.color = bpp; + Window.alpha = alpha; + Window.depth = depth; + Window.stencil = stencil; + Window.fullscreen = true; + Window.title = title; + Window.width = Display.getWidth(); + Window.height = Display.getHeight(); + nCreate(title, x, y, width, height, fullscreen, color, alpha, depth, stencil); created = true; - } - + } + /** - * Create the window (derived classes). + * Create a window. If the underlying OS does not have "floating" windows, then a fullscreen + * display will be created instead. If this fails too then an Exception will be thrown. + * If the window is created fullscreen, then its size may not match the specified size + * here. + * + * @param title The title of the window + * @param x The position of the window on the x axis. May be ignored. + * @param y The position of the window on the y axis. May be ignored. + * @param width The width of the window's client area + * @param height The height of the window's client area + * @param bpp Minimum bits per pixel + * @param alpha Minimum bits per pixel in alpha buffer + * @param depth Minimum bits per pixel in depth buffer + * @param stencil Minimum bits per pixel in stencil buffer + * @throws Exception if the window could not be created for any reason; typically because + * the minimum requirements could not be met satisfactorily + */ + public static void create(String title, int x, int y, int width, int height, int bpp, int alpha, int depth, int stencil) + throws Exception { + if (isCreated()) + throw new Exception("Only one LWJGL window may be instantiated at any one time."); + Window.x = x; + Window.y = y; + Window.width = width; + Window.height = height; + Window.color = bpp; + Window.alpha = alpha; + Window.depth = depth; + Window.stencil = stencil; + Window.fullscreen = false; + Window.title = title; + nCreate(title, x, y, width, height, fullscreen, color, alpha, depth, stencil); + created = true; + } + + /** + * Create the native window peer. * @throws Exception */ - protected abstract void doCreate() throws Exception; - + private static native void nCreate( + String title, + int x, + int y, + int width, + int height, + boolean fullscreen, + int bpp, + int alpha, + int depth, + int stencil) + throws Exception; + /** * Destroy the window. */ - public final void destroy() { + public static void destroy() { if (!created) return; - doDestroy(); - currentWindow = null; + nDestroy(); created = false; } - - /** - * Destroy the window (derived classes) - */ - protected abstract void doDestroy(); - - + /** - * @return the native window handle + * Destroy the native window peer. */ - public static int getHandle() { - return handle; - } - + private native static void nDestroy(); + /** * @return true if the window's native peer has been created */ public static boolean isCreated() { return created; } - + /** * 'Tick' the window. This must be called at least once per video frame * to handle window close requests, moves, paints, etc. */ public static native void tick(); - /* (non-Javadoc) - * @see java.lang.Object#toString() - */ - public String toString() { - return "Window["+title+"]"; - } - - /** - * @return the current window, or null, if there is no current window - */ - public static Window getCurrentWindow() { - return currentWindow; - } } |
|
From: Caspian Rychlik-P. <ci...@us...> - 2003-08-03 22:04:48
|
Update of /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/hp In directory sc8-pr-cvs1:/tmp/cvs-serv26859/src/java/org/lwjgl/opengl/hp Removed Files: HPOcclusionTest.java Log Message: Removed GLWindow and some useless extensions --- HPOcclusionTest.java DELETED --- CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/hp/HPOcclusionTest.java |
|
From: Caspian Rychlik-P. <ci...@us...> - 2003-08-03 22:04:48
|
Update of /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/sgis In directory sc8-pr-cvs1:/tmp/cvs-serv26859/src/java/org/lwjgl/opengl/sgis Removed Files: SGISGenerateMipmap.java Log Message: Removed GLWindow and some useless extensions --- SGISGenerateMipmap.java DELETED --- CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/sgis/SGISGenerateMipmap.java |
|
From: Caspian Rychlik-P. <ci...@us...> - 2003-08-03 22:04:48
|
Update of /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/opengl In directory sc8-pr-cvs1:/tmp/cvs-serv26859/src/java/org/lwjgl/opengl Modified Files: GL.java GLConstants.java GLCaps.java Removed Files: GLWindow.java Log Message: Removed GLWindow and some useless extensions Index: GL.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/GL.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/GL.java,v retrieving revision 1.36 retrieving revision 1.37 diff -u -d -r1.36 -r1.37 --- GL.java 2 Aug 2003 17:09:56 -0000 1.36 +++ GL.java 3 Aug 2003 22:04:45 -0000 1.37 @@ -1362,7 +1362,7 @@ public static native int wglGetCurrentReadDCARB(); - public static native String wglGetExtensionsStringARB(int hdc); + public static native String wglGetExtensionsStringARB(); public static native String wglGetExtensionsStringEXT(); Index: GLConstants.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/GLConstants.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/GLConstants.java,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- GLConstants.java 28 Jul 2003 08:22:03 -0000 1.12 +++ GLConstants.java 3 Aug 2003 22:04:45 -0000 1.13 @@ -41,13 +41,9 @@ import org.lwjgl.opengl.ext.*; import org.lwjgl.opengl.ext.EXTAbgr; import org.lwjgl.opengl.ext.EXTCompiledVertexArray; -import org.lwjgl.opengl.hp.HPOcclusionTest; import org.lwjgl.opengl.nv.*; import org.lwjgl.opengl.nv.NVCopyDepthToColor; import org.lwjgl.opengl.nv.NVDepthClamp; -import org.lwjgl.opengl.sgis.SGISGenerateMipmap; -import org.lwjgl.opengl.sgix.SGIXDepthTexture; -import org.lwjgl.opengl.sgix.SGIXShadow; import org.lwjgl.opengl.wgl.*; import org.lwjgl.opengl.wgl.WGLBufferRegion; import org.lwjgl.opengl.wgl.WGLMakeCurrentRead; @@ -114,7 +110,6 @@ EXTVertexArray, EXTVertexShader, EXTVertexWeighting, - HPOcclusionTest, NVCopyDepthToColor, NVDepthClamp, NVEvaluators, @@ -135,9 +130,6 @@ NVVertexArrayRange, NVVertexArrayRange2, NVVertexProgram, - SGISGenerateMipmap, - SGIXDepthTexture, - SGIXShadow, WGLBufferRegion, WGLMakeCurrentRead, WGLMultisample, Index: GLCaps.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/GLCaps.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/GLCaps.java,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- GLCaps.java 2 Aug 2003 17:09:56 -0000 1.3 +++ GLCaps.java 3 Aug 2003 22:04:45 -0000 1.4 @@ -33,8 +33,6 @@ package org.lwjgl.opengl; import org.lwjgl.Sys; -import org.lwjgl.Window; - import java.lang.reflect.*; import java.lang.reflect.Field; import java.util.HashMap; @@ -249,7 +247,7 @@ final String exts; if (WGL_ARB_extensions_string) - exts = GL.wglGetExtensionsStringARB(Window.getHandle()); + exts = GL.wglGetExtensionsStringARB(); // Remember - this is an HWND not an HDC, which is what's required. The native // code on the other side of wglGetExtensionsStringARB gets the HDC from the HWND // behind the scenes. --- GLWindow.java DELETED --- CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/GLWindow.java |
|
From: Caspian Rychlik-P. <ci...@us...> - 2003-08-03 22:04:48
|
Update of /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/sgix In directory sc8-pr-cvs1:/tmp/cvs-serv26859/src/java/org/lwjgl/opengl/sgix Removed Files: SGIXShadow.java SGIXDepthTexture.java Log Message: Removed GLWindow and some useless extensions --- SGIXShadow.java DELETED --- CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/sgix/SGIXShadow.java --- SGIXDepthTexture.java DELETED --- CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/opengl/sgix/SGIXDepthTexture.java |
|
From: Brian M. <ma...@us...> - 2003-08-03 17:32:51
|
Update of /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal In directory sc8-pr-cvs1:/tmp/cvs-serv17923 Modified Files: AL.java ALC.java ALCcontext.java ALCdevice.java ALConstants.java BaseAL.java BaseALConstants.java CoreAL.java OpenALException.java Log Message: Added OpenAL specification to javadoc Index: AL.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/openal/AL.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/AL.java,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- AL.java 2 Aug 2003 17:09:26 -0000 1.11 +++ AL.java 3 Aug 2003 17:32:48 -0000 1.12 @@ -33,7 +33,7 @@ /** * $Id$ - * + * <br> * This is the OpenAL class. It extends the latest core. * * @author Brian Matzon <br...@ma...> Index: ALC.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/openal/ALC.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/ALC.java,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- ALC.java 2 Jul 2003 22:34:27 -0000 1.8 +++ ALC.java 3 Aug 2003 17:32:48 -0000 1.9 @@ -35,9 +35,29 @@ /** * $Id$ - * + * + * <p> * This is the context class for OpenAL. This class implements functions * in alc.h + * </p> + * + * <p> + * ALC introduces the notion of a Device. A Device can be, depending on the + * implementation, a hardware device, or a daemon/OS service/actual server. This + * mechanism also permits different drivers (and hardware) to coexist within the same + * system, as well as allowing several applications to share system resources for audio, + * including a single hardware output device. The details are left to the + * implementation, which has to map the available backends to unique device + * specifiers (represented as strings). + * </p> + * + * <p> + * <b>NOTE:</b><br> + * The LWJGL implementation of OpenAL does not expose the device, nor the context. + * Whenever <code>AL</code> is created using the <code>create</code> method, an underlying + * device and context is created. Thus more advanced usage of multiple contexts and/or devices + * are not possible. The above mentioned features are very rarely used in games. + * </p> * * @author Brian Matzon <br...@ma...> * @version $Revision$ @@ -58,17 +78,39 @@ /** Errors: No Error */ public static final int ALC_NO_ERROR = ALC_FALSE; + /** Major version query. */ public static final int ALC_MAJOR_VERSION = 0x1000; + + /** Minor version query. */ public static final int ALC_MINOR_VERSION = 0x1001; + + /** + * The size required for the zero-terminated attributes list, for the current context. + **/ public static final int ALC_ATTRIBUTES_SIZE = 0x1002; + + /** + * Expects a destination of ALC_CURRENT_ATTRIBUTES_SIZE, + * and provides the attribute list for the current context of the specified device. + */ public static final int ALC_ALL_ATTRIBUTES = 0x1003; + /** The specifier string for the default device */ public static final int ALC_DEFAULT_DEVICE_SPECIFIER = 0x1004; + + /** The specifier string for the device */ public static final int ALC_DEVICE_SPECIFIER = 0x1005; + + /** The extensions string for diagnostics and printing */ public static final int ALC_EXTENSIONS = 0x1006; + /** Frequency for mixing output buffer, in units of Hz. */ public static final int ALC_FREQUENCY = 0x1007; + + /** Refresh intervalls, in units of Hz. */ public static final int ALC_REFRESH = 0x1008; + + /** Flag, indicating a synchronous context. */ public static final int ALC_SYNC = 0x1009; /** The device argument does not name a valid device */ @@ -158,8 +200,16 @@ protected static native void nDestroy(); /** - * Returns strings related to the context. + * The application can obtain certain strings from ALC. + * + * <code>ALC_DEFAULT_DEVICE_SPECIFIER</code> - The specifer string for the default device + * <code>ALC_DEVICE_SPECIFIER</code> - The specifer string for the device + * <code>ALC_EXTENSIONS</code> - The extensions string for diagnostics and printing. * + * In addition, printable error message strings are provided for all valid error tokens, + * including <code>ALC_NO_ERROR</code>,<code>ALC_INVALID_DEVICE</code>, <code>ALC_INVALID_CONTEXT</code>, + * <code>ALC_INVALID_ENUM</code>, <code>ALC_INVALID_VALUE</code>. + * * @param pname Property to get * @return String property from device */ @@ -170,7 +220,21 @@ native static String nGetString(int device, int pname); /** - * Returns integers related to the context. + * The application can query ALC for information using an integer query function. + * For some tokens, <code>null</code> is a legal deviceHandle. In other cases, specifying a <code>null</code> + * device will generate an <code>ALC_INVALID_DEVICE</code> error. The application has to + * specify the size of the destination buffer provided. A <code>null</code> destination or a zero + * size parameter will cause ALC to ignore the query. + * + * <code>ALC_MAJOR_VERSION</code> - Major version query. + * <code>ALC_MINOR_VERSION</code> - Minor version query. + * <code>ALC_ATTRIBUTES_SIZE</code> - The size required for the zero-terminated attributes list, + * for the current context. <code>null</code> is an invalid device. <code>null</code> (no current context + * for the specified device) is legal. + * <code>ALC_ALL_ATTRIBUTES</code> - Expects a destination of <code>ALC_CURRENT_ATTRIBUTES_SIZE</code>, + * and provides the attribute list for the current context of the specified device. + * <code>null</code> is an invalid device. <code>null</code> (no current context for the specified device) + * will return the default attributes defined by the specified device. * * @param pname Property to get * @param size Size of destination buffer provided @@ -183,8 +247,13 @@ native static void nGetIntegerv(int device, int pname, int size, Buffer integerdata); /** - * Opens the named device. If null is specied, the implementation will - * provide an implementation specic default. + * The <code>alcOpenDevice</code> function allows the application (i.e. the client program) to + * connect to a device (i.e. the server). + * + * If the function returns <code>null</code>, then no sound driver/device has been found. The + * argument is a null terminated string that requests a certain device or device + * configuration. If <code>null</code> is specified, the implementation will provide an + * implementation specific default. * * @param devicename name of device to open * @return opened device, or null @@ -192,14 +261,26 @@ native static ALCdevice alcOpenDevice(String devicename); /** - * Closes the supplied device. + * The <code>alcCloseDevice</code> function allows the application (i.e. the client program) to + * disconnect from a device (i.e. the server). + * + * If deviceHandle is <code>null</code> or invalid, an <code>ALC_INVALID_DEVICE</code> error will be + * generated. Once closed, a deviceHandle is invalid. * * @param device address of native device to close */ native static void alcCloseDevice(int device); /** - * Creates a context using a specified device. + * A context is created using <code>alcCreateContext</code>. The device parameter has to be a valid + * device. The attribute list can be <code>null</code>, or a zero terminated list of integer pairs + * composed of valid ALC attribute tokens and requested values. + * + * Context creation will fail if the application requests attributes that, by themselves, + * can not be provided. Context creation will fail if the combination of specified + * attributes can not be provided. Context creation will fail if a specified attribute, or + * the combination of attributes, does not match the default values for unspecified + * attributes. * * @param device address of device to associate context to * @param attrList Buffer to read attributes from @@ -208,7 +289,15 @@ native static ALCcontext alcCreateContext(int device, Buffer attrList); /** - * Makes the supplied context the current one + * To make a Context current with respect to AL Operation (state changes by issueing + * commands), <code>alcMakeContextCurrent</code> is used. The context parameter can be <code>null</code> + * or a valid context pointer. The operation will apply to the device that the context + * was created for. + * + * For each OS process (usually this means for each application), only one context can + * be current at any given time. All AL commands apply to the current context. + * Commands that affect objects shared among contexts (e.g. buffers) have side effects + * on other contexts. * * @param context address of context to make current * @return true if successfull, false if not @@ -216,7 +305,15 @@ native static boolean alcMakeContextCurrent(int context); /** - * Tells a context to begin processing. + * The current context is the only context accessible to state changes by AL commands + * (aside from state changes affecting shared objects). However, multiple contexts can + * be processed at the same time. To indicate that a context should be processed (i.e. + * that internal execution state like offset increments are supposed to be performed), + * the application has to use <code>alcProcessContext</code>. + * + * Repeated calls to <code>alcProcessContext</code> are legal, and do not affect a context that is + * already marked as processing. The default state of a context created by + * alcCreateContext is that it is not marked as processing. */ public static void alcProcessContext() { nProcessContext(AL.context.context); @@ -225,14 +322,15 @@ native static void nProcessContext(int context); /** - * Gets the current context + * The application can query for, and obtain an handle to, the current context for the + * application. If there is no current context, <code>null</code> is returned. * * @return Current ALCcontext */ native static ALCcontext alcGetCurrentContext(); /** - * Retrives the device associated with the supplied context + * The application can query for, and obtain an handle to, the device of a given context. * * @param context address of context to get device for * @param ALCdevice associated with context @@ -240,21 +338,39 @@ native static ALCdevice alcGetContextsDevice(int context); /** - * Suspends processing on supplied context + * The application can suspend any context from processing (including the current + * one). To indicate that a context should be suspended from processing (i.e. that + * internal execution state like offset increments is not supposed to be changed), the + * application has to use <code>alcSuspendContext</code>. + * + * Repeated calls to <code>alcSuspendContext</code> are legal, and do not affect a context that is + * already marked as suspended. The default state of a context created by + * <code>alcCreateContext</code> is that it is marked as suspended. * * @param context address of context to suspend */ native static void alcSuspendContext(int context); /** - * Destroys supplied context + * The correct way to destroy a context is to first release it using <code>alcMakeCurrent</code> and + * <code>null</code>. Applications should not attempt to destroy a current context. * * @param context address of context to Destroy */ native static void alcDestroyContext(int context); /** - * Retrieves the current context error state. + * ALC uses the same conventions and mechanisms as AL for error handling. In + * particular, ALC does not use conventions derived from X11 (GLX) or Windows + * (WGL). The <code>alcGetError</code> function can be used to query ALC errors. + * + * Error conditions are specific to the device. + * + * ALC_NO_ERROR - The device handle or specifier does name an accessible driver/server. + * <code>ALC_INVALID_DEVICE</code> - The Context argument does not name a valid context. + * <code>ALC_INVALID_CONTEXT</code> - The Context argument does not name a valid context. + * <code>ALC_INVALID_ENUM</code> - A token used is not valid, or not applicable. + * <code>ALC_INVALID_VALUE</code> - An value (e.g. attribute) is not valid, or not applicable. * * @return Errorcode from ALC statemachine */ @@ -265,7 +381,10 @@ native static int nGetError(int device); /** - * Query if a specified context extension is available. + * Verify that a given extension is available for the current context and the device it + * is associated with. + * A <code>null</code> name argument returns <code>ALC_FALSE</code>, as do invalid and unsupported string + * tokens. * * @param extName name of extension to find * @return true if extension is available, false if not @@ -277,7 +396,11 @@ native static boolean nIsExtensionPresent(int device, String extName); /** - * retrieves the enum value for a specified enumeration name. + * Enumeration/token values are device independend, but tokens defined for + * extensions might not be present for a given device. But only the tokens defined + * by the AL core are guaranteed. Availability of extension tokens dependends on the ALC extension. + * + * Specifying a <code>null</code> name parameter will cause an <code>ALC_INVALID_VALUE</code> error. * * @param enumName name of enum to find * @return value of enumeration Index: ALCcontext.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/openal/ALCcontext.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/ALCcontext.java,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- ALCcontext.java 2 Jul 2003 22:34:27 -0000 1.4 +++ ALCcontext.java 3 Aug 2003 17:32:48 -0000 1.5 @@ -37,7 +37,7 @@ /** * $Id$ - * + * <br> * Wrapper class, to make ALC contexts behave like the orginal api. * * @author Brian Matzon <br...@ma...> Index: ALCdevice.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/openal/ALCdevice.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/ALCdevice.java,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- ALCdevice.java 2 Jul 2003 22:34:27 -0000 1.4 +++ ALCdevice.java 3 Aug 2003 17:32:48 -0000 1.5 @@ -33,7 +33,7 @@ /** * $Id$ - * + * <br> * Wrapper class, to make ALC devices behave like the orginal api. * * @author Brian Matzon <br...@ma...> Index: ALConstants.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/openal/ALConstants.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/ALConstants.java,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- ALConstants.java 21 Dec 2002 12:37:19 -0000 1.5 +++ ALConstants.java 3 Aug 2003 17:32:48 -0000 1.6 @@ -33,7 +33,7 @@ /** * $Id$ - * + * <br> * This class contains all OpenAL constants, including extensions. * * @author Brian Matzon <br...@ma...> Index: BaseAL.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/openal/BaseAL.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/BaseAL.java,v retrieving revision 1.17 retrieving revision 1.18 diff -u -d -r1.17 -r1.18 --- BaseAL.java 2 Aug 2003 10:57:45 -0000 1.17 +++ BaseAL.java 3 Aug 2003 17:32:48 -0000 1.18 @@ -39,7 +39,7 @@ /** * $Id$ - * + * <br> * The base AL functionality (no actual AL methods). * * This has been provided as a base class that we can use for either the Index: BaseALConstants.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/openal/BaseALConstants.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/BaseALConstants.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- BaseALConstants.java 2 Jul 2003 22:34:27 -0000 1.6 +++ BaseALConstants.java 3 Aug 2003 17:32:48 -0000 1.7 @@ -33,7 +33,7 @@ /** * $Id$ - * + * <br> * This class implements all basic OpenAL constants. * * @author Brian Matzon <br...@ma...> Index: CoreAL.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/openal/CoreAL.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/CoreAL.java,v retrieving revision 1.17 retrieving revision 1.18 diff -u -d -r1.17 -r1.18 --- CoreAL.java 2 Aug 2003 17:09:26 -0000 1.17 +++ CoreAL.java 3 Aug 2003 17:32:48 -0000 1.18 @@ -39,7 +39,7 @@ /** * $Id$ - * + * <br> * This is the core OpenAL class. This class implements * AL.h version 1.0 * @@ -49,21 +49,33 @@ public abstract class CoreAL extends BaseAL implements BaseALConstants { /** - * Enables a feature of the OpenAL driver. + * The application can temporarily disable certain AL capabilities on a per Context + * basis. This allows the driver implementation to optimize for certain subsets of + * operations. Enabling and disabling capabilities is handled using a function pair. * * @param capability name of a capability to enable */ public static native void alEnable(int capability); /** - * Disables a feature of the OpenAL driver. + * The application can temporarily disable certain AL capabilities on a per Context + * basis. This allows the driver implementation to optimize for certain subsets of + * operations. Enabling and disabling capabilities is handled using a function pair. * * @param capability name of a capability to disable */ public static native void alDisable(int capability); /** - * Checks if a specific feature is enabled in the OpenAL driver. + * The application can also query whether a given capability is currently enabled or + * not. + * <p> + * If the token used to specify target is not legal, an AL_INVALID_ENUM error will be + * generated. + * </p> + * <p> + * At this time, this mechanism is not used. There are no valid targets. + * </p> * * @param capability name of a capability to check * @return true if named feature is enabled @@ -74,41 +86,81 @@ * Hinting for implementation * NOTE: This method is a NOP, but is provided for completeness. * - * @param target FIXME - * @param mode FIXME + * @param target The target to hint + * @param mode Mode to hint */ public static native void alHint(int target, int mode); /** - * Returns a boolean OpenAL state. + * Like OpenGL, AL uses a simplified interface for querying global state. + * + * Legal values are e.g. AL_DOPPLER_FACTOR, AL_DOPPLER_VELOCITY, + * AL_DISTANCE_MODEL. + * <p> + * <code>null</code> destinations are quietly ignored. AL_INVALID_ENUM is the response to errors + * in specifying pName. The amount of memory required in the destination + * depends on the actual state requested. + * </p> * * @return boolean state described by pname will be returned. */ public static native boolean alGetBoolean(int pname); /** - * Returns an int OpenAL state. + * Like OpenGL, AL uses a simplified interface for querying global state. + * + * Legal values are e.g. AL_DOPPLER_FACTOR, AL_DOPPLER_VELOCITY, + * AL_DISTANCE_MODEL. + * <p> + * <code>null</code> destinations are quietly ignored. AL_INVALID_ENUM is the response to errors + * in specifying pName. The amount of memory required in the destination + * depends on the actual state requested. + * </p> * * @return int state described by pname will be returned. */ public static native int alGetInteger(int pname); /** - * Returns a float OpenAL state. + * Like OpenGL, AL uses a simplified interface for querying global state. + * + * Legal values are e.g. AL_DOPPLER_FACTOR, AL_DOPPLER_VELOCITY, + * AL_DISTANCE_MODEL. + * <p> + * <code>null</code> destinations are quietly ignored. AL_INVALID_ENUM is the response to errors + * in specifying pName. The amount of memory required in the destination + * depends on the actual state requested. + * </p> * * @return float state described by pname will be returned. */ public static native float alGetFloat(int pname); /** - * Returns a double OpenAL state. + * Like OpenGL, AL uses a simplified interface for querying global state. + * + * Legal values are e.g. AL_DOPPLER_FACTOR, AL_DOPPLER_VELOCITY, + * AL_DISTANCE_MODEL. + * <p> + * <code>null</code> destinations are quietly ignored. AL_INVALID_ENUM is the response to errors + * in specifying pName. The amount of memory required in the destination + * depends on the actual state requested. + * </p> * * @return double state described by pname will be returned. */ public static native double alGetDouble(int pname); /** - * Returns a boolean OpenAL state. + * Like OpenGL, AL uses a simplified interface for querying global state. + * + * Legal values are e.g. AL_DOPPLER_FACTOR, AL_DOPPLER_VELOCITY, + * AL_DISTANCE_MODEL. + * <p> + * <code>null</code> destinations are quietly ignored. AL_INVALID_ENUM is the response to errors + * in specifying pName. The amount of memory required in the destination + * depends on the actual state requested. + * </p> * * @param pname state to be queried * @param data Buffer to place the booleans in @@ -116,7 +168,15 @@ public static native void alGetBooleanv(int pname, ByteBuffer data); /** - * Returns an integer OpenAL state. + * Like OpenGL, AL uses a simplified interface for querying global state. + * + * Legal values are e.g. AL_DOPPLER_FACTOR, AL_DOPPLER_VELOCITY, + * AL_DISTANCE_MODEL. + * <p> + * <code>null</code> destinations are quietly ignored. AL_INVALID_ENUM is the response to errors + * in specifying pName. The amount of memory required in the destination + * depends on the actual state requested. + * </p> * * @param pname state to be queried * @param data Buffer to place the integers in @@ -124,7 +184,15 @@ public static native void alGetIntegerv(int pname, IntBuffer data); /** - * Returns a floating point OpenAL state. + * Like OpenGL, AL uses a simplified interface for querying global state. + * + * Legal values are e.g. AL_DOPPLER_FACTOR, AL_DOPPLER_VELOCITY, + * AL_DISTANCE_MODEL. + * <p> + * <code>null</code> destinations are quietly ignored. AL_INVALID_ENUM is the response to errors + * in specifying pName. The amount of memory required in the destination + * depends on the actual state requested. + * </p> * * @param pname state to be queried * @param data Buffer to place the floats in @@ -132,15 +200,27 @@ public static native void alGetFloatv(int pname, FloatBuffer data); /** - * Returns a double OpenAL state. - * - * @param pname state to be queried - * @param data Buffer to place the floats in - */ + * Like OpenGL, AL uses a simplified interface for querying global state. + * + * Legal values are e.g. AL_DOPPLER_FACTOR, AL_DOPPLER_VELOCITY, + * AL_DISTANCE_MODEL. + * <p> + * <code>null</code> destinations are quietly ignored. AL_INVALID_ENUM is the response to errors + * in specifying pName. The amount of memory required in the destination + * depends on the actual state requested. + * </p> + * + * @param pname state to be queried + * @param data Buffer to place the floats in + */ public static native void alGetDoublev(int pname, DoubleBuffer data); /** - * Retrieve an OpenAL string property. + * The application can retrieve state information global to the current AL Context. + * GetString will return a pointer to a constant string. Valid values for param are + * VERSION, RENDERER, VENDOR, and EXTENSIONS, as well as the error codes + * defined by AL. The application can use GetString to retrieve a string for an error + * code. * * @param pname The property to be returned * @return OpenAL String property @@ -148,14 +228,91 @@ public static native String alGetString(int pname); /** - * Retrieve the current error state and then clears the error state. + * The AL detects only a subset of those conditions that could be considered errors. + * This is because in many cases error checking would adversely impact the + * performance of an error-free program. + * <p> + * Each detectable error is assigned a numeric + * code. When an error is detected by AL, a flag is set and the error code is recorded. + * Further errors, if they occur, do not affect this recorded code. When GetError is + * called, the code is returned and the flag is cleared, so that a further error will again + * record its code. If a call to GetError returns AL_NO_ERROR then there has been no + * detectable error since the last call to GetError (or since the AL was initialized). + * </p> + * <p> + * Error codes can be mapped to strings. The GetString function returns a pointer to a + * constant (literal) string that is identical to the identifier used for the enumeration + * value, as defined in the specification. + * </p> + * <p> + * AL_NO_ERROR - "No Error" token.<br> + * AL_INVALID_NAME - Invalid Name parameter.<br> + * AL_INVALID_ENUM - Invalid parameter.<br> + * AL_INVALID_VALUE - Invalid enum parameter value.<br> + * AL_INVALID_OPERATION - Illegal call.<br> + * AL_OUT_OF_MEMORY - Unable to allocate memory.<br> + * </p> + * <p> + * The table summarizes the AL errors. Currently, when an error flag is set, results of + * AL operations are undefined only if AL_OUT_OF_MEMORY has occured. In other + * cases, the command generating the error is ignored so that it has no effect on AL + * state or output buffer contents. If the error generating command returns a value, it + * returns zero. If the generating command modifies values through a pointer + * argument, no change is made to these values. These error semantics apply only to + * AL errors, not to system errors such as memory access errors. + * </p> + * <p> + * Several error generation conditions are implicit in the description of the various AL + * commands. First, if a command that requires an enumerated value is passed a value + * that is not one of those specified as allowable for that command, the error + * AL_INVALID_ENUM results. This is the case even if the argument is a pointer to a + * symbolic constant if that value is not allowable for the given command. This will + * occur whether the value is allowable for other functions, or an invalid integer value. + * </p> + * <p> + * Integer parameters that are used as names for AL objects such as Buffers and + * Sources are checked for validity. If an invalid name parameter is specified in an AL + * command, an AL_INVALID_NAME error will be generated, and the command is + * ignored. + * </p> + * <p> + * If a negative integer is provided where an argument of type sizei is specified, the + * error AL_INVALID_VALUE results. The same error will result from attempts to set + * integral and floating point values for attributes exceeding the legal range for these. + * The specification does not guarantee that the implementation emits + * AL_INVALID_VALUE if a NaN or Infinity value is passed in for a float or double + * argument (as the specification does not enforce possibly expensive testing of + * floating point values). + * </p> + * <p> + * Commands can be invalid. For example, certain commands might not be applicable + * to a given object. There are also illegal combinations of tokens and values as + * arguments to a command. AL responds to any such illegal command with an + * AL_INVALID_OPERATION error. + * </p> + * <p> + * If memory is exhausted as a side effect of the execution of an AL command, either + * on system level or by exhausting the allocated resources at AL's internal disposal, + * the error AL_OUT_OF_MEMORY may be generated. This can also happen independent + * of recent commands if AL has to request memory for an internal task and fails to + * allocate the required memory from the operating system. + * </p> + * <p> + * Otherwise errors are generated only for conditions that are explicitely described in + * this specification. + * </p> * * @return current error state */ public static native int alGetError(); /** - * Test if a specific extension is available for the OpenAL driver. + * To verify that a given extension is available for the current context and the device it + * is associated with, use this method. + * <p> + * A <code>null</code> name argument returns AL_FALSE, as do invalid and unsupported string + * tokens. A <code>null</code> deviceHandle will result in an INVALID_DEVICE error. + * </p> * * @param fname String describing the desired extension * @return true if extension is available, false if not @@ -163,7 +320,19 @@ public static native boolean alIsExtensionPresent(String fname); /** - * Returns the enumeration value of an OpenAL enum described by a string. + * <p> + * To obtain enumeration values for extensions, the application has to use + * GetEnumValue of an extension token. Enumeration values are defined within the + * AL namespace and allocated according to specification of the core API and the + * extensions, thus they are context-independent. + * </p> + * <p> + * Returns 0 if the enumeration can not be found. The presence of an enum value does + * not guarantee the applicability of an extension to the current context. A non-zero + * return indicates merely that the implementation is aware of the existence of this + * extension. Implementations should not attempt to return 0 to indicate that the + * extensions is not supported for the current context. + * </p> * * @param ename String describing an OpenAL enum * @return Actual int for the described enumeration name @@ -171,7 +340,7 @@ public static native int alGetEnumValue(String ename); /** - * Sets an integer property of the listener + * Listener attributes are changed using the Listener group of commands. * * @param pname name of the attribute to be set * @param value value to set the attribute to @@ -179,7 +348,7 @@ public static native void alListeneri(int pname, int value); /** - * Sets a floating point property of the listener + * Listener attributes are changed using the Listener group of commands. * * @param pname name of the attribute to be set * @param value floating point value to set the attribute to @@ -187,7 +356,7 @@ public static native void alListenerf(int pname, float value); /** - * Sets a floating point property of the listener + * Listener attributes are changed using the Listener group of commands. * * @param pname name of the attribute to be set * @param v1 value value 1 @@ -198,7 +367,7 @@ /** - * Sets a floating point vector property of the listener + * Listener attributes are changed using the Listener group of commands. * * @param pname name of the attribute to be set * @param floatdata Buffer to read floats from @@ -206,7 +375,8 @@ public static native void alListenerfv(int pname, FloatBuffer floatdata); /** - * Gets an integer property of the listener. + * Listener state is maintained inside the AL implementation and can be queried in + * full. * * @param pname name of the attribute to be retrieved * @param integerdata Buffer to write integer to @@ -214,7 +384,8 @@ public static native void alGetListeneri(int pname, IntBuffer integerdata); /** - * Gets a floating point property of the listener. + * Listener state is maintained inside the AL implementation and can be queried in + * full. * * @param pname name of the attribute to be retrieved * @param floatdata Buffer to write float to @@ -222,7 +393,8 @@ public static native void alGetListenerf(int pname, FloatBuffer floatdata); /** - * Retrieves a floating point vector property of the listener. + * Listener state is maintained inside the AL implementation and can be queried in + * full. * * @param pname name of the attribute to be retrieved * @param floatdata Buffer to write floats to @@ -230,7 +402,7 @@ public static native void alGetListenerfv(int pname, FloatBuffer floatdata); /** - * Generate one or more sources. + * The application requests a number of Sources using GenSources. * * @param n number of sources to generate * @param sources array holding sources @@ -238,7 +410,7 @@ public static native void alGenSources(int n, IntBuffer sources); /** - * Delete one or more sources. + * The application requests deletion of a number of Sources by DeleteSources. * * @param n Number of sources to delete * @param source Source array to delete from @@ -246,7 +418,7 @@ public static native void alDeleteSources(int n, IntBuffer source); /** - * Tests if a source is valid. + * The application can verify whether a source name is valid using the IsSource query. * * @param id id of source to be testes for validity * @return true if id is valid, false if not @@ -254,7 +426,8 @@ public static native boolean alIsSource(int id); /** - * Set an integer property of a source. + * Specifies the position and other properties as taken into account during + * sound processing. * * @param source Source to det property on * @param pname property to set @@ -263,7 +436,8 @@ public static native void alSourcei(int source, int pname, int value); /** - * Set a floating point property of a source. + * Specifies the position and other properties as taken into account during + * sound processing. * * @param source Source to det property on * @param pname property to set @@ -272,7 +446,8 @@ public static native void alSourcef(int source, int pname, float value); /** - * Sets a source property requiring three floating point values. + * Specifies the position and other properties as taken into account during + * sound processing. * * @param source Source to set property on * @param pname property to set @@ -289,7 +464,8 @@ /** - * Sets a floating point vector property of a source. + * Specifies the position and other properties as taken into account during + * sound processing. * * @param source source whichs attribute is being set * @param pname name of the attribute being set @@ -298,7 +474,9 @@ public static native void alSourcefv(int source, int pname, FloatBuffer floatdata); /** - * Retrieves an integer property of a source. + * Source state is maintained inside the AL implementation, and the current attributes + * can be queried. The performance of such queries is implementation dependent, no + * performance guarantees are made. * * @param source source to get property from * @param pname name of property @@ -307,7 +485,9 @@ public static native void alGetSourcei(int source, int pname, IntBuffer integerdata); /** - * Retrieves a floating point property of a source. + * Source state is maintained inside the AL implementation, and the current attributes + * can be queried. The performance of such queries is implementation dependent, no + * performance guarantees are made. * * @param source source to get property from * @param pname name of property @@ -316,7 +496,9 @@ public static native void alGetSourcef(int source, int pname, FloatBuffer floatdata); /** - * Gets a floating point vector property from a Source object. + * Source state is maintained inside the AL implementation, and the current attributes + * can be queried. The performance of such queries is implementation dependent, no + * performance guarantees are made. * * @param source Source to get property from * @param pname property to get @@ -325,7 +507,14 @@ public static native void alGetSourcefv(int source, int pname, FloatBuffer floatdata); /** - * Plays a set of sources. + * Play() applied to an AL_INITIAL Source will promote the Source to AL_PLAYING, thus + * the data found in the Buffer will be fed into the processing, starting at the + * beginning. Play() applied to a AL_PLAYING Source will restart the Source from the + * beginning. It will not affect the configuration, and will leave the Source in + * AL_PLAYING state, but reset the sampling offset to the beginning. Play() applied to a + * AL_PAUSED Source will resume processing using the Source state as preserved at the + * Pause() operation. Play() applied to a AL_STOPPED Source will propagate it to + * AL_INITIAL then to AL_PLAYING immediately. * * @param n number of sources to play * @param sources array of sources to play @@ -333,7 +522,10 @@ public static native void alSourcePlayv(int n, IntBuffer sources); /** - * Pauses a set of sources. + * Pause() applied to an AL_INITIAL Source is a legal NOP. Pause() applied to a + * AL_PLAYING Source will change its state to AL_PAUSED. The Source is exempt from + * processing, its current state is preserved. Pause() applied to a AL_PAUSED Source is a + * legal NOP. Pause() applied to a AL_STOPPED Source is a legal NOP. * * @param n number of sources to pause * @param sources array of sources to pause @@ -341,7 +533,11 @@ public static native void alSourcePausev(int n, IntBuffer sources); /** - * Stops a set of sources. + * Stop() applied to an AL_INITIAL Source is a legal NOP. Stop() applied to a AL_PLAYING + * Source will change its state to AL_STOPPED. The Source is exempt from processing, + * its current state is preserved. Stop() applied to a AL_PAUSED Source will change its + * state to AL_STOPPED, with the same consequences as on a AL_PLAYING Source. Stop() + * applied to a AL_STOPPED Source is a legal NOP. * * @param n number of sources to stop * @param sources array of sources to stop @@ -349,7 +545,13 @@ public static native void alSourceStopv(int n, IntBuffer sources); /** - * Rewinds a set of sources. + * Rewind() applied to an AL_INITIAL Source is a legal NOP. Rewind() applied to a + * AL_PLAYING Source will change its state to AL_STOPPED then AL_INITIAL. The Source is + * exempt from processing, its current state is preserved, with the exception of the + * sampling offset which is reset to the beginning. Rewind() applied to a AL_PAUSED + * Source will change its state to AL_INITIAL, with the same consequences as on a + * AL_PLAYING Source. Rewind() applied to a AL_STOPPED Source promotes the Source to + * AL_INITIAL, resetting the sampling offset to the beginning. * * @param n number of sources to rewind * @param sources array of sources to rewind @@ -357,35 +559,55 @@ public static native void alSourceRewindv(int n, IntBuffer sources); /** - * Play a source. + * Play() applied to an AL_INITIAL Source will promote the Source to AL_PLAYING, thus + * the data found in the Buffer will be fed into the processing, starting at the + * beginning. Play() applied to a AL_PLAYING Source will restart the Source from the + * beginning. It will not affect the configuration, and will leave the Source in + * AL_PLAYING state, but reset the sampling offset to the beginning. Play() applied to a + * AL_PAUSED Source will resume processing using the Source state as preserved at the + * Pause() operation. Play() applied to a AL_STOPPED Source will propagate it to + * AL_INITIAL then to AL_PLAYING immediately. * * @param source Source to play */ public static native void alSourcePlay(int source); /** - * Pauses a source. + * Pause() applied to an AL_INITIAL Source is a legal NOP. Pause() applied to a + * AL_PLAYING Source will change its state to AL_PAUSED. The Source is exempt from + * processing, its current state is preserved. Pause() applied to a AL_PAUSED Source is a + * legal NOP. Pause() applied to a AL_STOPPED Source is a legal NOP. * * @param source Source to pause */ public static native void alSourcePause(int source); /** - * Stops a source. + * Stop() applied to an AL_INITIAL Source is a legal NOP. Stop() applied to a AL_PLAYING + * Source will change its state to AL_STOPPED. The Source is exempt from processing, + * its current state is preserved. Stop() applied to a AL_PAUSED Source will change its + * state to AL_STOPPED, with the same consequences as on a AL_PLAYING Source. Stop() + * applied to a AL_STOPPED Source is a legal NOP. * * @param source Source to stop */ public static native void alSourceStop(int source); /** - * Rewinds a source. + * Rewind() applied to an AL_INITIAL Source is a legal NOP. Rewind() applied to a + * AL_PLAYING Source will change its state to AL_STOPPED then AL_INITIAL. The Source is + * exempt from processing, its current state is preserved, with the exception of the + * sampling offset which is reset to the beginning. Rewind() applied to a AL_PAUSED + * Source will change its state to AL_INITIAL, with the same consequences as on a + * AL_PLAYING Source. Rewind() applied to a AL_STOPPED Source promotes the Source to + * AL_INITIAL, resetting the sampling offset to the beginning. * * @param source Source to rewind */ public static native void alSourceRewind(int source); /** - * Generate one or more buffers. + * The application requests a number of Buffers using GenBuffers. * * @param n number of buffers to generate * @param buffers holding buffers @@ -393,7 +615,18 @@ public static native void alGenBuffers(int n, IntBuffer buffers); /** - * Delete one or more buffers. + * <p> + * The application requests deletion of a number of Buffers by calling DeleteBuffers. + * </p> + * <p> + * Once deleted, Names are no longer valid for use with AL function calls. Any such + * use will cause an AL_INVALID_NAME error. The implementation is free to defer actual + * release of resources. + * </p> + * <p> + * IsBuffer(bname) can be used to verify deletion of a buffer. Deleting bufferName 0 is + * a legal NOP in both scalar and vector forms of the command. The same is true for + * unused buffer names, e.g. such as not allocated yet, or as released already. * * @param n Number of buffers to delete * @param buffers Buffer to delete from @@ -401,7 +634,7 @@ public static native void alDeleteBuffers(int n, IntBuffer buffers); /** - * Tests if buffer is valid. + * The application can verify whether a buffer Name is valid using the IsBuffer query. * * @param buffer buffer to be tested for validity * @return true if supplied buffer is valid, false if not @@ -409,7 +642,26 @@ public static native boolean alIsBuffer(int buffer); /** - * Fill a buffer with audio data. + * <p> + * A special case of Buffer state is the actual sound sample data stored in asociation + * with the Buffer. Applications can specify sample data using BufferData. + * </p> + * <p> + * The data specified is copied to an internal software, or if possible, hardware buffer. + * The implementation is free to apply decompression, conversion, resampling, and + * filtering as needed. The internal format of the Buffer is not exposed to the + * application, and not accessible. Valid formats are AL_FORMAT_MONO8, + * AL_FORMAT_MONO16, AL_FORMAT_STEREO8, and AL_FORMAT_STEREO16. An + * implementation may expose other formats, see the chapter on Extensions for + * information on determining if additional formats are supported. + * </p> + * <p> + * Applications should always check for an error condition after attempting to specify + * buffer data in case an implementation has to generate an AL_OUT_OF_MEMORY or + * conversion related AL_INVALID_VALUE error. The application is free to reuse the + * memory specified by the data pointer once the call to BufferData returns. The + * implementation has to dereference, e.g. copy, the data during BufferData execution. + * </p> * * @param buffer Buffer to fill * @param format format sound data is in @@ -425,7 +677,9 @@ int freq); /** - * Retrieves an integer property from a buffer. + * Buffer state is maintained inside the AL implementation and can be queried in full.<br> + * ALC_FREQUENCY - specified in samples per second, i.e. units of Hertz [Hz].<br> + * ALC_SIZE - Size in bytes of the buffer data.<br> * * @param buffer buffer to get property from * @param pname name of property to retrieve @@ -434,7 +688,9 @@ public static native void alGetBufferi(int buffer, int pname, IntBuffer integerdata); /** - * Retrieves a floating point property from a buffer. + * Buffer state is maintained inside the AL implementation and can be queried in full.<br> + * ALC_FREQUENCY - specified in samples per second, i.e. units of Hertz [Hz].<br> + * ALC_SIZE - Size in bytes of the buffer data.<br> * * @param buffer buffer to get property from * @param pname name of property to retrieve @@ -443,7 +699,16 @@ public static native void alGetBufferf(int buffer, int pname, FloatBuffer floatdata); /** - * Queues a set of buffers on a source. + * <p> + * The application can queue up one or multiple buffer names using + * SourceQueueBuffers. The buffers will be queued in the sequence in which they + * appear in the array. + * </p> + * <p> + * This command is legal on a Source in any state (to allow for streaming, queueing + * has to be possible on a AL_PLAYING Source). Queues are read-only with exception of + * the unqueue operation. The Buffer Name AL_NONE (i.e. 0) can be queued. + * </p> * * @param source source to queue buffers onto * @param n number of buffers to be queued @@ -452,7 +717,20 @@ public static native void alSourceQueueBuffers(int source, int n, IntBuffer buffers); /** - * Unqueues a set of buffers attached to a source. + * <p> + * Once a queue entry for a buffer has been appended to a queue and is pending + * processing, it should not be changed. Removal of a given queue entry is not possible + * unless either the Source is AL_STOPPED (in which case then entire queue is considered + * processed), or if the queue entry has already been processed (AL_PLAYING or AL_PAUSED + * Source). + * </p> + * <p> + * The Unqueue command removes a number of buffers entries that have nished + * processing, in the order of appearance, from the queue. The operation will fail if + * more buffers are requested than available, leaving the destination arguments + * unchanged. An AL_INVALID_VALUE error will be thrown. If no error, the destination + * argument will have been updated accordingly. + * </p> * * @param source source to unqueue buffers from * @param n number of buffers to be unqueued @@ -461,22 +739,160 @@ public static native void alSourceUnqueueBuffers(int source, int n, IntBuffer buffers); /** - * Selects the OpenAL distance model. + * <p> + * Samples usually use the entire dynamic range of the chosen format/encoding, + * independent of their real world intensity. In other words, a jet engine and a + * clockwork both will have samples with full amplitude. The application will then + * have to adjust Source AL_GAIN accordingly to account for relative differences. + * </p> + * <p> + * Source AL_GAIN is then attenuated by distance. The effective attenuation of a Source + * depends on many factors, among which distance attenuation and source and + * Listener AL_GAIN are only some of the contributing factors. Even if the source and + * Listener AL_GAIN exceed 1.0 (amplification beyond the guaranteed dynamic range), + * distance and other attenuation might ultimately limit the overall AL_GAIN to a value + * below 1.0. + * </p> + * <p> + * AL currently supports three modes of operation with respect to distance + * attenuation. It supports two distance-dependent attenuation models, one which is + * similar to the IASIG I3DL2 (and DS3D) model. The application choses one of these + * two models (or can chose to disable distance-dependent attenuation effects model) + * on a per-context basis. + * </p> + * <p> + * Legal arguments are AL_NONE, AL_INVERSE_DISTANCE, and + * AL_INVERSE_DISTANCE_CLAMPED. + * <br> + * <br> + * AL_NONE bypasses all distance attenuation + * calculation for all Sources. The implementation is expected to optimize this + * situation. + * <br> + * <br> + * AL_INVERSE_DISTANCE_CLAMPED is the DS3D model, with + * AL_REFERENCE_DISTANCE indicating both the reference distance and the distance + * below which gain will be clamped. + * <br> + * <br> + * AL_INVERSE_DISTANCE is equivalent to the DS3D + * model with the exception that AL_REFERENCE_DISTANCE does not imply any + * clamping. + * <br> + * <br> + * The AL implementation is still free to apply any range clamping as + * necessary. The current distance model chosen can be queried using GetIntegerv and + * AL_DISTANCE_MODEL. + * </p> * * @param value distance model to be set */ public static native void alDistanceModel(int value); /** - * Selects the OpenAL Doppler factor value. + * The Doppler Effect depends on the velocities of Source and Listener relative to the + * medium, and the propagation speed of sound in that medium. The application + * might want to emphasize or de-emphasize the Doppler Effect as physically accurate + * calculation might not give the desired results. The amount of frequency shift (pitch + * change) is proportional to the speed of listener and source along their line of sight. + * The application can increase or decrease that frequency shift by specifying the + * scaling factor AL should apply to the result of the calculation. + * <br> + * <br> + * The Doppler Effect as implemented by AL is described by the formula below. Effects + * of the medium (air, water) moving with respect to listener and source are ignored. + * AL_DOPPLER_VELOCITY is the propagation speed relative to which the Source + * velocities are interpreted. + * + * <p> + * <pre> + * VD: AL_DOPPLER_VELOCITY + * DF: AL_DOPPLER_FACTOR + * vl: Listener velocity (scalar, projected on source-listener vector) + * vs: Source verlocity (scalar, projected on source-listener vector) + * f: Frequency in sample + * f': effective Doppler shifted frequency + * + * f' = DF * f * (VD-vl)/(VD+vs) + * + * vl<0, vs>0 : source and listener approaching each other + * vl>0, vs<0 : source and listener moving away from each other + * </pre> + * </p> + * <p> + * The implementation has to clamp the projected Listener velocity vl, if abs(vl) is + * greater or equal VD. It similarly has to clamp the projected Source velocity vs if + * abs(vs) is greater or equal VD. + * </p> + * <p> + * There are two API calls global to the current context that provide control of the two + * related parameters. + * </p> + * <p> + * AL_DOPPLER_FACTOR is a simple scaling to exaggerate or + * deemphasize the Doppler (pitch) shift resulting from the calculation. + * </p> + * <p> + * A negative 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_FACTOR. The implementation is free to optimize the case of + * AL_DOPPLER_FACTOR being set to zero, as this effectively disables the effect. + * </p> * * @param value Doppler scale value to set */ public static native void alDopplerFactor(float value); /** - * Selects the OpenAL Doppler velocity value. - * + * The Doppler Effect depends on the velocities of Source and Listener relative to the + * medium, and the propagation speed of sound in that medium. The application + * might want to emphasize or de-emphasize the Doppler Effect as physically accurate + * calculation might not give the desired results. The amount of frequency shift (pitch + * change) is proportional to the speed of listener and source along their line of sight. + * The application can increase or decrease that frequency shift by specifying the + * scaling factor AL should apply to the result of the calculation. + * <br> + * <br> + * The Doppler Effect as implemented by AL is described by the formula below. Effects + * of the medium (air, water) moving with respect to listener and source are ignored. + * AL_DOPPLER_VELOCITY is the propagation speed relative to which the Source + * velocities are interpreted. + * + * <p> + * <pre> + * VD: AL_DOPPLER_VELOCITY + * DF: AL_DOPPLER_FACTOR + * vl: Listener velocity (scalar, projected on source-listener vector) + * vs: Source verlocity (scalar, projected on source-listener vector) + * f: Frequency in sample + * f': effective Doppler shifted frequency + * + * f' = DF * f * (VD-vl)/(VD+vs) + * + * vl<0, vs>0 : source and listener approaching each other + * vl>0, vs<0 : source and listener moving away from each other + * </pre> + * </p> + * <p> + * The implementation has to clamp the projected Listener velocity vl, if abs(vl) is + * greater or equal VD. It similarly has to clamp the projected Source velocity vs if + * abs(vs) is greater or equal VD. + * </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: OpenALException.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/openal/OpenALException.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/openal/OpenALException.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- OpenALException.java 21 Dec 2002 12:37:19 -0000 1.2 +++ OpenALException.java 3 Aug 2003 17:32:48 -0000 1.3 @@ -33,7 +33,7 @@ /** * $Id$ - * + * <br> * Thrown by the debug build library of the LWJGL if any OpenAL operation * causes an error. * |
|
From: Elias N. <eli...@us...> - 2003-08-03 16:19:12
|
Update of /cvsroot/java-game-lib/LWJGL/src/native/win32 In directory sc8-pr-cvs1:/tmp/cvs-serv7681/src/native/win32 Modified Files: org_lwjgl_Sys.cpp Log Message: Improved createIndexBuffer Index: org_lwjgl_Sys.cpp CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/native/win32/org_lwjgl_Sys.cpp =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/win32/org_lwjgl_Sys.cpp,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- org_lwjgl_Sys.cpp 3 Aug 2003 11:02:57 -0000 1.12 +++ org_lwjgl_Sys.cpp 3 Aug 2003 16:19:09 -0000 1.13 @@ -57,7 +57,8 @@ JNIEXPORT jobject JNICALL Java_org_lwjgl_Sys_createIndexBuffer (JNIEnv *env, jclass clazz, jint index) { - return env->NewDirectByteBuffer((void *)index, 0); + void *p = (char *)NULL + index; + return env->NewDirectByteBuffer(p, 0); } /* |
|
From: Elias N. <eli...@us...> - 2003-08-03 16:19:12
|
Update of /cvsroot/java-game-lib/LWJGL/src/native/linux In directory sc8-pr-cvs1:/tmp/cvs-serv7681/src/native/linux Modified Files: org_lwjgl_Sys.cpp Log Message: Improved createIndexBuffer Index: org_lwjgl_Sys.cpp CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/native/linux/org_lwjgl_Sys.cpp =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/linux/org_lwjgl_Sys.cpp,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- org_lwjgl_Sys.cpp 3 Aug 2003 11:02:57 -0000 1.12 +++ org_lwjgl_Sys.cpp 3 Aug 2003 16:19:09 -0000 1.13 @@ -56,7 +56,8 @@ JNIEXPORT jobject JNICALL Java_org_lwjgl_Sys_createIndexBuffer (JNIEnv *env, jclass clazz, jint index) { - return env->NewDirectByteBuffer((void *)index, 0); + void *p = (char *)NULL + index; + return env->NewDirectByteBuffer(p, 0); } /* |
|
From: Elias N. <eli...@us...> - 2003-08-03 16:19:12
|
Update of /cvsroot/java-game-lib/LWJGL/src/native In directory sc8-pr-cvs1:/tmp/cvs-serv7681/src/native Modified Files: configure.in Log Message: Improved createIndexBuffer Index: configure.in CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/native/configure.in =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/configure.in,v retrieving revision 1.19 retrieving revision 1.20 diff -u -d -r1.19 -r1.20 --- configure.in 2 Aug 2003 12:53:25 -0000 1.19 +++ configure.in 3 Aug 2003 16:19:09 -0000 1.20 @@ -51,8 +51,8 @@ else AC_MSG_RESULT($JAVA_HOME) JAVA_HOME="$JAVA_HOME" - CPPFLAGS="$CPPFLAGS -D_DEBUG -fno-rtti -fno-exceptions -pthread -D_X11 -Wall -I$JAVA_HOME/include -I$JAVA_HOME/include/linux" - CFLAGS="$CFLAGS -D_DEBUG -pthread -D_X11 -Wall -I$JAVA_HOME/include -I$JAVA_HOME/include/linux" + CPPFLAGS="$CPPFLAGS -fno-rtti -fno-exceptions -pthread -D_X11 -Wall -I$JAVA_HOME/include -I$JAVA_HOME/include/linux" + CFLAGS="$CFLAGS -pthread -D_X11 -Wall -I$JAVA_HOME/include -I$JAVA_HOME/include/linux" fi dnl Checks for libraries. |
|
From: Elias N. <eli...@us...> - 2003-08-03 11:03:00
|
Update of /cvsroot/java-game-lib/LWJGL/src/native/win32 In directory sc8-pr-cvs1:/tmp/cvs-serv25197/src/native/win32 Modified Files: org_lwjgl_Sys.cpp Log Message: Removed Sys.NULL Index: org_lwjgl_Sys.cpp CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/native/win32/org_lwjgl_Sys.cpp =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/win32/org_lwjgl_Sys.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- org_lwjgl_Sys.cpp 2 Aug 2003 15:21:55 -0000 1.11 +++ org_lwjgl_Sys.cpp 3 Aug 2003 11:02:57 -0000 1.12 @@ -51,17 +51,6 @@ /* * Class: org_lwjgl_Sys - * Method: nGetNULLValue - * Signature: ()I - */ -/*JNIEXPORT jobject JNICALL Java_org_lwjgl_Sys_nGetNULLValue - (JNIEnv *env, jclass clazz) -{ - return env->NewDirectByteBuffer(NULL, 0); -} -*/ -/* - * Class: org_lwjgl_Sys * Method: createIndexBuffer * Signature: (I)Ljava/nio/ByteBuffer; */ |
|
From: Elias N. <eli...@us...> - 2003-08-03 11:03:00
|
Update of /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl In directory sc8-pr-cvs1:/tmp/cvs-serv25197/src/java/org/lwjgl Modified Files: Sys.java Log Message: Removed Sys.NULL Index: Sys.java CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/java/org/lwjgl/Sys.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/Sys.java,v retrieving revision 1.24 retrieving revision 1.25 diff -u -d -r1.24 -r1.25 --- Sys.java 2 Aug 2003 15:21:54 -0000 1.24 +++ Sys.java 3 Aug 2003 11:02:57 -0000 1.25 @@ -102,7 +102,6 @@ } finally { DEBUG = _debug; initialize(); -// NULL = nGetNULLValue(); } } @@ -128,11 +127,6 @@ System.loadLibrary(LIBRARY_NAME); setTime(0); } - - /** - * Gets the native NULL constant value - */ -// private static native ByteBuffer nGetNULLValue(); /** * Create a buffer representing an integer index. Use it with functions that in C can take |
|
From: Elias N. <eli...@us...> - 2003-08-03 11:03:00
|
Update of /cvsroot/java-game-lib/LWJGL/src/native/linux In directory sc8-pr-cvs1:/tmp/cvs-serv25197/src/native/linux Modified Files: org_lwjgl_Sys.cpp Log Message: Removed Sys.NULL Index: org_lwjgl_Sys.cpp CVS Browser: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/java-game-lib/LWJGL/src/native/linux/org_lwjgl_Sys.cpp =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/linux/org_lwjgl_Sys.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- org_lwjgl_Sys.cpp 2 Aug 2003 15:21:55 -0000 1.11 +++ org_lwjgl_Sys.cpp 3 Aug 2003 11:02:57 -0000 1.12 @@ -50,17 +50,6 @@ /* * Class: org_lwjgl_Sys - * Method: nGetNULLValue - * Signature: ()I - */ -/*JNIEXPORT jobject JNICALL Java_org_lwjgl_Sys_nGetNULLValue - (JNIEnv *env, jclass clazz) -{ - return env->NewDirectByteBuffer(NULL, 0); -} -*/ -/* - * Class: org_lwjgl_Sys * Method: createIndexBuffer * Signature: (I)Ljava/nio/ByteBuffer; */ |