|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Curve2D
Interface for piecewise smooth curves, like polylines, conics, straight lines, line segments...
Several interfaces exist to use more explicit type of curves:
ContinuousCurve2D
for finite or infinite
continuous curves, SmoothCurve2D
for curves that
admit a derivative (and hence a tangent, a curvature...) at each point,
OrientedCurve2D
that are used to
define the boundary
of a
domain
...
Points on curves are identified using curve parameterization. This parameterization is left to the implementation.
Field Summary |
---|
Fields inherited from interface math.geom2d.Shape2D |
---|
ACCURACY |
Method Summary | |
---|---|
java.awt.Shape |
asAwtShape()
|
CurveSet2D<? extends Curve2D> |
clip(Box2D box)
When a curve is clipped, the result is a set of curves. |
Curve2D |
clone()
Overrides Object declaration to ensure Curve2D implementation are cloned as Curve2D. |
java.util.Collection<? extends ContinuousCurve2D> |
continuousCurves()
Returns the collection of continuous curves which constitute this curve. |
void |
draw(java.awt.Graphics2D g2)
Draws the curve on the given Graphics2D object. |
Point2D |
firstPoint()
Returns the first point of the curve. |
double |
getT0()
Deprecated. replaced by t0() (since 0.11.1). |
double |
getT1()
Deprecated. replaced by t1() (since 0.11.1). |
java.util.Collection<Point2D> |
intersections(LinearShape2D line)
Returns the intersection points of the curve with the specified line. |
boolean |
isSingular(double pos)
Checks if a point is singular. |
Point2D |
lastPoint()
Returns the last point of the curve. |
Point2D |
point(double t)
Returns the point located at the given position on the curve. |
double |
position(Point2D point)
Computes the position of the point on the curve. |
double |
project(Point2D point)
Returns the position of the closest orthogonal projection of the point on the curve, or of the closest singular point. |
Curve2D |
reverse()
Returns the curve with same trace on the plane with parameterization in reverse order. |
java.util.Collection<Point2D> |
singularPoints()
Returns a set of singular points, i. e. which do not locally admit derivative. |
Curve2D |
subCurve(double t0,
double t1)
Returns a portion of the original curve, delimited by two positions on the curve. |
double |
t0()
Get value of parameter t for the first point of the curve. |
double |
t1()
Get value of parameter t for the last point of the curve. |
Curve2D |
transform(AffineTransform2D trans)
Transforms the curve by an affine transform. |
java.util.Collection<Point2D> |
vertices()
Returns the set of vertices for this curve. |
Methods inherited from interface math.geom2d.Shape2D |
---|
boundingBox, contains, contains, distance, distance, isBounded, isEmpty |
Methods inherited from interface math.geom2d.GeometricObject2D |
---|
almostEquals |
Method Detail |
---|
double t0()
@Deprecated double getT0()
double t1()
@Deprecated double getT1()
Point2D point(double t)
Point2D firstPoint()
point(t0())
.
t0()
,
point(double)
Point2D lastPoint()
this.point(this.t1())
.
t1()
,
point(double)
java.util.Collection<Point2D> singularPoints()
vertices()
java.util.Collection<Point2D> vertices()
singularPoints()
boolean isSingular(double pos)
pos
- the position of the point on the curve
double position(Point2D point)
point(double)
method.
point
- a point belonging to the curve
point(double)
double project(Point2D point)
point
- a point to project
java.util.Collection<Point2D> intersections(LinearShape2D line)
Curve2D reverse()
java.util.Collection<? extends ContinuousCurve2D> continuousCurves()
Curve2D subCurve(double t0, double t1)
t0
- position of the start of the sub-curvet1
- position of the end of the sub-curve
Curve2D transform(AffineTransform2D trans)
transform
in interface Shape2D
trans
- an affine transform
CurveSet2D<? extends Curve2D> clip(Box2D box)
clip
in interface Shape2D
box
- the clipping box
java.awt.Shape asAwtShape()
void draw(java.awt.Graphics2D g2)
draw
in interface Shape2D
g2
- the graphics to draw the curve inCurve2D clone()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |