From 3c5704666a2f64f66de432ef21ac223cc81131e8 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Fri, 5 Jun 2009 11:32:09 +0000 Subject: Minor egl cleanup git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1928 232f8b59-042b-4e1e-8c03-345bb8c30851 --- .../com/sun/opengl/impl/egl/EGLGraphicsConfigurationFactory.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/jogl/classes/com/sun') diff --git a/src/jogl/classes/com/sun/opengl/impl/egl/EGLGraphicsConfigurationFactory.java b/src/jogl/classes/com/sun/opengl/impl/egl/EGLGraphicsConfigurationFactory.java index fd59ccdbc..c332ed9b6 100644 --- a/src/jogl/classes/com/sun/opengl/impl/egl/EGLGraphicsConfigurationFactory.java +++ b/src/jogl/classes/com/sun/opengl/impl/egl/EGLGraphicsConfigurationFactory.java @@ -113,7 +113,7 @@ public class EGLGraphicsConfigurationFactory extends GraphicsConfigurationFactor _EGLConfig[] configs = new _EGLConfig[10]; int[] numConfigs = new int[1]; - if(!EGL.eglGetConfigs(eglDisplay, configs, 10, numConfigs, 0)) { + if(!EGL.eglGetConfigs(eglDisplay, configs, configs.length, numConfigs, 0)) { throw new GLException("Graphics configuration fetch (eglGetConfigs) failed"); } if (numConfigs[0] == 0) { @@ -164,11 +164,11 @@ public class EGLGraphicsConfigurationFactory extends GraphicsConfigurationFactor AbstractGraphicsScreen absScreen) { GLProfile glp = capabilities.getGLProfile(); int[] attrs = EGLGraphicsConfiguration.GLCapabilities2AttribList(capabilities); - _EGLConfig[] configs = new _EGLConfig[1]; + _EGLConfig[] configs = new _EGLConfig[10]; int[] numConfigs = new int[1]; if (!EGL.eglChooseConfig(eglDisplay, attrs, 0, - configs, 1, + configs, configs.length, numConfigs, 0)) { throw new GLException("Graphics configuration selection (eglChooseConfig) failed for "+capabilities); } @@ -182,7 +182,7 @@ public class EGLGraphicsConfigurationFactory extends GraphicsConfigurationFactor if(!EGL.eglGetConfigAttrib(eglDisplay, configs[0], EGL.EGL_CONFIG_ID, val, 0)) { if(DEBUG) { // FIXME: this happens on a ATI PC Emulation .. - System.err.println("EGL couldn't retrieve ConfigID for already chosen eglConfig "+capabilities+" fake 0"); + System.err.println("EGL couldn't retrieve ConfigID for already chosen eglConfig "+capabilities+", error 0x"+Integer.toHexString(EGL.eglGetError())); } val[0]=0; } -- cgit v1.2.3