From 0038e2d41825c22bdd18a7b86a8229a3fab674a3 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Sun, 6 Nov 2011 07:36:35 +0100 Subject: JOGL *Drawable swapBufferImpl() cleanup: Don't force swap-buffer off for offscreen/pbuffer, but respect GLDrawableImpl's decision (double-buffer) --- src/jogl/classes/jogamp/opengl/egl/EGLDrawable.java | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src/jogl/classes/jogamp/opengl/egl/EGLDrawable.java') diff --git a/src/jogl/classes/jogamp/opengl/egl/EGLDrawable.java b/src/jogl/classes/jogamp/opengl/egl/EGLDrawable.java index a9cc40335..de10b066d 100644 --- a/src/jogl/classes/jogamp/opengl/egl/EGLDrawable.java +++ b/src/jogl/classes/jogamp/opengl/egl/EGLDrawable.java @@ -197,6 +197,16 @@ public abstract class EGLDrawable extends GLDrawableImpl { } } + protected final void swapBuffersImpl() { + // single-buffer is already filtered out @ GLDrawableImpl#swapBuffers() + if(!EGL.eglSwapBuffers(eglDisplay, eglSurface)) { + if(DEBUG) { + System.err.println("eglSwapBuffers failed:"); + Thread.dumpStack(); + } + } + } + public int getWidth() { int[] tmp = new int[1]; if (!EGL.eglQuerySurface(eglDisplay, eglSurface, EGL.EGL_WIDTH, tmp, 0)) { -- cgit v1.2.3