From 0002fccdcd6383874b2813dc6bbe3e33f5f00924 Mon Sep 17 00:00:00 2001
From: Sven Gothel
+ * Composable pipeline which wraps an underlying {@link GL} implementation,
+ * providing error checking after each OpenGL method call. If an error occurs,
+ * causes a {@link GLException} to be thrown at exactly the point of failure.
+ *
+ * Sample code which installs this pipeline, manual:
+ *
+ * gl = drawable.setGL(new DebugGL(drawable.getGL()));
+ *
+ * For automatic instantiation see {@link GLPipelineFactory#create(String, Class, GL, Object[])}.
+ *
+ * Composable pipeline which wraps an underlying {@link GL} implementation, + * providing error checking after each OpenGL method call. If an error occurs, + * causes a {@link GLException} to be thrown at exactly the point of failure. + *
+ *+ * Sample code which installs this pipeline, manual: + *
+ * gl = drawable.setGL(new DebugGL(drawable.getGL())); + *+ * For automatic instantiation see {@link GLPipelineFactory#create(String, Class, GL, Object[])}. + * + */ +public class DebugGL3 extends DebugGL4bc { + public DebugGL3(GL3 downstream) { + super((GL4bc)downstream); + } +} diff --git a/src/jogl/classes/javax/media/opengl/DebugGL3bc.java b/src/jogl/classes/javax/media/opengl/DebugGL3bc.java new file mode 100644 index 000000000..6e294d42b --- /dev/null +++ b/src/jogl/classes/javax/media/opengl/DebugGL3bc.java @@ -0,0 +1,21 @@ +package javax.media.opengl; + +/** + *
+ * Composable pipeline which wraps an underlying {@link GL} implementation, + * providing error checking after each OpenGL method call. If an error occurs, + * causes a {@link GLException} to be thrown at exactly the point of failure. + *
+ *+ * Sample code which installs this pipeline, manual: + *
+ * gl = drawable.setGL(new DebugGL(drawable.getGL())); + *+ * For automatic instantiation see {@link GLPipelineFactory#create(String, Class, GL, Object[])}. + * + */ +public class DebugGL3bc extends DebugGL4bc { + public DebugGL3bc(GL3bc downstream) { + super((GL4bc)downstream); + } +} diff --git a/src/jogl/classes/javax/media/opengl/DebugGL4.java b/src/jogl/classes/javax/media/opengl/DebugGL4.java new file mode 100644 index 000000000..d21d39390 --- /dev/null +++ b/src/jogl/classes/javax/media/opengl/DebugGL4.java @@ -0,0 +1,21 @@ +package javax.media.opengl; + +/** + *
+ * Composable pipeline which wraps an underlying {@link GL} implementation, + * providing error checking after each OpenGL method call. If an error occurs, + * causes a {@link GLException} to be thrown at exactly the point of failure. + *
+ *+ * Sample code which installs this pipeline, manual: + *
+ * gl = drawable.setGL(new DebugGL(drawable.getGL())); + *+ * For automatic instantiation see {@link GLPipelineFactory#create(String, Class, GL, Object[])}. + * + */ +public class DebugGL4 extends DebugGL4bc { + public DebugGL4(GL4 downstream) { + super((GL4bc)downstream); + } +} diff --git a/src/jogl/classes/javax/media/opengl/DebugGLES2.java b/src/jogl/classes/javax/media/opengl/DebugGLES2.java new file mode 100644 index 000000000..dee363c1b --- /dev/null +++ b/src/jogl/classes/javax/media/opengl/DebugGLES2.java @@ -0,0 +1,21 @@ +package javax.media.opengl; + +/** + *
+ * Composable pipeline which wraps an underlying {@link GL} implementation, + * providing error checking after each OpenGL method call. If an error occurs, + * causes a {@link GLException} to be thrown at exactly the point of failure. + *
+ *+ * Sample code which installs this pipeline, manual: + *
+ * gl = drawable.setGL(new DebugGL(drawable.getGL())); + *+ * For automatic instantiation see {@link GLPipelineFactory#create(String, Class, GL, Object[])}. + * + */ +public class DebugGLES2 extends DebugGLES3 { + public DebugGLES2(GLES2 downstream) { + super((GLES3)downstream); + } +} diff --git a/src/jogl/classes/javax/media/opengl/GLPipelineFactory.java b/src/jogl/classes/javax/media/opengl/GLPipelineFactory.java index 2bfc77d4a..c6bf26235 100644 --- a/src/jogl/classes/javax/media/opengl/GLPipelineFactory.java +++ b/src/jogl/classes/javax/media/opengl/GLPipelineFactory.java @@ -51,8 +51,23 @@ public class GLPipelineFactory { /** * Creates a pipelined GL instance using the given downstream
downstream
- * and optional arguments additionalArgs
for the constructor.additionalArgs
for the constructor.
*
+ * + * Sample code which installs a Debug and Trace pipeline + * automatic w/ user defined interface, here: GL2ES2: + *
+ * gl = drawable.setGL( GLPipelineFactory.create("javax.media.opengl.Debug", GL2ES2.class, gl, null) ); + * gl = drawable.setGL( GLPipelineFactory.create("javax.media.opengl.Trace", GL2ES2.class, gl, new Object[] { System.err } ) ); + *+ * or automatic w/ automatic defined class: + *
+ * gl = drawable.setGL( GLPipelineFactory.create("javax.media.opengl.Debug", null, gl, null) ); + * gl = drawable.setGL( GLPipelineFactory.create("javax.media.opengl.Trace", null, gl, new Object[] { System.err } ) ); + *+ * + * + *
* The upstream GL instance is determined as follows: *
pipelineClazzBaseName
as the class name's full basename, incl. package name+ * Composable pipeline which wraps an underlying {@link GL} implementation, + * providing tracing information to a user-specified {@link java.io.PrintStream} + * before and after each OpenGL method call. + *
+ *+ * Sample code which installs this pipeline, manual: + *
+ * gl = drawable.setGL(new TraceGL(drawable.getGL(), System.err)); + *+ * For automatic instantiation see {@link GLPipelineFactory#create(String, Class, GL, Object[])}. + * + */ +public class TraceGL2 extends TraceGL4bc { + public TraceGL2(GL2 downstream, PrintStream stream) { + super((GL4bc)downstream, stream); + } +} diff --git a/src/jogl/classes/javax/media/opengl/TraceGL3.java b/src/jogl/classes/javax/media/opengl/TraceGL3.java new file mode 100644 index 000000000..616b31f61 --- /dev/null +++ b/src/jogl/classes/javax/media/opengl/TraceGL3.java @@ -0,0 +1,23 @@ +package javax.media.opengl; + +import java.io.PrintStream; + +/** + *
+ * Composable pipeline which wraps an underlying {@link GL} implementation, + * providing tracing information to a user-specified {@link java.io.PrintStream} + * before and after each OpenGL method call. + *
+ *+ * Sample code which installs this pipeline, manual: + *
+ * gl = drawable.setGL(new TraceGL(drawable.getGL(), System.err)); + *+ * For automatic instantiation see {@link GLPipelineFactory#create(String, Class, GL, Object[])}. + * + */ +public class TraceGL3 extends TraceGL4bc { + public TraceGL3(GL3 downstream, PrintStream stream) { + super((GL4bc)downstream, stream); + } +} diff --git a/src/jogl/classes/javax/media/opengl/TraceGL3bc.java b/src/jogl/classes/javax/media/opengl/TraceGL3bc.java new file mode 100644 index 000000000..f3761d4d6 --- /dev/null +++ b/src/jogl/classes/javax/media/opengl/TraceGL3bc.java @@ -0,0 +1,23 @@ +package javax.media.opengl; + +import java.io.PrintStream; + +/** + *
+ * Composable pipeline which wraps an underlying {@link GL} implementation, + * providing tracing information to a user-specified {@link java.io.PrintStream} + * before and after each OpenGL method call. + *
+ *+ * Sample code which installs this pipeline, manual: + *
+ * gl = drawable.setGL(new TraceGL(drawable.getGL(), System.err)); + *+ * For automatic instantiation see {@link GLPipelineFactory#create(String, Class, GL, Object[])}. + * + */ +public class TraceGL3bc extends TraceGL4bc { + public TraceGL3bc(GL3bc downstream, PrintStream stream) { + super((GL4bc)downstream, stream); + } +} diff --git a/src/jogl/classes/javax/media/opengl/TraceGL4.java b/src/jogl/classes/javax/media/opengl/TraceGL4.java new file mode 100644 index 000000000..a12bf0f47 --- /dev/null +++ b/src/jogl/classes/javax/media/opengl/TraceGL4.java @@ -0,0 +1,23 @@ +package javax.media.opengl; + +import java.io.PrintStream; + +/** + *
+ * Composable pipeline which wraps an underlying {@link GL} implementation, + * providing tracing information to a user-specified {@link java.io.PrintStream} + * before and after each OpenGL method call. + *
+ *+ * Sample code which installs this pipeline, manual: + *
+ * gl = drawable.setGL(new TraceGL(drawable.getGL(), System.err)); + *+ * For automatic instantiation see {@link GLPipelineFactory#create(String, Class, GL, Object[])}. + * + */ +public class TraceGL4 extends TraceGL4bc { + public TraceGL4(GL4 downstream, PrintStream stream) { + super((GL4bc)downstream, stream); + } +} diff --git a/src/jogl/classes/javax/media/opengl/TraceGLES2.java b/src/jogl/classes/javax/media/opengl/TraceGLES2.java new file mode 100644 index 000000000..38d60e3ac --- /dev/null +++ b/src/jogl/classes/javax/media/opengl/TraceGLES2.java @@ -0,0 +1,23 @@ +package javax.media.opengl; + +import java.io.PrintStream; + +/** + *
+ * Composable pipeline which wraps an underlying {@link GL} implementation, + * providing tracing information to a user-specified {@link java.io.PrintStream} + * before and after each OpenGL method call. + *
+ *+ * Sample code which installs this pipeline, manual: + *
+ * gl = drawable.setGL(new TraceGL(drawable.getGL(), System.err)); + *+ * For automatic instantiation see {@link GLPipelineFactory#create(String, Class, GL, Object[])}. + * + */ +public class TraceGLES2 extends TraceGLES3 { + public TraceGLES2(GLES2 downstream, PrintStream stream) { + super((GLES3)downstream, stream); + } +} -- cgit v1.2.3