public abstract class GLPipelineRendererBase extends java.lang.Object implements GLPipelineRenderer
| Constructor and Description |
|---|
GLPipelineRendererBase() |
| Modifier and Type | Method and Description |
|---|---|
void |
begin(com.jogamp.opengl.GL gl,
int glMode,
int maxVertices)
Begins rendering of primitives
|
abstract void |
bind(com.jogamp.opengl.GL gl,
java.nio.ByteBuffer buff,
int normalOffset,
int colorOffset,
int texcoordOffset,
int positionOffset,
int vertexStride)
Prepare to start drawing
|
void |
color(int r,
int g,
int b,
int a)
Cues up a color to use for following vertices
|
void |
dispose(com.jogamp.opengl.GL gl)
Disposes of any resources.
|
void |
enableColors(boolean set)
Enables/disables per-vertex colors.
|
void |
enableNormals(boolean set)
Enables/disables per-vertex normals.
|
void |
enableTexCoords(boolean set)
Enables/disables per-vertex texture coordinates.
|
void |
end()
Ends drawing, flushing the pipeline if necessary
|
void |
flush()
Flushes the pipeline
|
com.jogamp.opengl.GL |
getGL()
The currently-active GL context if rendering.
|
boolean |
isColorsEnabled() |
boolean |
isEmpty()
Checks whether or not pipeline is empty
|
boolean |
isNormalsEnabled() |
boolean |
isTexCoordsEnabled() |
void |
normal(float x,
float y,
float z)
Cues up a normal to use for following vertices
|
void |
setup(boolean hasNormals,
boolean hasColors,
boolean hasTexcoords)
Set up properties of pipeline.
|
void |
texcoord(float x,
float y)
Cues up a texture coordinate to use for following
vertices
|
void |
vertex(float x,
float y,
float z)
Adds a vertex to the pipeline with the currently active
attributes.
|
public boolean isEmpty()
GLPipelineRendererisEmpty in interface GLPipelineRendererpublic void setup(boolean hasNormals,
boolean hasColors,
boolean hasTexcoords)
GLPipelineRenderersetup in interface GLPipelineRendererpublic void enableNormals(boolean set)
GLPipelineRendererenableNormals in interface GLPipelineRendererpublic boolean isNormalsEnabled()
isNormalsEnabled in interface GLPipelineRendererpublic void enableColors(boolean set)
GLPipelineRendererenableColors in interface GLPipelineRendererpublic boolean isColorsEnabled()
isColorsEnabled in interface GLPipelineRendererpublic void enableTexCoords(boolean set)
GLPipelineRendererenableTexCoords in interface GLPipelineRendererpublic boolean isTexCoordsEnabled()
isTexCoordsEnabled in interface GLPipelineRendererpublic abstract void bind(com.jogamp.opengl.GL gl,
java.nio.ByteBuffer buff,
int normalOffset,
int colorOffset,
int texcoordOffset,
int positionOffset,
int vertexStride)
public void begin(com.jogamp.opengl.GL gl,
int glMode,
int maxVertices)
GLPipelineRendererbegin in interface GLPipelineRenderergl - context to useglMode - draw modemaxVertices - maximum number of vertices before content
is flushed. This should be a valid multiple of the vertices
required to complete primitives in the given draw mode.public void normal(float x,
float y,
float z)
GLPipelineRenderernormal in interface GLPipelineRendererpublic void color(int r,
int g,
int b,
int a)
GLPipelineRenderercolor in interface GLPipelineRendererpublic void texcoord(float x,
float y)
GLPipelineRenderertexcoord in interface GLPipelineRendererpublic void vertex(float x,
float y,
float z)
GLPipelineRenderervertex in interface GLPipelineRendererpublic void flush()
GLPipelineRendererflush in interface GLPipelineRendererpublic void end()
GLPipelineRendererend in interface GLPipelineRendererpublic void dispose(com.jogamp.opengl.GL gl)
GLPipelineRendererdispose in interface GLPipelineRendererpublic com.jogamp.opengl.GL getGL()
GLPipelineRendererGLPipelineRenderer.begin(GL, int, int) and GLPipelineRenderer.end().getGL in interface GLPipelineRenderer