jjdh API

jjdh.opengl.exercises.playground.font
Class PathIteratorMesh

java.lang.Object
  extended by jjdh.opengl.meshes.core.AbstractMesh
      extended by jjdh.opengl.meshes.core.DirectMesh
          extended by jjdh.opengl.exercises.playground.font.PathIteratorMesh
All Implemented Interfaces:
javax.media.opengl.glu.GLUtessellatorCallback, Renderable, Mesh

public final class PathIteratorMesh
extends DirectMesh
implements javax.media.opengl.glu.GLUtessellatorCallback

This Class uses GLU to tesselate the content of a PathIterator.


Field Summary
private  javax.media.opengl.GL gl
           
private  javax.media.opengl.glu.GLU glu
           
private  PathIterator path
           
private  javax.media.opengl.glu.GLUtessellator tessellator
           
 
Fields inherited from class jjdh.opengl.meshes.core.AbstractMesh
material, position, rotation, scale
 
Constructor Summary
PathIteratorMesh(PathIterator path)
          A PathIteratorMesh will be created by Tesselating the interior of a polygon defined by a path.
 
Method Summary
 void begin(int glMode)
           
 void beginData(int arg0, Object arg1)
           
 void combine(double[] arg0, Object[] arg1, float[] arg2, Object[] arg3)
           
 void combineData(double[] arg0, Object[] arg1, float[] arg2, Object[] arg3, Object arg4)
           
 void dispose(javax.media.opengl.GL gl)
          Dispose the OpenGL TessObj associated with this Mesh.
 void edgeFlag(boolean arg0)
           
 void edgeFlagData(boolean arg0, Object arg1)
           
 void end()
           
 void endData(Object arg0)
           
 void error(int errorCode)
           
 void errorData(int errorCode, Object arg1)
           
protected  void privateRender(javax.media.opengl.GL gl)
          This method has to be overwritten by subcasses.
private  void setWindingRule(int rule)
           
 void vertex(Object arg)
          Implements the TessCallback vertex method.
 void vertexData(Object arg0, Object arg1)
           
 
Methods inherited from class jjdh.opengl.meshes.core.AbstractMesh
applyMaterial, applyPosition, applyRotation, applyScaling, getMaterial, getPosition, move, render, rotate, setMaterial, setPosition, setRotation, setScale, toString, unApplyMaterial
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

gl

private javax.media.opengl.GL gl

glu

private javax.media.opengl.glu.GLU glu

path

private PathIterator path

tessellator

private javax.media.opengl.glu.GLUtessellator tessellator
Constructor Detail

PathIteratorMesh

public PathIteratorMesh(PathIterator path)
A PathIteratorMesh will be created by Tesselating the interior of a polygon defined by a path.

Parameters:
path - a flattened path
Method Detail

privateRender

protected void privateRender(javax.media.opengl.GL gl)
Description copied from class: AbstractMesh
This method has to be overwritten by subcasses.

Specified by:
privateRender in class DirectMesh
Parameters:
gl - a OpenGL obejct

setWindingRule

private void setWindingRule(int rule)

dispose

public void dispose(javax.media.opengl.GL gl)
Dispose the OpenGL TessObj associated with this Mesh.

Specified by:
dispose in interface Mesh
Overrides:
dispose in class DirectMesh

begin

public void begin(int glMode)
Specified by:
begin in interface javax.media.opengl.glu.GLUtessellatorCallback

end

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

beginData

public void beginData(int arg0,
                      Object arg1)
Specified by:
beginData in interface javax.media.opengl.glu.GLUtessellatorCallback

edgeFlag

public void edgeFlag(boolean arg0)
Specified by:
edgeFlag in interface javax.media.opengl.glu.GLUtessellatorCallback

edgeFlagData

public void edgeFlagData(boolean arg0,
                         Object arg1)
Specified by:
edgeFlagData in interface javax.media.opengl.glu.GLUtessellatorCallback

vertex

public void vertex(Object arg)
Implements the TessCallback vertex method.

Specified by:
vertex in interface javax.media.opengl.glu.GLUtessellatorCallback

vertexData

public void vertexData(Object arg0,
                       Object arg1)
Specified by:
vertexData in interface javax.media.opengl.glu.GLUtessellatorCallback

endData

public void endData(Object arg0)
Specified by:
endData in interface javax.media.opengl.glu.GLUtessellatorCallback

combine

public void combine(double[] arg0,
                    Object[] arg1,
                    float[] arg2,
                    Object[] arg3)
Specified by:
combine in interface javax.media.opengl.glu.GLUtessellatorCallback

combineData

public void combineData(double[] arg0,
                        Object[] arg1,
                        float[] arg2,
                        Object[] arg3,
                        Object arg4)
Specified by:
combineData in interface javax.media.opengl.glu.GLUtessellatorCallback

error

public void error(int errorCode)
Specified by:
error in interface javax.media.opengl.glu.GLUtessellatorCallback

errorData

public void errorData(int errorCode,
                      Object arg1)
Specified by:
errorData in interface javax.media.opengl.glu.GLUtessellatorCallback

jjdh API

Copyright © 2006 Jonas Jacobi and Dennis Heidsiek. All Rights Reserved.