public class GL3Debug
extends java.lang.Object
implements java.lang.reflect.InvocationHandler
gl*
method) is printed together with its arguments, then passed on to the
wrapped object, after which (if error checking is enabled) any OpenGL
error is printed. Other methods are passed on and error checked without
being printed.
The wrapper is a dynamic proxy, created by wrap(com.jogamp.opengl.GL3), rather than a
class implementing GL3 explicitly. GL3 has well over a thousand methods
and changes between JOGL versions (JOGL 2.6 added over 400 and removed
some), so an explicit implementation compiles against only one JOGL
version, whereas the proxy works with any.
| Constructor and Description |
|---|
GL3Debug(com.jogamp.opengl.GL3 gl) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
getCheckErrors() |
static GL3Debug |
getHandler(com.jogamp.opengl.GL3 gl)
Returns the debugging handler of a GL3 object created by
wrap(com.jogamp.opengl.GL3), or null if it was not created that way. |
java.lang.Object |
invoke(java.lang.Object proxy,
java.lang.reflect.Method method,
java.lang.Object[] args) |
void |
setCheckErrors(boolean set) |
static com.jogamp.opengl.GL3 |
wrap(com.jogamp.opengl.GL3 gl)
Creates a debugging wrapper for a GL3 object.
|
public static com.jogamp.opengl.GL3 wrap(com.jogamp.opengl.GL3 gl)
gl - object to wrapglpublic static GL3Debug getHandler(com.jogamp.opengl.GL3 gl)
wrap(com.jogamp.opengl.GL3), or null if it was not created that way.public void setCheckErrors(boolean set)
public boolean getCheckErrors()
public java.lang.Object invoke(java.lang.Object proxy,
java.lang.reflect.Method method,
java.lang.Object[] args)
throws java.lang.Throwable
invoke in interface java.lang.reflect.InvocationHandlerjava.lang.Throwable