|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||

java.lang.Objectmath.geom2d.curve.AbstractContinuousCurve2D
math.geom2d.polygon.Polyline2D
math.geom2d.polygon.LinearRing2D
public class LinearRing2D
A LinearRing2D is a Polyline2D whose last point is connected to the first one. This is typically the boundary of a SimplePolygon2D.
The name 'LinearRing2D' was used for 2 reasons:
| Field Summary |
|---|
| Fields inherited from class math.geom2d.polygon.Polyline2D |
|---|
points |
| Fields inherited from interface math.geom2d.Shape2D |
|---|
ACCURACY |
| Constructor Summary | |
|---|---|
LinearRing2D()
|
|
LinearRing2D(Collection<? extends Point2D> points)
|
|
LinearRing2D(double[] xcoords,
double[] ycoords)
|
|
LinearRing2D(Point2D initialPoint)
|
|
LinearRing2D(Point2D[] points)
|
|
| Method Summary | |
|---|---|
GeneralPath |
appendPath(GeneralPath path)
Append the path of the curve to the given path. |
LinearRing2D |
clone()
Overrides Object declaration to ensure Curve2D implementation are cloned as Curve2D. |
static LinearRing2D |
create(Collection<? extends Point2D> points)
Static factory for creating a new LinearRing2D from a collection of points. |
static LinearRing2D |
create(Point2D[] points)
Static factory for creating a new LinearRing2D from an array of points. |
boolean |
equals(Object object)
|
void |
fill(Graphics2D g2)
|
double |
getArea()
Computes area of the polyline, by returning the absolute value of the signed area. |
Collection<ContinuousBoundary2D> |
getBoundaryCurves()
Returns the different continuous curves composing the boundary |
Collection<? extends LinearRing2D> |
getContinuousCurves()
Returns the collection of continuous curves which constitute this curve. |
Domain2D |
getDomain()
Returns the domain delimited by this boundary. |
Collection<LineSegment2D> |
getEdges()
Returns an array of LineSegment2D. |
Point2D |
getFirstPoint()
return the first point of the polyline. |
GeneralPath |
getGeneralPath()
Return a general path iterator. |
LineSegment2D |
getLastEdge()
|
Point2D |
getLastPoint()
return the first point, as this is the same as the last point. |
CirculinearRing2D |
getParallel(double dist)
Creates a new curve, formed by the points with parameterization: p(t) = c(t) + d*n(t)/|n(t)|, with p(t) being a point of
the original curve, n(t) the normal of the curve, and |n| being the
norm of n.In the case of a continuous curve formed by several smooth circulinear elements, the parallels of contiguous elements are joined by a circle arc. |
Point2D |
getPoint(double t)
Returns point from position as double. |
LinearRing2D |
getReverseCurve()
Returns the closed polyline with same points taken in reverse order. |
double |
getSignedArea()
Computes the signed area of the polyline. |
double |
getSignedDistance(double x,
double y)
The same as getSignedDistance(Point2D), but by passing 2 double as arguments. |
double |
getSignedDistance(Point2D point)
Get the signed distance of the curve to the given point: this distance is positive if the point lies outside the shape, and is negative if the point lies inside the shape. |
Polyline2D |
getSubCurve(double t0,
double t1)
Return an instance of Polyline2D. |
double |
getT0()
returns 0. |
double |
getT1()
return the number of points in the polyline. |
double |
getWindingAngle(Point2D point)
Return the angle portion that the curve turn around the given point. |
boolean |
isClosed()
return true, by definition. |
boolean |
isInside(double x,
double y)
|
boolean |
isInside(Point2D point)
Returns true if the point is 'inside' the domain bounded by the curve. |
LinearRing2D |
transform(AffineTransform2D trans)
Return the transformed shape, as a ClosePolyline2D. |
CirculinearContour2D |
transform(CircleInversion2D inv)
Transforms the shape by a circle inversion. |
| Methods inherited from class math.geom2d.polygon.Polyline2D |
|---|
addPoint, clearPoints, clearVertices, clip, contains, contains, getBoundingBox, getBuffer, getDistance, getDistance, getEdge, getFirstEdge, getIntersections, getLeftTangent, getLength, getLength, getPointArray, getPointsIterator, getPosition, getPosition, getRightTangent, getSingularPoints, getSmoothPieces, getVertex, getVertexNumber, getVertices, isBounded, isEmpty, isSingular, project, removePoint |
| Methods inherited from class math.geom2d.curve.AbstractContinuousCurve2D |
|---|
draw, getAsAWTShape, getAsPolyline, wrapCurve |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface math.geom2d.circulinear.CirculinearContinuousCurve2D |
|---|
clip, getSmoothPieces |
| Methods inherited from interface math.geom2d.circulinear.CirculinearCurve2D |
|---|
getLength, getLength, getPosition |
| Methods inherited from interface math.geom2d.circulinear.CirculinearShape2D |
|---|
getBuffer |
| Methods inherited from interface math.geom2d.curve.ContinuousCurve2D |
|---|
getAsPolyline, getLeftTangent, getRightTangent |
| Methods inherited from interface math.geom2d.curve.Curve2D |
|---|
draw, getAsAWTShape, getIntersections, getPosition, getSingularPoints, isSingular, project |
| Methods inherited from interface math.geom2d.Shape2D |
|---|
contains, contains, getBoundingBox, getDistance, getDistance, isBounded, isEmpty |
| Methods inherited from interface math.geom2d.circulinear.CirculinearBoundary2D |
|---|
clip |
| Constructor Detail |
|---|
public LinearRing2D()
public LinearRing2D(Point2D initialPoint)
public LinearRing2D(Point2D[] points)
public LinearRing2D(double[] xcoords,
double[] ycoords)
public LinearRing2D(Collection<? extends Point2D> points)
| Method Detail |
|---|
public static LinearRing2D create(Collection<? extends Point2D> points)
public static LinearRing2D create(Point2D[] points)
public double getArea()
public double getSignedArea()
public Collection<LineSegment2D> getEdges()
getEdges in class Polyline2Dpublic LineSegment2D getLastEdge()
getLastEdge in class Polyline2Dpublic CirculinearRing2D getParallel(double dist)
CirculinearCurve2D p(t) = c(t) + d*n(t)/|n(t)|, with p(t) being a point of
the original curve, n(t) the normal of the curve, and |n| being the
norm of n.
getParallel in interface CirculinearContinuousCurve2DgetParallel in interface CirculinearContour2DgetParallel in interface CirculinearCurve2DgetParallel in interface ContinuousCirculinearCurve2DgetParallel in class Polyline2Ddist - the distance between the original curve and he parallel curve.
public CirculinearContour2D transform(CircleInversion2D inv)
CirculinearShape2D
transform in interface CirculinearBoundary2Dtransform in interface CirculinearContinuousCurve2Dtransform in interface CirculinearContour2Dtransform in interface CirculinearCurve2Dtransform in interface CirculinearShape2Dtransform in interface ContinuousCirculinearCurve2Dtransform in class Polyline2Dinv - the circle inversion
public Collection<ContinuousBoundary2D> getBoundaryCurves()
Boundary2D
getBoundaryCurves in interface Boundary2Dpublic Domain2D getDomain()
Boundary2D
getDomain in interface Boundary2Dpublic void fill(Graphics2D g2)
fill in interface Boundary2D
public double getSignedDistance(double x,
double y)
OrientedCurve2D
getSignedDistance in interface OrientedCurve2DgetSignedDistance in class Polyline2Dx - x-coord of a pointy - y-coord of a point
public double getSignedDistance(Point2D point)
OrientedCurve2D
getSignedDistance in interface OrientedCurve2DgetSignedDistance in class Polyline2Dpoint - a point of the plane
public double getWindingAngle(Point2D point)
OrientedCurve2D
getWindingAngle in interface OrientedCurve2DgetWindingAngle in class Polyline2Dpoint - a point of the plane
public boolean isInside(double x,
double y)
public boolean isInside(Point2D point)
OrientedCurve2D
isInside in interface Boundary2DisInside in interface OrientedCurve2DisInside in class Polyline2Dpoint - a point in the plane
public boolean isClosed()
isClosed in interface ContinuousCurve2DisClosed in class Polyline2Dpublic Point2D getPoint(double t)
getPoint in interface Curve2DgetPoint in class Polyline2Dpublic double getT0()
getT0 in interface Curve2DgetT0 in class Polyline2Dpublic double getT1()
getT1 in interface Curve2DgetT1 in class Polyline2Dpublic Point2D getFirstPoint()
getFirstPoint in interface Curve2DgetFirstPoint in class Polyline2Dpublic Point2D getLastPoint()
getLastPoint in interface Curve2DgetLastPoint in class Polyline2Dpublic Collection<? extends LinearRing2D> getContinuousCurves()
Curve2D
getContinuousCurves in interface CirculinearBoundary2DgetContinuousCurves in interface CirculinearCurve2DgetContinuousCurves in interface Curve2DgetContinuousCurves in class Polyline2Dpublic LinearRing2D getReverseCurve()
getReverseCurve in interface CirculinearBoundary2DgetReverseCurve in interface CirculinearContinuousCurve2DgetReverseCurve in interface CirculinearContour2DgetReverseCurve in interface CirculinearCurve2DgetReverseCurve in interface ContinuousCirculinearCurve2DgetReverseCurve in interface ContinuousCurve2DgetReverseCurve in interface Curve2DgetReverseCurve in interface Boundary2DgetReverseCurve in interface ContinuousBoundary2DgetReverseCurve in interface ContinuousOrientedCurve2DgetReverseCurve in interface OrientedCurve2DgetReverseCurve in class Polyline2D
public Polyline2D getSubCurve(double t0,
double t1)
getSubCurve in interface CirculinearContinuousCurve2DgetSubCurve in interface CirculinearCurve2DgetSubCurve in interface ContinuousCirculinearCurve2DgetSubCurve in interface ContinuousCurve2DgetSubCurve in interface Curve2DgetSubCurve in interface ContinuousOrientedCurve2DgetSubCurve in class Polyline2Dt0 - position of the start of the sub-curvet1 - position of the end of the sub-curve
public LinearRing2D transform(AffineTransform2D trans)
transform in interface ContinuousCurve2Dtransform in interface Curve2Dtransform in interface Boundary2Dtransform in interface ContinuousBoundary2Dtransform in interface ContinuousOrientedCurve2Dtransform in interface OrientedCurve2Dtransform in interface Shape2Dtransform in class Polyline2Dtrans - an affine transform
public GeneralPath appendPath(GeneralPath path)
ContinuousCurve2D
appendPath in interface ContinuousCurve2DappendPath in class Polyline2Dpath - a path to modify
public GeneralPath getGeneralPath()
getGeneralPath in class Polyline2Dpublic boolean equals(Object object)
equals in class Polyline2Dpublic LinearRing2D clone()
Curve2D
clone in interface Curve2Dclone in class Polyline2D
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||