cz.cuni.jagrlib.piece
Class FaceRenderFlat.PolyEdge

java.lang.Object
  extended by cz.cuni.jagrlib.piece.FaceRenderFlat.PolyEdge
All Implemented Interfaces:
java.lang.Comparable<FaceRenderFlat.PolyEdge>
Enclosing class:
FaceRenderFlat

protected static class FaceRenderFlat.PolyEdge
extends java.lang.Object
implements java.lang.Comparable<FaceRenderFlat.PolyEdge>

Polygon edge.


Field Summary
 int count
          Number of hlines to draw.
 double dx
          X difference between two adjacent hlines.
 double x
          X-coordinate of the edge-hline intersection.
 int y0
          Starting Y-coordinate.
 
Constructor Summary
FaceRenderFlat.PolyEdge(double[] p1, double[] p2)
           
 
Method Summary
 int compareTo(FaceRenderFlat.PolyEdge o)
          Natural ordering: [ y0, x ].
 void next()
          Prepare the edge record for the next line.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

y0

public int y0
Starting Y-coordinate.


x

public double x
X-coordinate of the edge-hline intersection.


dx

public double dx
X difference between two adjacent hlines.


count

public int count
Number of hlines to draw.

Constructor Detail

FaceRenderFlat.PolyEdge

public FaceRenderFlat.PolyEdge(double[] p1,
                               double[] p2)
Method Detail

next

public void next()
Prepare the edge record for the next line.


compareTo

public int compareTo(FaceRenderFlat.PolyEdge o)
Natural ordering: [ y0, x ].

Specified by:
compareTo in interface java.lang.Comparable<FaceRenderFlat.PolyEdge>