aboutsummaryrefslogtreecommitdiffstats
path: root/src/jogl/classes/javax/media/opengl/GLAutoDrawable.java
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2011-04-24 12:21:36 +0200
committerSven Gothel <[email protected]>2011-04-24 12:21:36 +0200
commit6c0ad949be979d5fed95a1166d59100f7bf5580f (patch)
treed69242fabf1f066d43418612209597616fba6cdd /src/jogl/classes/javax/media/opengl/GLAutoDrawable.java
parentea819ff768d507c37a981c1ab0bdc0cad32c6a87 (diff)
Add unified support for GL_ARB_debug_output and GL_AMD_debug_output.
If GL_ARB_debug_output is not available, but GL_AMD_debug_output exist, fallback to the latter, offering generic aliased methods translating the delta (AMD category <-> ARB source/type). Generic aliased methods reside in GLContext* Enable/Disable via GLContext and GLAutoDrawable. To enable the GLDebugOutput feature GLContext.enableGLDebugMessage(true) or GLContext.setContextCreationFlags(GLContext.CTX_OPTION_DEBUG) shall be called _before_ context creation via GLContext.makeCurrent()! In case GLAutoDrawable is being used, GLAutoDrawable.setContextCreationFlags(GLContext.CTX_OPTION_DEBUG) shall be issued before context creation via GLContext.makeCurrent()!. After context creation, the GLDebugOutput feature may be enabled or disabled at any time using this method. Verify both unit tests for usability.
Diffstat (limited to 'src/jogl/classes/javax/media/opengl/GLAutoDrawable.java')
-rw-r--r--src/jogl/classes/javax/media/opengl/GLAutoDrawable.java23
1 files changed, 18 insertions, 5 deletions
diff --git a/src/jogl/classes/javax/media/opengl/GLAutoDrawable.java b/src/jogl/classes/javax/media/opengl/GLAutoDrawable.java
index cf24d1028..90290d882 100644
--- a/src/jogl/classes/javax/media/opengl/GLAutoDrawable.java
+++ b/src/jogl/classes/javax/media/opengl/GLAutoDrawable.java
@@ -185,14 +185,14 @@ public interface GLAutoDrawable extends GLDrawable {
* Enqueues a one-shot {@link javax.media.opengl.GLRunnable},
* which will be executed with the next {@link #display()} call.</p>
* <p>
- * If a {@link javax.media.opengl.GLAnimatorControl} is registered, or if it's not animating, the default situation,<br>
+ * If no {@link javax.media.opengl.GLAnimatorControl} is registered, or if it is not animating, the default situation,<br>
* or if the current thread is the animator thread,<br>
- * a {@link #display()} call has to be issued after enqueue the <code>GLRunnable</code>.<br>
- * No extra synchronization must be performed in case <code>wait</code> is true, since it is executed in the current thread.</p>
+ * a {@link #display()} call is issued after enqueue the <code>GLRunnable</code>.<br>
+ * No extra synchronization is performed in case <code>wait</code> is true, since it is executed in the current thread.</p>
* <p>
* If {@link javax.media.opengl.GLAnimatorControl} is registered and is animating,<br>
- * no call of {@link #display()} must be issued, since the animator thread will performs it.<br>
- * If <code>wait</code> is true, the implementation must wait until the <code>GLRunnable</code> is executed.<br>
+ * no {@link #display()} call is issued, since the animator thread performs it.<br>
+ * If <code>wait</code> is true, the implementation waits until the <code>GLRunnable</code> is executed.<br>
* </p><br>
*
* @see #setAnimator(javax.media.opengl.GLAnimatorControl)
@@ -255,6 +255,19 @@ public interface GLAutoDrawable extends GLDrawable {
drawable. See {@link #setAutoSwapBufferMode}. */
public boolean getAutoSwapBufferMode();
+ /**
+ * @param flags Additional context creation flags.
+ *
+ * @see GLContext#setContextCreationFlags(int)
+ * @see GLContext#enableGLDebugMessage(boolean)
+ */
+ public void setContextCreationFlags(int flags);
+
+ /**
+ * @return Additional context creation flags
+ */
+ public int getContextCreationFlags();
+
/** Returns the {@link GL} pipeline object this GLAutoDrawable uses.
If this method is called outside of the {@link
GLEventListener}'s callback methods (init, display, etc.) it may