diff options
Diffstat (limited to 'src/classes/com')
-rwxr-xr-x | src/classes/com/sun/javafx/newt/kd/KDWindow.java | 4 | ||||
-rw-r--r-- | src/classes/com/sun/opengl/impl/egl/EGLConfig.java | 5 | ||||
-rwxr-xr-x | src/classes/com/sun/opengl/impl/egl/EGLContext.java | 2 |
3 files changed, 7 insertions, 4 deletions
diff --git a/src/classes/com/sun/javafx/newt/kd/KDWindow.java b/src/classes/com/sun/javafx/newt/kd/KDWindow.java index ebd8edc36..b7b9f6686 100755 --- a/src/classes/com/sun/javafx/newt/kd/KDWindow.java +++ b/src/classes/com/sun/javafx/newt/kd/KDWindow.java @@ -76,7 +76,7 @@ public class KDWindow extends Window { windowHandle = 0; windowID = ++_windowID; - eglWindowHandle = CreateWindow(windowID, getDisplayHandle(), visualID, eglRenderableType); + eglWindowHandle = CreateWindow(windowID, getDisplayHandle(), config.getAttributeList()); if (eglWindowHandle == 0) { throw new RuntimeException("Error creating egl window: "+eglWindowHandle); } @@ -140,7 +140,7 @@ public class KDWindow extends Window { // private static native boolean initIDs(); - private native long CreateWindow(int owner, long displayHandle, long eglConfig, int eglRenderableType); + private native long CreateWindow(int owner, long displayHandle, int[] attributes); private native long RealizeWindow(long eglWindowHandle); private native int CloseWindow(long eglWindowHandle); private native void setVisible0(long eglWindowHandle, boolean visible); diff --git a/src/classes/com/sun/opengl/impl/egl/EGLConfig.java b/src/classes/com/sun/opengl/impl/egl/EGLConfig.java index 49c1a895f..4948b3a0c 100644 --- a/src/classes/com/sun/opengl/impl/egl/EGLConfig.java +++ b/src/classes/com/sun/opengl/impl/egl/EGLConfig.java @@ -54,6 +54,10 @@ public class EGLConfig { return capabilities; } + public int[] getAttributeList() { + return glCapabilities2AttribList(capabilities); + } + public EGLConfig(long display, int configID) { int[] attrs = new int[] { EGL.EGL_RENDERABLE_TYPE, -1, @@ -163,6 +167,5 @@ public class EGLConfig { private _EGLConfig _config; private int configID; private GLCapabilities capabilities; - } diff --git a/src/classes/com/sun/opengl/impl/egl/EGLContext.java b/src/classes/com/sun/opengl/impl/egl/EGLContext.java index 8ba07bc51..40ab077a6 100755 --- a/src/classes/com/sun/opengl/impl/egl/EGLContext.java +++ b/src/classes/com/sun/opengl/impl/egl/EGLContext.java @@ -182,7 +182,7 @@ public class EGLContext extends GLContextImpl { protected void create() throws GLException { long display = drawable.getDisplay(); _EGLConfig config = drawable.getEGLConfig().getNativeConfig(); - long shareWith = 0; + long shareWith = EGL.EGL_NO_CONTEXT; if (display == 0) { throw new GLException("Error: attempted to create an OpenGL context without a display connection"); |