agile2d.opengl
Interface TesselatorVisitor
- All Known Implementing Classes:
- VertexArrayList
- public interface TesselatorVisitor
A TesselatorVisitor abstracts the sending of a list of OpenGL
geometry to an OpenGL engine.
For old OpenGL implementations, only glBegin and glEnd functions
can be used, whereas on more recent versions, Vertex Arrays are
much faster since they avoid a function call overhead at each vertex.
This is even more true from gl4java that needs to perform a JNI function,
more expensive than a mere C function call.
TesselatorVisitor objects are meant to be used by Tesselator objects,
and for other purposes as well.
|
Method Summary |
void |
addVertex(double[] coords)
|
void |
addVertex(double x,
double y)
|
void |
begin(int mode)
|
void |
combine(double[] coords,
double[] vertex_data,
float[] weight,
double[] dataOut)
|
void |
end()
|
void |
error(int errorCode)
|
begin
public void begin(int mode)
addVertex
public void addVertex(double[] coords)
addVertex
public void addVertex(double x,
double y)
end
public void end()
error
public void error(int errorCode)
combine
public void combine(double[] coords,
double[] vertex_data,
float[] weight,
double[] dataOut)
Copyright © 2002 by University of Maryland, USA All rights reserved.