You can subscribe to this list here.
| 2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(134) |
Sep
(52) |
Oct
(13) |
Nov
(342) |
Dec
(163) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2003 |
Jan
(44) |
Feb
(62) |
Mar
(158) |
Apr
(38) |
May
(70) |
Jun
(58) |
Jul
(104) |
Aug
(207) |
Sep
(83) |
Oct
(122) |
Nov
(23) |
Dec
(49) |
| 2004 |
Jan
(119) |
Feb
(132) |
Mar
(192) |
Apr
(140) |
May
(77) |
Jun
(74) |
Jul
(201) |
Aug
(63) |
Sep
(102) |
Oct
(70) |
Nov
(173) |
Dec
(78) |
| 2005 |
Jan
(174) |
Feb
(197) |
Mar
(105) |
Apr
(59) |
May
(77) |
Jun
(43) |
Jul
(21) |
Aug
(18) |
Sep
(47) |
Oct
(37) |
Nov
(74) |
Dec
(50) |
| 2006 |
Jan
(44) |
Feb
(19) |
Mar
(32) |
Apr
(24) |
May
(31) |
Jun
(55) |
Jul
(138) |
Aug
(28) |
Sep
(12) |
Oct
(41) |
Nov
(58) |
Dec
(24) |
| 2007 |
Jan
(28) |
Feb
(14) |
Mar
(10) |
Apr
(68) |
May
(30) |
Jun
(26) |
Jul
(18) |
Aug
(63) |
Sep
(19) |
Oct
(29) |
Nov
(20) |
Dec
(10) |
| 2008 |
Jan
(38) |
Feb
(7) |
Mar
(37) |
Apr
(120) |
May
(41) |
Jun
(36) |
Jul
(39) |
Aug
(24) |
Sep
(28) |
Oct
(30) |
Nov
(36) |
Dec
(75) |
| 2009 |
Jan
(46) |
Feb
(22) |
Mar
(50) |
Apr
(70) |
May
(134) |
Jun
(105) |
Jul
(75) |
Aug
(34) |
Sep
(38) |
Oct
(34) |
Nov
(19) |
Dec
(20) |
| 2010 |
Jan
(11) |
Feb
(20) |
Mar
(65) |
Apr
(83) |
May
(104) |
Jun
(73) |
Jul
(78) |
Aug
(57) |
Sep
(43) |
Oct
(35) |
Nov
(9) |
Dec
(4) |
| 2011 |
Jan
(21) |
Feb
(11) |
Mar
(18) |
Apr
(10) |
May
(18) |
Jun
(15) |
Jul
(48) |
Aug
(25) |
Sep
(17) |
Oct
(45) |
Nov
(15) |
Dec
(12) |
| 2012 |
Jan
(21) |
Feb
(9) |
Mar
(12) |
Apr
(9) |
May
(9) |
Jun
(5) |
Jul
(1) |
Aug
(10) |
Sep
(12) |
Oct
(1) |
Nov
(28) |
Dec
(5) |
| 2013 |
Jan
(4) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2014 |
Jan
|
Feb
(1) |
Mar
(1) |
Apr
|
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
| 2015 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
|
Dec
|
| 2016 |
Jan
(2) |
Feb
(1) |
Mar
(1) |
Apr
(1) |
May
(2) |
Jun
|
Jul
(1) |
Aug
(2) |
Sep
|
Oct
|
Nov
(1) |
Dec
|
| 2017 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
|
|
|
|
|
|
1
|
|
2
(1) |
3
(3) |
4
(2) |
5
(18) |
6
|
7
|
8
|
|
9
|
10
(3) |
11
(1) |
12
|
13
|
14
(5) |
15
|
|
16
|
17
|
18
(4) |
19
(1) |
20
|
21
|
22
|
|
23
(31) |
24
|
25
(1) |
26
(2) |
27
|
28
|
29
|
|
30
|
31
(5) |
|
|
|
|
|
|
From: Elias N. <eli...@us...> - 2004-05-11 20:35:01
|
Update of /cvsroot/java-game-lib/LWJGL/src/native/linux In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv796/linux Modified Files: Window.h org_lwjgl_opengl_Pbuffer.cpp org_lwjgl_opengl_Window.cpp Log Message: Linux: Implemented proper X async error handling Index: org_lwjgl_opengl_Window.cpp =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/linux/org_lwjgl_opengl_Window.cpp,v retrieving revision 1.44 retrieving revision 1.45 diff -u -d -r1.44 -r1.45 --- org_lwjgl_opengl_Window.cpp 10 May 2004 21:50:54 -0000 1.44 +++ org_lwjgl_opengl_Window.cpp 11 May 2004 20:34:47 -0000 1.45 @@ -54,6 +54,7 @@ #include "org_lwjgl_opengl_Window.h" #define USEGLX13 extgl_Extensions.GLX13 +#define ERR_MSG_SIZE 1024 static GLXContext context = NULL; // OpenGL rendering context static GLXWindow glx_window; @@ -79,6 +80,28 @@ static Display *display_connection = NULL; static Atom warp_atom; static int display_connection_usage = 0; +static bool async_x_error; +static char error_message[ERR_MSG_SIZE]; + +bool checkXError(JNIEnv *env) { + XSync(getDisplay(), False); + if (async_x_error) { + async_x_error = false; + throwException(env, error_message); + return false; + } else + return true; +} + +static int errorHandler(Display *disp, XErrorEvent *error) { + char err_msg_buffer[ERR_MSG_SIZE]; + XGetErrorText(disp, error->error_code, err_msg_buffer, ERR_MSG_SIZE); + err_msg_buffer[ERR_MSG_SIZE - 1] = '\0'; + snprintf(error_message, ERR_MSG_SIZE, "X Error - serial: %d, error_code: %s, request_code: %d, minor_code: %d", (int)error->serial, err_msg_buffer, (int)error->request_code, (int)error->minor_code); + error_message[ERR_MSG_SIZE - 1] = '\0'; + async_x_error = true; + return 0; +} Display *getDisplay(void) { return display_connection; @@ -86,6 +109,8 @@ Display *incDisplay(JNIEnv *env) { if (display_connection_usage == 0) { + async_x_error = false; + XSetErrorHandler(errorHandler); display_connection = XOpenDisplay(NULL); if (display_connection == NULL) { throwException(env, "Could not open X display"); @@ -236,7 +261,12 @@ env->ReleaseStringUTFChars(title_obj, title); } -static void createWindow(JNIEnv* env, int screen, XVisualInfo *vis_info, jstring title, int x, int y, int width, int height, bool fullscreen, bool undecorated) { +static void destroyWindow() { + XDestroyWindow(getDisplay(), current_win); + XFreeColormap(getDisplay(), cmap); +} + +static bool createWindow(JNIEnv* env, int screen, XVisualInfo *vis_info, jstring title, int x, int y, int width, int height, bool fullscreen, bool undecorated) { dirty = true; focused = true; minimized = false; @@ -266,6 +296,10 @@ attribs.override_redirect = True; } win = XCreateWindow(getDisplay(), root_win, x, y, width, height, 0, vis_info->depth, InputOutput, vis_info->visual, attribmask, &attribs); + if (!checkXError(env)) { + XFreeColormap(getDisplay(), cmap); + return false; + } printfDebug("Created window\n"); current_win = win; Java_org_lwjgl_opengl_Window_nSetTitle(env, NULL, title); @@ -283,12 +317,11 @@ waitMapped(win); XClearWindow(getDisplay(), win); setRepeatMode(AutoRepeatModeOff); - XSync(getDisplay(), True); -} - -static void destroyWindow() { - XDestroyWindow(getDisplay(), current_win); - XFreeColormap(getDisplay(), cmap); + if (!checkXError(env)) { + destroyWindow(); + return false; + } + return true; } int getCurrentScreen(void) { @@ -470,13 +503,23 @@ throwException(env, "Could not create visual info from FB config"); return false; } - createWindow(env, screen, vis_info, title, x, y, width, height, fscreen, undecorated); + bool window_created = createWindow(env, screen, vis_info, title, x, y, width, height, fscreen, undecorated); + XFree(vis_info); + if (!window_created) { + glXDestroyContext(getDisplay(), context); + XFree(configs); + return false; + } glx_window = glXCreateWindow(getDisplay(), configs[0], getCurrentWindow(), NULL); makeCurrent(); if (isDebugEnabled()) dumpVisualInfo(vis_info); XFree(configs); - XFree(vis_info); + if (!checkXError(env)) { + glXDestroyWindow(getDisplay(), glx_window); + glXDestroyContext(getDisplay(), context); + return false; + } return true; } @@ -501,9 +544,18 @@ throwException(env, "Could not create a direct GLX context"); return false; } - createWindow(env, screen, vis_info, title, x, y, width, height, fscreen, undecorated); - makeCurrent(); + bool window_created = createWindow(env, screen, vis_info, title, x, y, width, height, fscreen, undecorated); XFree(vis_info); + if (!window_created) { + glXDestroyContext(getDisplay(), context); + return false; + } + makeCurrent(); + if (!checkXError(env)) { + glXDestroyContext(getDisplay(), context); + destroyWindow(); + return false; + } return true; } Index: Window.h =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/linux/Window.h,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- Window.h 13 Apr 2004 12:13:32 -0000 1.11 +++ Window.h 11 May 2004 20:34:47 -0000 1.12 @@ -56,6 +56,8 @@ extern void resetCursor(int x, int y); + extern bool checkXError(JNIEnv *env); + extern Atom getWarpAtom(void); /* Index: org_lwjgl_opengl_Pbuffer.cpp =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/linux/org_lwjgl_opengl_Pbuffer.cpp,v retrieving revision 1.13 retrieving revision 1.14 diff -u -d -r1.13 -r1.14 --- org_lwjgl_opengl_Pbuffer.cpp 7 Apr 2004 07:46:03 -0000 1.13 +++ org_lwjgl_opengl_Pbuffer.cpp 11 May 2004 20:34:47 -0000 1.14 @@ -74,6 +74,15 @@ return extgl_Extensions.GLX13 ? org_lwjgl_opengl_Pbuffer_PBUFFER_SUPPORTED : 0; } +static void destroyPbuffer(PbufferInfo *buffer_info) { + GLXPbuffer buffer = buffer_info->buffer; + GLXContext context = buffer_info->context; + glXDestroyPbuffer(getDisplay(), buffer); + glXDestroyContext(getDisplay(), context); + free(buffer_info); + decDisplay(); +} + /* * Class: org_lwjgl_opengl_Pbuffer * Method: nCreate @@ -131,14 +140,14 @@ if (context == NULL) { XFree(configs); throwException(env, "Could not create a GLX context"); - return false; + return -1; } jboolean allow_software_acceleration = getBooleanProperty(env, "org.lwjgl.opengl.Window.allowSoftwareOpenGL"); if (!allow_software_acceleration && glXIsDirect(disp, context) == False) { glXDestroyContext(disp, context); XFree(configs); throwException(env, "Could not create a direct GLX context"); - return false; + return -1; } const int buffer_attribs[] = {GLX_PBUFFER_WIDTH, width, GLX_PBUFFER_HEIGHT, height, @@ -150,6 +159,10 @@ PbufferInfo *buffer_info = (PbufferInfo *)malloc(sizeof(PbufferInfo)); buffer_info->buffer = buffer; buffer_info->context = context; + if (!checkXError(env)) { + destroyPbuffer(buffer_info); + return -1; + } return (jint)buffer_info; } @@ -178,12 +191,7 @@ (JNIEnv *env, jclass clazz, jint handle) { PbufferInfo *buffer_info = (PbufferInfo *)handle; - GLXPbuffer buffer = buffer_info->buffer; - GLXContext context = buffer_info->context; - glXDestroyPbuffer(getDisplay(), buffer); - glXDestroyContext(getDisplay(), context); - free(buffer_info); - decDisplay(); + destroyPbuffer(buffer_info); } JNIEXPORT void JNICALL Java_org_lwjgl_opengl_Pbuffer_nSetAttrib |