|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||
java.lang.Object | +--FlatRenderer.EdgeEntry
The entry for an edge in an EdgeBucket.
FlatRenderer.EdgeBucket| Field Summary | |
protected int |
denominator
The denominator of 1/m (dy). |
protected float |
dxPerScan
The x increment, set to numerator/denominator. |
protected int |
increment
The numerator increment |
protected int |
numerator
The numerator of 1/m (dx). |
protected Mesh.Polygon |
owner
The polygon which this edge belongs. |
protected float |
x
The x intersection value; |
protected int |
xmin
The minimum x value of the edge. |
protected int |
ymax
The maximum y value of the edge. |
protected int |
ymin
The minimum y value of the edge. |
| Constructor Summary | |
FlatRenderer.EdgeEntry(Mesh.Polygon poly,
int xmin,
int ymin,
int xmax,
int ymax)
Constructs the entry for an edge. |
|
| Method Summary | |
protected int |
getDenominator()
Returns the denominator of 1/m (dy). |
protected int |
getNumerator()
Returns the numerator of 1/m (dx). |
Mesh.Polygon |
getOwner()
Returns the owning polygon of this edge. |
int |
getX()
Gets the X intersection value. |
int |
getXMin()
Returns the minimum x value of the edge. |
int |
getYMax()
Returns the maximum y value of the edge. |
int |
getYMin()
Returns the minimum y value of the edge. |
boolean |
isHorizontal()
Returns true if the edge is horizontal (dy == 0) |
boolean |
isVertical()
Returns true if the edge is vertical (dx == 0) |
void |
nextX()
Calculates the next x intersection value when y is incremented, based on the current x. |
String |
toString()
Creates a human-readable String that displays the contents of this object, for debugging purposes. |
| Methods inherited from class java.lang.Object |
|
| Field Detail |
protected int increment
protected int numerator
protected int denominator
protected int xmin
protected int ymin
protected int ymax
protected Mesh.Polygon owner
protected float x
protected float dxPerScan
| Constructor Detail |
public FlatRenderer.EdgeEntry(Mesh.Polygon poly,
int xmin,
int ymin,
int xmax,
int ymax)
poly - the owner of this edge.xmin - the x coordinate of the lower point in the edge.ymin - the y coordinate of the lower point in the edge.xmax - the x coordinate of the upper point in the edge.ymax - the y coordinate of the upper point in the edge.| Method Detail |
public void nextX()
public String toString()
public boolean isVertical()
public boolean isHorizontal()
public int getX()
public int getXMin()
public int getYMax()
public int getYMin()
protected int getNumerator()
protected int getDenominator()
public Mesh.Polygon getOwner()
|
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||