|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.deegree_impl.graphics.displayelements.CurveWalker
Walks along the given GM_Curve and generates positions on the line string in regular intervals (i.e. with the same distance).
Field Summary | |
private int |
maxX
|
private int |
maxY
|
private int |
minX
|
private int |
minY
|
Constructor Summary | |
CurveWalker(java.awt.Rectangle bounds)
|
Method Summary | |
double[] |
calcDeviation(int[] start,
int[] end,
java.util.List points)
Calculates the maximum deviation that points on a linestring have to the ideal line between the starting point and the end point. |
java.util.ArrayList |
createPositions(int[][] pos,
double width)
Determines positions on the given GM_Curve where a caption could be drawn. |
static int[] |
findPointWithDistance(int[] p0,
int[] p1,
int[] p2,
int d)
Finds a point on the line between p1 and p2 that has a certain distance from point p0 (provided that there is such a point). |
double |
getDistance(double x1,
double y1,
double x2,
double y2)
|
double |
getDistance(int[] p1,
int[] p2)
|
double |
getRotation(double x1,
double y1,
double x2,
double y2)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private int minX
private int minY
private int maxX
private int maxY
Constructor Detail |
public CurveWalker(java.awt.Rectangle bounds)
Method Detail |
public java.util.ArrayList createPositions(int[][] pos, double width)
pos
-
public double[] calcDeviation(int[] start, int[] end, java.util.List points)
The ideal line is thought to be running from left to right, the left deviation value generally is above the line, the right value is below.
start
- starting point of the linestringend
- end point of the linestringpoints
- points in between
public static int[] findPointWithDistance(int[] p0, int[] p1, int[] p2, int d)
p0
- point that is used as reference point for the distancep1
- starting point of the linep2
- end point of the lined
- distance
public double getRotation(double x1, double y1, double x2, double y2)
public double getDistance(int[] p1, int[] p2)
public double getDistance(double x1, double y1, double x2, double y2)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |