From f0f696c4253691503a0d66636ea779e0731bda84 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Sat, 10 Mar 2012 04:51:28 +0100 Subject: GL/GLContext: Properly define swapInterval incl. default value for EGL (1) and desktop (undefined). *GLContext.setSwapIntervalImpl: Simple return success, set state in GLContext. --- .../classes/jogamp/opengl/macosx/cgl/MacOSXCGLContext.java | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'src/jogl/classes/jogamp/opengl/macosx') diff --git a/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLContext.java b/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLContext.java index 4ef49e337..63d58f447 100644 --- a/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLContext.java +++ b/src/jogl/classes/jogamp/opengl/macosx/cgl/MacOSXCGLContext.java @@ -279,14 +279,9 @@ public abstract class MacOSXCGLContext extends GLContextImpl } } - protected void setSwapIntervalImpl(int interval) { - if( ! isCreated() ) { - throw new GLException("OpenGL context not created"); - } - if(!impl.setSwapInterval(interval)) { - throw new GLException("Error set swap-interval: "+this); - } - currentSwapInterval = interval ; + @Override + protected boolean setSwapIntervalImpl(int interval) { + return impl.setSwapInterval(interval); } public ByteBuffer glAllocateMemoryNV(int arg0, float arg1, float arg2, float arg3) { -- cgit v1.2.3