| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.newdawn.slick.geom.MannTriangulator
public class MannTriangulator
A 2D Triangulator. Graciously made available by the man(n) himself.
| Nested Class Summary | |
|---|---|
| protected  class | MannTriangulator.PointBagA bag/pool of point objects | 
| Field Summary | |
|---|---|
| protected  MannTriangulator.PointBag | contourThe outer countour of the shape | 
| protected  MannTriangulator.PointBag | holesThe holes defined in the polygon | 
| Constructor Summary | |
|---|---|
| MannTriangulator()Creates a new instance of Triangulator0 | |
| Method Summary | |
|---|---|
|  void | addPolyPoint(float x,
             float y)Add a point that forms part of the outer polygon | 
|  int | getTriangleCount()Get a count of the number of triangles produced | 
|  float[] | getTrianglePoint(int tri,
                 int i)Get a point on a specified generated triangle | 
|  void | reset()Reset the internal state of the triangulator | 
|  void | startHole()Begin adding a hole to the polygon | 
|  boolean | triangulate()Run the triangulation | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
protected MannTriangulator.PointBag contour
protected MannTriangulator.PointBag holes
| Constructor Detail | 
|---|
public MannTriangulator()
| Method Detail | 
|---|
public void addPolyPoint(float x,
                         float y)
Triangulator
addPolyPoint in interface Triangulatorx - The x coordinate of the pointy - The y coordiante of the pointTriangulator.addPolyPoint(float, float)public void reset()
public void startHole()
startHole in interface Triangulatorpublic boolean triangulate()
Triangulator
triangulate in interface Triangulatorpublic int getTriangleCount()
Triangulator
getTriangleCount in interface TriangulatorTriangulator.getTriangleCount()
public float[] getTrianglePoint(int tri,
                                int i)
Triangulator
getTrianglePoint in interface Triangulatortri - The index of the triangle to interegatei - The index of the point within the triangle to retrieve
 (0 - 2)
Triangulator.getTrianglePoint(int, int)| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||