From e5df5210e059ef597c1c05942cf7dcc0327730cd Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Sun, 23 Jun 2013 01:02:44 +0200 Subject: GLWindow: Mention GLStateKeeper's GL state preservation in API doc --- src/newt/classes/com/jogamp/newt/opengl/GLWindow.java | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/src/newt/classes/com/jogamp/newt/opengl/GLWindow.java b/src/newt/classes/com/jogamp/newt/opengl/GLWindow.java index 1500d48e6..345d92bc1 100644 --- a/src/newt/classes/com/jogamp/newt/opengl/GLWindow.java +++ b/src/newt/classes/com/jogamp/newt/opengl/GLWindow.java @@ -79,11 +79,16 @@ import com.jogamp.newt.event.WindowEvent; import com.jogamp.newt.event.WindowListener; import com.jogamp.newt.event.WindowUpdateEvent; import com.jogamp.opengl.JoglVersion; +import com.jogamp.opengl.GLStateKeeper; /** * An implementation of {@link GLAutoDrawable} and {@link Window} interface, * using a delegated {@link Window} instance, which may be an aggregation (lifecycle: created and destroyed). *

+ * This implementation supports {@link GLStateKeeper GL state preservation}, + * hence {@link #isGLStatePreservationSupported()} returns true. + *

+ *

* This implementation does not make the OpenGL context current
* before calling the various input EventListener callbacks, ie {@link com.jogamp.newt.event.MouseListener} etc.
* This design decision is made in favor of a more performant and simplified @@ -433,8 +438,8 @@ public class GLWindow extends GLAutoDrawableBase implements GLAutoDrawable, Wind protected class GLLifecycleHook implements WindowImpl.LifecycleHook { @Override - public void preserveGLStateAtDestroy() { - GLWindow.this.preserveGLStateAtDestroy(true); + public void preserveGLStateAtDestroy(boolean value) { + GLWindow.this.preserveGLStateAtDestroy(value); } @Override @@ -579,6 +584,12 @@ public class GLWindow extends GLAutoDrawableBase implements GLAutoDrawable, Wind } } + /** + * {@inheritDoc} + *

+ * GLWindow supports GL state preservation, hence returns true. + *

+ */ @Override public final boolean isGLStatePreservationSupported() { return true; } -- cgit v1.2.3