net.nexttext.renderer
Class OpenGLTextPageRenderer.TessCallback

java.lang.Object
  extended by javax.media.opengl.glu.GLUtessellatorCallbackAdapter
      extended by net.nexttext.renderer.OpenGLTextPageRenderer.TessCallback
All Implemented Interfaces:
javax.media.opengl.glu.GLUtessellatorCallback
Enclosing class:
OpenGLTextPageRenderer

public class OpenGLTextPageRenderer.TessCallback
extends javax.media.opengl.glu.GLUtessellatorCallbackAdapter

This tesselator callback uses native Processing drawing functions to execute the incoming commands.


Constructor Summary
OpenGLTextPageRenderer.TessCallback()
           
 
Method Summary
 void begin(int type)
           
 void combine(double[] coords, java.lang.Object[] data, float[] weight, java.lang.Object[] outData)
          Implementation of the GLU_TESS_COMBINE callback.
 void end()
           
 void error(int errnum)
           
 void vertex(java.lang.Object data)
           
 
Methods inherited from class javax.media.opengl.glu.GLUtessellatorCallbackAdapter
beginData, combineData, edgeFlag, edgeFlagData, endData, errorData, vertexData
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OpenGLTextPageRenderer.TessCallback

public OpenGLTextPageRenderer.TessCallback()
Method Detail

begin

public void begin(int type)
Specified by:
begin in interface javax.media.opengl.glu.GLUtessellatorCallback
Overrides:
begin in class javax.media.opengl.glu.GLUtessellatorCallbackAdapter

end

public void end()
Specified by:
end in interface javax.media.opengl.glu.GLUtessellatorCallback
Overrides:
end in class javax.media.opengl.glu.GLUtessellatorCallbackAdapter

vertex

public void vertex(java.lang.Object data)
Specified by:
vertex in interface javax.media.opengl.glu.GLUtessellatorCallback
Overrides:
vertex in class javax.media.opengl.glu.GLUtessellatorCallbackAdapter

error

public void error(int errnum)
Specified by:
error in interface javax.media.opengl.glu.GLUtessellatorCallback
Overrides:
error in class javax.media.opengl.glu.GLUtessellatorCallbackAdapter

combine

public void combine(double[] coords,
                    java.lang.Object[] data,
                    float[] weight,
                    java.lang.Object[] outData)
Implementation of the GLU_TESS_COMBINE callback.

Specified by:
combine in interface javax.media.opengl.glu.GLUtessellatorCallback
Overrides:
combine in class javax.media.opengl.glu.GLUtessellatorCallbackAdapter
Parameters:
coords - is the 3-vector of the new vertex
data - is the vertex data to be combined, up to four elements. This is useful when mixing colors together or any other user data that was passed in to gluTessVertex.
weight - is an array of weights, one for each element of "data" that should be linearly combined for new values.
outData - is the set of new values of "data" after being put back together based on the weights. it's passed back as a single element Object[] array because that's the closest that Java gets to a pointer.