From d72745fa32a86a3820e5220643a01153e3f21fe7 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Fri, 22 Apr 2011 05:52:06 +0200 Subject: NEWT GLWindow: Remove context current check for swapBuffer() call The spec doesn't require a current context for a swap buffer call, however, if required .. as user shall encapsulate it by himself, or use the GLEventListener model. Motivation: Reduce TLS GLContext.getCurrent() calls. --- src/jogl/classes/jogamp/opengl/GLDrawableHelper.java | 1 + 1 file changed, 1 insertion(+) (limited to 'src/jogl/classes/jogamp/opengl') diff --git a/src/jogl/classes/jogamp/opengl/GLDrawableHelper.java b/src/jogl/classes/jogamp/opengl/GLDrawableHelper.java index d079a1bd1..8911b9ab3 100644 --- a/src/jogl/classes/jogamp/opengl/GLDrawableHelper.java +++ b/src/jogl/classes/jogamp/opengl/GLDrawableHelper.java @@ -337,6 +337,7 @@ public class GLDrawableHelper { // Support for recursive makeCurrent() calls as well as calling // other drawables' display() methods from within another one's + // FIXME: re-evaluate due to possible expensive TLS access ? GLContext lastContext = GLContext.getCurrent(); Runnable lastInitAction = (Runnable) perThreadInitAction.get(); if (lastContext != null) { -- cgit v1.2.3