|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface IGeometry
| Field Summary | |
|---|---|
static int |
DEFAULT_POINT_AMOUNT
|
| Method Summary | |
|---|---|
void |
addPoint(double x,
double y)
Add a new point to the geometry specified by its x and y coordinates. |
void |
addPoint(Point pt)
Add the given point to the geometry. |
IGeometry |
clone()
Clone the geometry, returning a new copy that is totally independent from the original. |
void |
extend(Iterator<Point> points)
Extend the current geometry with the given list of points. |
void |
extend(Point[] points)
Extend the current geometry with the given list of points. |
void |
flatten()
Flatten the geometry. |
IGeometry |
flattened()
Make a flattened copy of the geometry. |
int |
getPointCount()
|
List<Point> |
getPoints()
Get the points for this geometry. |
Point[] |
makePoints()
Make 100 new points along the contours of the existing path. |
Point[] |
makePoints(int amount)
Make 100 new points along the contours of the existing path. |
Point[] |
makePoints(int amount,
boolean perContour)
Make new points along the contours of the existing path. |
IGeometry |
resampleByAmount(int amount,
boolean perContour)
Generate new geometry with the given amount of points along the shape of the original geometry. |
IGeometry |
resampleByLength(double segmentLength)
Generate new geometry with points along the shape of the original geometry, spaced at the given length. |
| Methods inherited from interface nodebox.graphics.Grob |
|---|
getBounds, getTransformDelegate, isEmpty, rotate, rotateRadians, scale, scale, setTransformDelegate, skew, skew, transform, translate |
| Methods inherited from interface nodebox.graphics.Drawable |
|---|
draw |
| Field Detail |
|---|
static final int DEFAULT_POINT_AMOUNT
| Method Detail |
|---|
int getPointCount()
List<Point> getPoints()
void addPoint(Point pt)
pt - the point to add.
void addPoint(double x,
double y)
x - the X coordinate.y - the Y coordinate.void extend(Iterator<Point> points)
points - the points to add to the geometry.void extend(Point[] points)
points - the points to add to the geometry.Point[] makePoints()
Point[] makePoints(int amount)
amount - the amount of points to distribute.
Point[] makePoints(int amount,
boolean perContour)
amount - the amount of points to distribute.perContour - if true, the points are distributed per contour. The amount of points returned will then be
number of contours * amount.
IGeometry resampleByAmount(int amount,
boolean perContour)
amount - the number of points to generate.perContour - whether the given points are per contour, or for the entire geometry.
IGeometry resampleByLength(double segmentLength)
segmentLength - the maximum length of each resampled segment.
void flatten()
IGeometry flattened()
IGeometry clone()
clone in interface Grob
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||